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.
Shift4 Payment API (1.7.43)
https://api.shift4test.com/api/rest/v1/
https://api.shift4api.net/api/rest/v1/
Request
This function is used to process a request via the 3D Secure process without authorizing the payment. This will return the result of the 3D Secure process as well as the 3D Secure data that can then be used to process a payment via the Authorization or Sale/Purchase endpoint.
Integration Methods:
- Host Direct
See the Integration Methods and URLs Section sections of the Development Quick Start guide for details regarding each processing option.
Refers to the version of the program or application that is sending requests to Shift4. The following special characters are not allowed: $ % : ^ - ~ < > , ? “ ” ‘ ’ { } [ ] \ + =
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: $ % : ^ - ~ ` < > , ? “ ” ‘ ’ { } [ ] \ + =
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: $ % : ^ - ~ ` < > , ? “ ” ‘ ’ { } [ ] \ + =
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 authToken
and clientGuid
.
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
Object containing information regarding the amount being requested. The total
field within the object is required and specifies the amount being requested.
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 section for details.
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.
Note: For US and Canadian processing: Although the invoice number is sent as a JSON string it is a numeric value. No alpha characters are allowed.
For processing outside of the US and Canada alpha characters are allowed.
A free-form notes field that supports the use of HTML tags. This can be used for reference in Lighthouse Transaction Manager and is not sent to the authorization host. Escaped quotation marks should not be sent in the Notes field.
Optional field for information that can be searched in the merchant portal.
Unique transaction identification number generated by Shift4 to identify a specific risk transaction and a field that can be searched in LTM.
Conditional: must be sent if Risk Assessment was completed prior to processing the transaction.
The payment card number entered in an initial authorization/sale request. This field will always be masked when returned in a response.
Conditional: Send only when card data is manually entered or when using a token. This field should not be specified when using an encrypted device.
Card expiration date in MMYY format. This value should only be populated in the initial sale/authorization request.
Conditional: Send in the initial authorization/sale request
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.
Note: 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 card.present
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 card.present
.
Specifies a consumer’s first name. This field is used in AVS. If the interface sends this field, the value specified by the interface will be returned in the response, unless the API Option USECARDNAME is included in the request and a Commerce Engine or UTG-controlled PIN pad is in use. If the interface does not send the customer
object, the consumer's name will be returned in the customer
object if the name is present in the card's EMV or track data.
Specifies a consumer’s last name. This field is used in AVS. If the interface sends this field, the value specified by the interface will be returned in the response, unless the API Option USECARDNAME is included in the request and a Commerce Engine or UTG-controlled PIN pad is in use. If the interface does not send the customer
object, the consumer's name will be returned in the customer
object if the name is present in the card's EMV or track data.
Customer email address.
Public source IP Address where the request originates, not the IP Address of the web server.
Country calling code of the phone number.
Required when sending customer.phoneNumber
.
Cardholder’s street address exactly as it appears on their billing statement. This field is used in AVS.
Recommended for increasing the possibility of frictionless flow
Customer address city.
Recommended for increasing the possibility of frictionless flow
A level 2 country subdivision code according to ISO-3166-2.
Recommended for increasing the possibility of frictionless flow
Cardholder’s ZIP/postal code from their billing statement. This field is used in AVS. Do not include special characters.
Note: This field only allows alphanumeric characters (a-z, A-Z, 0-9). Special characters including - are not allowed. If you are sending in zip+4 you must not include the dash so 89134-1234 would be sent as 891341234
Recommended for increasing the possibility of frictionless flow
2 character ISO Country Code. See the ISO website for details.
Recommended for increasing the possibility of frictionless flow
Transaction currency code. See the Currency Codes section for details.
Note: This is currently supported when processing for a merchant outside of the US and Canada. If processing for a US or Canadian merchant then this field will be ignored and the transaction will process in the merchant's configured currency.
Indicates whether to initiate the 3D Secure authentication process
Value | Description |
---|---|
01 | Force 3D Secure authentication |
03 | Initiate 3D Secure according to the 3D Secure Adviser result |
Exact content of the HTTP accept headers.
Indicates whether the cardholder's browser has the ability to execute Java.
Value | Description |
---|---|
true | Cardholder's browser does have the ability to execute Java. |
false | Cardholder's browser does not have the ability to execute Java. |
Indicates whether the cardholder's browser has the ability to execute Javascript.
Value | Description |
---|---|
true | Cardholder's browser does have the ability to execute Javascript. |
false | Cardholder's browser does not have the ability to execute Javascript. |
Value representing the browser language as defined in IETF BCP47.
Value representing the bit depth of the colour palette for displaying images, in bits per pixel. Accepted values are:
Value | Description |
---|---|
1 | 1 bit |
4 | 4 bits |
8 | 8 bits |
15 | 15 bits |
16 | 16 bits |
24 | 24 bits |
32 | 32 bits |
48 | 48 bits |
Total height of the Cardholder's screen in pixels.
Total height of the Cardholder's screen in pixels.
Exact content of the HTTP user-agent header.
Dimensions of the challenge window that will be displayed to the cardholder. The issuer replies with content that is formatted to appropriately render in this window to provide the best possible user experience. Preconfigured window sizes are given in “width x height” in pixels.
Value | Description |
---|---|
01 | 250 x 400 |
02 | 390 x 400 |
03 | 500 x 600 |
04 | 600 x 400 |
05 | Full screen |
Identifies the type of transaction being authenticated. The values are derived from ISO 8583.
Value | Description |
---|---|
01 | Goods / Service purchase |
03 | Check Acceptance |
10 | Account Funding |
11 | Quasi-Cash Transaction |
28 | Prepaid activation and Loan |
Indicates the type of channel interface being used to initiate the transaction.
Value | Description |
---|---|
01 | App-based (APP) |
02 | Browser (BRW) |
03 | 3DS Requestor Initiated (3RI) |
Indicates whether the Cardholder Shipping Address and Cardholder Billing Address are identical.
Value | Description |
---|---|
true | Shipping Address matches Billing Address |
false | Shipping Address does not match Billing Address |
Indicates whether a challenge is requested for this transaction. For example: For payment authentication, a merchant may have concerns about the transaction, and request a challenge.
Value | Description |
---|---|
01 | No preference |
02 | No challenge requested |
03 | Challenge requested by merchant |
04 | Challenge requested: Mandate |
05 | No Challenge Requested, transactional risk analysis is already performed |
06 | No Challenge Requested, Data share only |
07 | No Challenge Requested, SCA is already performed |
08 | No challenge requested (utilise whitelist exemption if no challenge required) |
09 | Challenge requested (whitelist prompt requested if challenge required)" |
Contains the merchant URL to which the browser should be redirected after the challenge session.
Conditional: must be sent if Risk Assessment was completed prior to processing the transaction.
API Options modify the request being made. See the API Options section for more information.
- Host Direct Test URL
https://api.shift4test.com/api/rest/v1/3dsecure/standalone
- Host Direct Production URL
https://api.shift4api.net/api/rest/v1/3dsecure/standalone
- Payload
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
{ "dateTime": "2022-05-04T09:18:23.283-07:00", "amount": { "total": 160 }, "currencyCode": "EUR", "customer": { "firstName": "John", "lastName": "Smith", "addressLine1": "65 Easy St", "city": "Las Vegas", "postalCode": "65144", "emailAddress": "firstname.lastname@email.com", "ipAddress": "63.57.84.101" }, "card": { "number": "4012000098765439", "expirationDate": 1225, "present": "N" }, "transaction": { "invoice": "730518", "notes": "Transaction notes are added here" }, "threeDSecure": { "initiate": "03", "browser": { "acceptHeader": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8", "javaEnabled": true, "javascriptEnabled": true, "language": "en-GB", "colorDepth": "48", "screenWidth": 1920, "screenHeight": 1080, "tz": -480 }, "headerContent": "userAgent header", "challengeWindowSize": "05", "transType": "01", "channel": "02" }, "completionUrl": "https://merchant.com/completion", "apiOptions": [ "ALLOWPARTIALAUTH" ] }
Request was processed
{ "result": { "dateTime": "2022-05-04T09:20:04.487-07:00", "amount": { "tax": 15, "total": 160 }, "currencyCode": "EUR", "card": { "entryMode": "M", "number": "XXXXXXXXXXXX1119", "present": "N", "securityCode": { "result": "M", "valid": "Y" }, "token": { "value": "8048471746471119" }, "type": "VS" }, "customer": { "firstName": "John", "lastName": "Smith", "addressLine1": "65 Easy St", "city": "Las Vegas", "postalCode": "65144", "emailAddress": "firstname.lastname@email.com", "ipAddress": "63.57.84.101" }, "merchant": { "mid": 15877, "name": "Merchant XYZ" }, "threeDSecure": { "trxId": "a7bbd49a-ffe6-49b2-8a92-541f0a3b053d", "cryptogram": "AAAAAAAA/COBt84dnIEcwAA3gAAGhgEDoLABAAhAgAABAAAALnNCLw==", "programProtocol": "2", "directoryServerTranId": "07e54000-2721-4df9-aa51-04fa0e079aa8", "ecommIndicator": "5" }, "server": { "name": "TM01CE" }, "transaction": { "authSource": "A", "avs": { "postalCodeVerified": "N", "result": "A", "streetVerified": "Y", "valid": "Y" }, "invoice": "730518", "responseCode": "A", "retrievalReference": "402F9H0230S0" }, "receipt": [ { "key": "CardEntryMode", "printName": "ENTRY METHOD", "printValue": "KEYED" }, { "key": "MaskedPAN", "printValue": "XXXXXXXXXXXX1119" }, { "key": "SignatureRequired", "printValue": "Y" }, { "key": "TransactionResponse", "printName": "Response", "printValue": "APPROVED" } ] } }
Request
This endpoint is utilized to send the status of the device fingerprint. This must be sent whenever the response to the 3D Secure Standalone results in a device fingerprint required.
Integration Methods:
- Host Direct
See the Integration Methods and URLs Section sections of the Development Quick Start guide for details regarding each processing option.
Refers to the version of the program or application that is sending requests to Shift4. The following special characters are not allowed: $ % : ^ - ~ < > , ? “ ” ‘ ’ { } [ ] \ + =
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: $ % : ^ - ~ ` < > , ? “ ” ‘ ’ { } [ ] \ + =
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: $ % : ^ - ~ ` < > , ? “ ” ‘ ’ { } [ ] \ + =
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 authToken
and clientGuid
.
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
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.
Note: For US and Canadian processing: Although the invoice number is sent as a JSON string it is a numeric value. No alpha characters are allowed.
For processing outside of the US and Canada alpha characters are allowed.
- Host Direct Test URL
https://api.shift4test.com/api/rest/v1/3dsecure/completion
- Host Direct Production URL
https://api.shift4api.net/api/rest/v1/3dsecure/completion
- Payload
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
{ "dateTime": "2022-05-04T09:20:04.487-07:00", "merchant": { "mid": 15877, "name": "Merchant XYZ" }, "transaction": { "invoice": "730518" }, "threeDSecure": { "trxId": "a7bbd49a-ffe6-49b2-8a92-541f0a3b053d", "compInd": "Y" } }
Transaction was processed
{ "result": { "dateTime": "2022-05-04T09:20:04.487-07:00", "amount": { "tax": 15, "total": 160 }, "currencyCode": "EUR", "card": { "entryMode": "M", "number": "XXXXXXXXXXXX1119", "present": "N", "securityCode": { "result": "M", "valid": "Y" }, "token": { "value": "8048471746471119" }, "type": "VS" }, "customer": { "firstName": "John", "lastName": "Smith", "addressLine1": "65 Easy St", "city": "Las Vegas", "postalCode": "65144", "emailAddress": "firstname.lastname@email.com", "ipAddress": "63.57.84.101" }, "merchant": { "mid": 15877, "name": "Merchant XYZ" }, "server": { "name": "TM01CE" }, "transaction": { "authorizationCode": "OK868Z", "authSource": "A", "avs": { "postalCodeVerified": "N", "result": "A", "streetVerified": "Y", "valid": "Y" }, "invoice": "730518", "responseCode": "A", "retrievalReference": "402F9H0230S0", "saleFlag": "S" }, "receipt": [ { "key": "CardEntryMode", "printName": "ENTRY METHOD", "printValue": "KEYED" }, { "key": "MaskedPAN", "printValue": "XXXXXXXXXXXX1119" }, { "key": "SignatureRequired", "printValue": "Y" }, { "key": "TransactionResponse", "printName": "Response", "printValue": "APPROVED" } ] } }