Skip to content

Get checkout url

POST
/carts/{cartId}/checkoutUrl
curl --request POST \
--url https://myshop.com/shopgate/v1/carts/example/checkoutUrl \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "userId": "example" }'

Generates a checkout URL for the app with a token. This URL opens in the app in a separate tab, logs the user in, and transfers the cart.

cartId
required
string
object
userId
required
string
Examplegenerated
{
"userId": "example"
}
Media typeapplication/json
object
output
required
object
url
required

A unified resource link.

string
expires

An optional date-time-string in the format ISO 8601 (YYYY-MM-DDTH:i:s.fZ). The URL does not expire if this field is not set. The returned timezone is always UTC (+00:00).

string
Example
{
"url": "https://myShop.com/checkout/shopgate?token=1234567890",
"expires": "2018-05-30T23:09:20.481Z"
}