# Invoice Information Used to request the status (e.g., approved, declined, error, referral, etc.) for a specific invoice; it is primarily used after a timeout or error has occurred. Voided or batched and settled invoices will return an “Invoice Not Found” error. For more information, see the Timeouts and Communication Failures section. - Host Direct - Locally Installed UTG - Commerce Engine For On Premise - Commerce Engine For Cloud See the Integration Methods and URLs Section sections of the Development Quick Start guide for details regarding each processing option. Endpoint: GET /transactions/invoice Version: 1.7.43 Security: AccessToken ## Header parameters: - `Invoice` (string, required) 10-digit invoice number assigned by the interface to identify a transaction. An invoice number serves as a unique key that identifies a transaction within a batch in Shift4's Gateway. Example: "0510093358" - `InterfaceVersion` (string, required) Refers to the version of the program or application that is sending requests to Shift4. The following special characters are not allowed: $ % : ^ - ~ , ? “ ” ‘ ’ { } [ ] \ + = Example: "2.1" - `InterfaceName` (string, required) Refers to the name of the program or application that is sending requests to Shift4. This should be the name of the program that you purchased or created. The following special characters are not allowed: $ % : ^ - ~ ` , ? “ ” ‘ ’ { } [ ] \ + = Example: "ForwardPOS" - `CompanyName` (string, required) Refers to the vendor or partner that designed and certified the interface. The information you use in this field should match what Shift4 has on file or what was agreed upon in your Integration Plan. The following special characters are not allowed: $ % : ^ - ~ ` , ? “ ” ‘ ’ { } [ ] \ + = Example: "PAWS" - `AccessToken` (string, required) A security credential used to authenticate API requests and all i4Go® authorizeClient/preauthorizeClient requests. An Access Token is the alias for the merchant account and interface being used. The Access Token is required in all requests except an Access Token Exchange request, which generates an Access Token using an and . Example: "EA79FB05-3AA7-4500-AF9A-73F986FF2C1D" - `ApiOptions` (string) API Options modify the request being made. Multiple API Options can be sent in a comma separated list with no spaces. See the API Options section for more information. Example: "ALLOWPARTIALAUTH,RETURNEXPDATE" - `ReceiptColumns` (integer) Send this field if you want Shift4 to format the receipt text instead of returning individual fields. The value sent will correlate to the column width of the formatted receipt that we return. (This also allows the receipt text to wrap to fit the paper size of the printed receipt.) See the Printing Receipts section of this document for more information on formatted receipts. Example: 40 - `Token` (string) This field is used to specify the token for the payment method. Example: "8048471746471119" ## Response 200 fields (application/json): - `result` (array) - `result.dateTime` (string) The date and time in ISO 8601 format including the timezone offset (yyyy-mm-ddThh:mm:ss.nnn+hh:mm). Must be sent as the local date/time of the merchant. For example, a request processed at a merchant in the Pacific time zone at 9:18am on April 15th 2021 would be sent as 2021-04-15T09:18:23.283-07:00 - `result.amount` (object) Object containing information regarding the amount being requested. The field within the object is required and specifies the amount being requested. All other fields are for informational purposes and must also be included in the field. For example, a purchase of $100 with a $20 tip and $8 tax would be in the field, in the field and in the field. Note: For merchants that are configured to allow multiple currencies, the amount fields can specify up to three decimal places. However, the number of decimal places can not exceed the number allowed for the specified currency. See the [Currency Codes](/guides/appendices/currency-codes) section for details. - `result.amount.total` (number, required) The amount being charged for a particular transaction. If other amount fields are sent, they must be included in the total amount. Amount cannot be zero. - `result.amount.tax` (number, required) The amount of sales tax charged for a transaction. The tax amount is used by businesses to track tax expenses for accounting purposes. Identifying the tax amount also helps consumers understand the total amount that they were billed. This field is part of Level 2 card data. - `result.amount.taxIndicator` (string) Value|Description -----|----------- Y | Tax is included N | Tax is not included Enum: "Y", "N" - `result.amount.cashback` (number) Specifies the cashback amount in a transaction. When using a UTG-controlled PIN pad with the ALLOWCASHBACK API Option, this field will return the cashback amount requested by the consumer. The interface can also send the desired cashback amount in a request by adding it to the and including it in the field. This will bypass prompting the consumer for a cashback amount. - `result.amount.surcharge` (number) In a sale or authorization transaction, the field specifies a fee amount that a consumer is charged in addition to the transaction amount. The fee amount is also added into . For example, if the transaction request had and the was 1.5% the transaction would include and - `result.amount.tip` (number) The tip amount of the transaction. - `result.card` (object) - `result.card.entryMode` (string) The method used to capture a payment card in an authorization/sale request. Value|Description -----|----------- 1 | Track 1 Only or Dual Track (Track 1 & 2) 2 | Track 2 Only C | EMV Contactless E | EMV Chip M | Manual Entry Q | QR Code R | Contactless MSD via card or mobile wallet Enum: "1", "2", "C", "E", "M", "Q", "R" - `result.card.expirationDate` (integer) Card expiration date in MMYY format. This value will only be populated if "RETURNEXPDATE" is included in the array. - `result.card.levelResult` (string) Classifies the type of card used in an authorization/sale request. This field is returned in a response if the data is provided by the processor. See [Card Level Results]/guides/appendices/card-level-results) for a complete list of values. - `result.card.number` (string) The card number field will always be masked when returned in a response. - `result.card.present` (string) Indicates whether a card was present (‘Y’) or not (‘N’) at the time a transaction took place. This should be set appropriately in the initial authorization/sale request. In subsequent requests, this field should be left blank or should not be sent. Subsequent request here does not apply to the secondary request for card on file type transactions or reuse of the same card. An example of a subsequent request would be a capture after an authorization. You would not include in the capture, which is the subsequent request. Another example is when performing an incremental authorization where you perform an authorization, followed by an incremental authorization then a capture. The second authorization (incremental) and the capture are the subsequent requests where you would not include . Enum: "Y", "N" - `result.card.type` (string) An abbreviation used to specify the type of card that was used when processing a transaction. Value| Description -----|------------ AX | American Express AP | Alipay BC | Backed Card CI | Citgo DB | Debit card GC | Gift Card JC | JCB MC | Mastercard NS | Discover/JCB/Novus PL | Private Label SC | Sears Canada VS | Visa WP | WeChat Pay YC | IT’S YOUR CARD Enum: "AX", "AP", "BC", "CI", "DB", "GC", "JC", "MC", "NS", "PL", "SC", "VS", "WP", "YC" - `result.card.balance` (object) - `result.card.balance.amount` (number) The balance remaining on the card. Depending on which processor is being used, the balance may be returned for a gift card, debit card, EBT card, or other stored value card. - `result.card.securityCode` (object) - `result.card.securityCode.result` (string) The result of a CSC check. This field will be used by Shift4 to determine the value sent in the field (based on the merchant’s list of accepted verification results as configured with Shift4). Value|Description -----|------------ M | CSC matched. N | CSC did not match. P | CSC not processed. S | CSC should have been present. U | Issuer unable to process. Y | CVC1 incorrect. 1 | CSC Unavailable - processor / card type does not support this parameter. 2 | An unrecognised result code was returned by the processor. 3 | No result code was returned by the processor. Enum: "M", "N", "P", "S", "U", "Y", "1", "2", "3" - `result.card.securityCode.valid` (string) A simplified CSC check result based on the value in the field and the merchant’s accepted verification results as configured with Shift4. The value returned will be ‘Y’ if CSC verification passed or ‘N’ if CSC verification did not pass. - `result.card.token` (object) - `result.card.token.value` (string) This field is used to specify a card token. Whenever CHD is sent in a request, a card token will be returned in this field. Your interface should be designed to store this card token for future use. The latest card token received should be used in any subsequent request that references the same card data. - `result.customer` (object) - `result.customer.firstName` (string) Specifies a consumer’s first name. This field is returned whenever the customer name is supplied in the request or if the track/EMV data contains the cardholder name. - `result.customer.lastName` (string) Specifies a consumer’s last name. This field is returned whenever the customer name is supplied in the request or if the track/EMV data contains the cardholder name. - `result.clerk` (object) - `result.clerk.numericId` (integer) A number used to identify the point-of-sale (POS) or property management system (PMS) clerk or user. The value cannot be 0. An interface must be able to dynamically populate this field (not use a hardcoded value), unless the interface will be used exclusively for e-commerce. - `result.merchant` (object) - `result.merchant.mid` (number) The merchant ID associated with the merchant account. - `result.merchant.name` (string) The merchant’s business name as configured with Shift4. - `result.transaction` (object) - `result.transaction.authorizationCode` (string) The authorization code provided by the consumer’s issuing bank. It is provided in a response if an online authorization or sale request is approved. Following a referral response, it is also specified in [Manual Sale](/apis/payments-platform-rest/openapi/transactions/manualsale) requests. - `result.transaction.authSource` (string) In a response, a code returned by the processor to indicate which host issued the response. Value | Description -------|---------------------------- E | Engine (Online) O | Offline A | APM (Online) F | Payment Platform (Online) Enum: "E", "O", "A", "F" - `result.transaction.invoice` (string) 10-digit invoice number assigned by the interface to identify a transaction. An invoice number serves as a unique key that identifies a transaction within a batch in Shift4's Gateway. - `result.transaction.responseCode` (string) Code indicating the Shift4 host response. Value | Description | Details -------|---------------------------------------------------------------------------------------|-------- A | Approved | The transaction is approved. C | Approved | The transaction is approved without requiring additional authorization because it is less than or equal to a ceiling amount. (The ceiling amount is the original authorization amount multiplied by the tolerance per the merchant’s settings with Shift4.) D | Declined | The transaction is declined. Note: Shift4 automatically declines AVS/CSC failures if the [POSHANDLEAVSFAIL Api Option](/guides/appendices/api-options#poshandleavsfail) was not sent in the request. e | [Error](/guides/appendices/error-codes) | There is an error condition. f | [AVS or CSC failure](/guides/response-handling/understanding-avs-and-csc-verification)| An AVS or CSC failure has occurred (credit card only). Note: This value will only be returned if the [POSHANDLEAVSFAIL Api Option](/guides/appendices/api-options#poshandleavsfail) was sent in the request. P | [Partial approval](/guides/advanced-concepts/partial-approval) | A partial approval has occurred. Check for the approved amount. R | Voice referral | The transaction requires a voice referral. [blank]| Status is unknown | The approval status is unknown. X | Expired card | There is an error condition due to the card being expired. S | SCA Online PIN required | The contactless EMV transaction requires strong customer authentication to continue. The terminal must gather the online PIN if supported by the device form factor and CVM list then resubmit the transaction request. I | SCA Interface switch required | The contactless EMV transaction requires strong customer authentication to continue. The terminal must look at the form factor indicator to determine if the transaction should be declined, switched to EMV contact or tapped again using CDCVM. Enum: "A", "C", "D", "e", "f", "P", "R", "X", "S", "I" - `result.transaction.saleFlag` (string) Specifies a transaction is a sale (‘S’) or credit (‘C’). In an [Invoice Information](/apis/payments-platform-rest/openapi/transactions/getinvoice) request, an 'A' may be returned to differentiate an authorization from a sale. Enum: "A", "C", "S" - `result.receipt` (array) Array of receipt key/value pairs that should be printed on the receipt. - `result.receipt.key` (string) The identifier the interface vendor can use to programmatically determine where to print a specific value. Example: "ApplicationIdentifier" - `result.receipt.printName` (string) The label that relates to the field. When present in the response, this must be printed to the left of the . Example: "AID" - `result.receipt.printValue` (string) The value that relates to the field. This must be printed to the right of the . Example: "AID" - `result.server` (object) - `result.server.name` (string) The name of the server that processed the request. ## Response 400 fields (application/json): - `result` (array) - `result.error` (object) - `result.error.code` (integer) Code indicating the type of error that occurred. Refer to the [Error Codes](/guides/appendices/error-codes) section of this document for more details. - `result.error.severity` (string) Severity level of the error. | Severity | Description | | -------- | ---------------------------------------------------------------- | | Info | Action not required - Data input/formatting is incorrect | | Error | Action may be required - Communication, timeout or network issue | | Alert | Action required - System issue | Enum: "Info", "Error", "Alert" - `result.error.shortText` (string) Abbreviated error message that is always returned if an error condition exists - `result.error.longText` (string) Extended error message that is returned if an error condition exists. - `result.error.primaryCode` (integer) Code indicating the type of error that occurred. Refer to the [Error Codes](/guides/appendices/error-codes) section of this document for more details. - `result.error.secondaryCode` (integer) This code supplements the code specified in the field to provide additional information about the error that occurred. - `result.lighthouse` (object) - `result.lighthouse.data` (string) Base64 encoded JSON formatted data that will be returned from Lighthouse to be passed back to SkyTab. This data will contain variable information. - `result.server` (object) - `result.server.name` (string) The name of the server that processed the request. ## Response 504 fields (application/json): - `result` (array) - `result.error` (object) - `result.error.code` (integer) Code indicating the type of error that occurred. Refer to the [Error Codes](/guides/appendices/error-codes) section of this document for more details. - `result.error.severity` (string) Severity level of the error. | Severity | Description | | -------- | ---------------------------------------------------------------- | | Info | Action not required - Data input/formatting is incorrect | | Error | Action may be required - Communication, timeout or network issue | | Alert | Action required - System issue | Enum: "Info", "Error", "Alert" - `result.error.shortText` (string) Abbreviated error message that is always returned if an error condition exists - `result.error.longText` (string) Extended error message that is returned if an error condition exists. - `result.error.primaryCode` (integer) Code indicating the type of error that occurred. Refer to the [Error Codes](/guides/appendices/error-codes) section of this document for more details. - `result.error.secondaryCode` (integer) This code supplements the code specified in the field to provide additional information about the error that occurred. - `result.lighthouse` (object) - `result.lighthouse.data` (string) Base64 encoded JSON formatted data that will be returned from Lighthouse to be passed back to SkyTab. This data will contain variable information. - `result.server` (object) - `result.server.name` (string) The name of the server that processed the request.