- Retrieve Checkout Session
Retrieves a single Checkout Session by id.
The id is passed via the CheckoutSessionId request header. Returns the same envelope shape as Create and List — the current status, lastOpened/expiresAt timestamps, the latest event, and (once the customer has paid) lastTransaction.
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 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. An Access Token is the alias for the merchant account and interface being used.
Obtain one via an Access Token Exchange request, using an authToken and clientGuid.
curl -i -X GET \
https://api.shift4.com/api/rest/v1/checkoutsessions/retrieve \
-H 'AccessToken: YOUR_API_KEY_HERE' \
-H 'CheckoutSessionId: string' \
-H 'CompanyName: PAWS' \
-H 'InterfaceName: ForwardPOS' \
-H 'InterfaceVersion: 2.1'- Fixed Total
- Customer-chosen amount
{ "result": [ { "dateTime": "2024-05-21T09:18:23.283-07:00", "event": { "type": "checkout_session_created" }, "customer": { "id": "cust_oM1i4j7EsIY7W5vqqF76diGw", "emailAddress": "jordan.smith@example.com", "phoneNumber": "+12025550123", "phoneCountry": "US", "firstName": "Jordan", "middleName": "Riley", "lastName": "Smith", "addressLine1": "Evergreen Terrace 742", "postalCode": "94043", "addressCity": "Mountain View", "addressRegion": "CA", "addressCountry": "US" }, "paymentLink": { "id": "link_8kdskX8DZ8FR6W3acYPXiyAN" }, "checkoutSession": { "id": "chse_wMCUGVZgpf45fWHzKbYWMKmZ", "action": "payment", "clientSecret": "chcs_II2TvLWBrzFniRdjLpgo2zIflaTCzZ5BGPngPZEu0XasgwYRBCHEpyqE0tO9pYocvoOl8alO9w91CAeW0bl3nrTfO9JH4zFDt8pXB2eyoOpOBeuD3XuxPnGKOiTjor0D0vwRfdMR7moSj3K9yLDktQy6KcoZEa9SgP5DHiXg30L1X26EKy4XCxqBdeB4dcC4osPiXBwJqFfhKsKxG4RUD8I8CCeUfvbXnCVSokauaT0AUEk7pkF3TBgN3Q", "url": "https://pay.shift4.com/chse_wMCUGVZgpf45fWHzKbYWMKmZ", "status": "active", "redirectUrl": "https://example.com/checkout/complete", "allowSavedCards": true, "locale": "en", "lastOpened": "2024-05-21T09:18:23.283-07:00", "expiresAt": "2024-05-21T09:18:23.283-07:00", "collectBillingAddress": true, "collectShippingAddress": true, "customFieldsTitle": "Additional information", "customFieldsTitleTranslations": { … }, "customFields": [ … ], "staticFields": { … }, "capture": true, "vendorReference": "ref_123456789", "webhookUrl": "string", "lineItems": [ … ], "lastTransaction": { … }, "customerCreationPolicy": "create" }, "metadata": { "property1": "string", "property2": "string" } } ] }