Overview
The Checkout API streamlines cart preparation with:- Shipping Information: Set delivery addresses for shipments
- Consent Management: Handle privacy policies, terms of service, and marketing preferences
- Multi-Shipment Support: Different shipping addresses per shipment
- Validation: Real-time address validation
Checkout Flow
A typical checkout process follows these steps:1
Set Shipping Information
Provide delivery address for each shipment requiring it
2
Review Consents
Present required and optional consent options
3
Accept Consents
Customer agrees to terms and policies
4
Process Payment
Use Payment Processing endpoints to complete order
Available Endpoints
Set Shipping Info
Configure delivery addresses for shipments
Set Billing Info
Store billing address for future reference
Get Consents
Retrieve required and optional consent options
Set Consents
Submit customer consent selections
Shipping Information
Multi-Address Support
V2 allows different shipping addresses per shipment:Address Validation
The API performs real-time validation:- Format Checking: Ensures all required fields are present
- Deliverability: Verifies address can receive shipments
- Standardization: Returns standardized address format
Billing Information
The Set Billing Info endpoint stores billing address information for the cart. Payment processing is handled separately through the Payment Processing endpoints.Payment details and card information are never sent through the Checkout endpoints. Use the secure Payment Processing endpoints for handling sensitive payment data.
Consent Management
Types of Consents
The API handles various consent types:| Type | Required | Description |
|---|---|---|
TERMS_OF_SERVICE | Yes | Agreement to merchant’s terms |
PRIVACY_POLICY | Yes | Acknowledgment of data handling |
MARKETING_EMAIL | No | Permission for promotional emails |
MARKETING_SMS | No | Permission for text messages |
DATA_SHARING | No | Agreement to share data with partners |
Consent Flow Example
- Get Available Consents
- Submit Consent Selections
Complete Checkout Example
Here’s a full checkout flow:Validation & Error Handling
Common validation errors:Address Validation Errors
Address Validation Errors
Consent Errors
Consent Errors
Integration Considerations
Checkout State Management:
- Shipping info is stored per shipment
- Billing info applies to the entire order
- All required consents must be accepted
- Validate data before submission to avoid errors
Next Steps
After checkout completion:Payment Processing
Complete checkout with secure payment processing