post https://global-api.au.edge.zip.co/merchant/checkouts
The first API call you will make in processing a Zip payment is a call to our /checkouts endpoint. This request is made once a customer chooses to use Zip as their payment method at checkout and will contain all order and customer information. The Zip API will then provide a response that includes a redirect url, allowing you to point the customer to the Zip checkout flow where they will complete their application or log in to their Zip account to confirm the payment.
/checkouts
Example Request
{
"shopper": {
"title": "Mr",
"first_name": "Test",
"last_name": "Tester",
"email": "firstname.lastname+{{$timestamp}}@domain.com",
"phone": "4154154455",
"billing_address": {
"first_name": "Test",
"last_name": "Tester",
"line1": "10 Spring St",
"city": "New York City",
"state": "New York",
"postal_code": "10001",
"country": "US"
}
},
"order": {
"reference": "ref_12345",
"amount": 200,
"currency": "USD",
"items": [
{
"name": "Awesome shoes",
"amount": 60,
"quantity": 1,
"type": "sku",
"reference": "001",
"image_uri": "https://yourimage.com/shoes_image_url",
"item_uri": "https://youritem.com/shoes_item_url"
},
{
"name": "Awesome pants",
"amount": 50,
"quantity": 1,
"type": "sku",
"reference": "002",
"image_uri": "https://yourimage.com/pants_image_url",
"item_uri": "https://youritem.com/pants_item_url"
}
],
"shipping": {
"pickup": false
}
},
"config": {
"redirect_uri": "https://localhost/zip_order_complete"
}
}
Important Notes
The checkout status is given by the state parameter in the response. The following are checkout status options:
- created
- approved
- completed
- expired