Create checkout
curl --request POST \
--url https://sg.sandbox.api.reap.global/agentic/checkouts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--header 'Reap-Version: <reap-version>' \
--data '
{
"quoteId": "<string>",
"enrollmentId": "<string>",
"presentation": {
"type": "REDIRECT",
"returnUrl": "<string>"
}
}
'const options = {
method: 'POST',
headers: {
'Reap-Version': '<reap-version>',
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
quoteId: '<string>',
enrollmentId: '<string>',
presentation: {type: 'REDIRECT', returnUrl: '<string>'}
})
};
fetch('https://sg.sandbox.api.reap.global/agentic/checkouts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://sg.sandbox.api.reap.global/agentic/checkouts"
payload = {
"quoteId": "<string>",
"enrollmentId": "<string>",
"presentation": {
"type": "REDIRECT",
"returnUrl": "<string>"
}
}
headers = {
"Reap-Version": "<reap-version>",
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "<string>",
"status": "REQUIRES_ACTION",
"quoteId": "<string>",
"enrollmentId": "<string>",
"nextAction": {
"type": "REDIRECT",
"url": "<string>",
"expiresAt": "<string>"
},
"amount": {
"amount": 123,
"currency": "<string>"
}
}{
"error": {
"code": "AGENTIC_REQUEST_REJECTED",
"message": "<string>",
"detail": {}
}
}{
"error": {
"code": "AGENTIC_PAYMENTS_NOT_ENABLED",
"message": "<string>",
"detail": {}
}
}{
"error": {
"code": "AGENTIC_RESOURCE_NOT_FOUND",
"message": "<string>",
"detail": {}
}
}{
"error": {
"code": "AGENTIC_SERVICE_UNAVAILABLE",
"message": "<string>",
"detail": {}
}
}Agentic
Create checkout
Opens the payment for an unexpired quote against an ACTIVE enrollment, whose stored card and owner are used for the charge. The response carries a redirect to a Reap-hosted approval page where the user reviews the order and approves the payment. After approval the user returns to presentation.returnUrl and Reap completes the merchant checkout.
POST
/
agentic
/
checkouts
Create checkout
curl --request POST \
--url https://sg.sandbox.api.reap.global/agentic/checkouts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--header 'Reap-Version: <reap-version>' \
--data '
{
"quoteId": "<string>",
"enrollmentId": "<string>",
"presentation": {
"type": "REDIRECT",
"returnUrl": "<string>"
}
}
'const options = {
method: 'POST',
headers: {
'Reap-Version': '<reap-version>',
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
quoteId: '<string>',
enrollmentId: '<string>',
presentation: {type: 'REDIRECT', returnUrl: '<string>'}
})
};
fetch('https://sg.sandbox.api.reap.global/agentic/checkouts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://sg.sandbox.api.reap.global/agentic/checkouts"
payload = {
"quoteId": "<string>",
"enrollmentId": "<string>",
"presentation": {
"type": "REDIRECT",
"returnUrl": "<string>"
}
}
headers = {
"Reap-Version": "<reap-version>",
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "<string>",
"status": "REQUIRES_ACTION",
"quoteId": "<string>",
"enrollmentId": "<string>",
"nextAction": {
"type": "REDIRECT",
"url": "<string>",
"expiresAt": "<string>"
},
"amount": {
"amount": 123,
"currency": "<string>"
}
}{
"error": {
"code": "AGENTIC_REQUEST_REJECTED",
"message": "<string>",
"detail": {}
}
}{
"error": {
"code": "AGENTIC_PAYMENTS_NOT_ENABLED",
"message": "<string>",
"detail": {}
}
}{
"error": {
"code": "AGENTIC_RESOURCE_NOT_FOUND",
"message": "<string>",
"detail": {}
}
}{
"error": {
"code": "AGENTIC_SERVICE_UNAVAILABLE",
"message": "<string>",
"detail": {}
}
}Authorizations
API key as Bearer token
Headers
API version (YYYY-MM-DD)
Available options:
2025-02-14 Example:
"2025-02-14"
Unique key for safely retrying this request. Up to 255 characters; we recommend a UUIDv4. The first request executes and its response is cached; subsequent requests with the same key replay the cached response (24h retention).
Required string length:
1 - 255Body
application/jsonapplication/x-www-form-urlencodedmultipart/form-data
Response
Response for status 200