Skip to main content
POST
/
dev
/
v1
/
checkout
/
sessions
Create checkout session
curl --request POST \
  --url https://api.shoppex.io/dev/v1/checkout/sessions \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "product": {
    "name": "<string>",
    "quantity": 2
  },
  "amount": 1.01,
  "currency": "<string>",
  "customer_email": "[email protected]",
  "success_url": "<string>",
  "cancel_url": "<string>",
  "metadata": {},
  "gateway": "<string>",
  "gateways": [
    "<string>"
  ],
  "crypto_gateway": "<string>",
  "white_label": true,
  "confirmations": 2,
  "customer_id": "<string>"
}
'
{
  "data": {
    "id": "<string>",
    "url": "<string>",
    "status": "<string>",
    "amount": 123,
    "currency": "<string>",
    "customer_email": "<string>",
    "success_url": "<string>",
    "cancel_url": "<string>",
    "created_at": 123,
    "expires_at": "<string>",
    "checkout_url": "<string>",
    "session_id": "<string>"
  }
}

Authorizations

Authorization
string
header
required

Use your Shoppex API key in the Authorization header.

Body

product
object
required
amount
number
required
Required range: x >= 0.01
currency
string
required
Required string length: 3
customer_email
string<email>
required
success_url
string
cancel_url
string
metadata
object
gateway
string
gateways
string[]
crypto_gateway
string
white_label
boolean
confirmations
number
Required range: x >= 1
customer_id
string

Response

Successful response

data
object
required