curl --request POST \
--url https://staging.crossmint.com/api/unstable/order-intents \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"amount": {
"currency": "USD",
"value": "150.00"
},
"description": "Weekly grocery purchases",
"expiresAt": "2030-12-31T23:59:59Z",
"merchant": {
"countryCode": "US",
"name": "Acme Store",
"url": "https://acme.example.com"
},
"paymentMethodId": "9f1a6b2c-3d4e-4f50-9a61-2b3c4d5e6f70"
}
'{
"amount": {
"available": "<string>",
"currency": "<string>",
"reserved": "<string>",
"spent": "<string>",
"total": "<string>"
},
"description": "<string>",
"expiresAt": "2024-01-15T10:30:00.000Z",
"orderIntentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"paymentMethodId": "<string>",
"rails": [
{
"credentialFormats": [
"card"
],
"error": {
"code": "<string>"
},
"rail": "encrypted-card",
"status": "error"
}
],
"status": "active",
"merchant": {
"countryCode": "<string>",
"name": "<string>",
"url": "<string>",
"acquirerBin": "<string>",
"categoryCode": "<string>"
},
"verificationConfig": {
"allowanceId": "<string>",
"environment": "production",
"publicApiKey": "<string>"
}
}Order Intents
Create Order Intent
Create a new order intent.
API scope required: order-intents.create
POST
/
unstable
/
order-intents
curl --request POST \
--url https://staging.crossmint.com/api/unstable/order-intents \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"amount": {
"currency": "USD",
"value": "150.00"
},
"description": "Weekly grocery purchases",
"expiresAt": "2030-12-31T23:59:59Z",
"merchant": {
"countryCode": "US",
"name": "Acme Store",
"url": "https://acme.example.com"
},
"paymentMethodId": "9f1a6b2c-3d4e-4f50-9a61-2b3c4d5e6f70"
}
'{
"amount": {
"available": "<string>",
"currency": "<string>",
"reserved": "<string>",
"spent": "<string>",
"total": "<string>"
},
"description": "<string>",
"expiresAt": "2024-01-15T10:30:00.000Z",
"orderIntentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"paymentMethodId": "<string>",
"rails": [
{
"credentialFormats": [
"card"
],
"error": {
"code": "<string>"
},
"rail": "encrypted-card",
"status": "error"
}
],
"status": "active",
"merchant": {
"countryCode": "<string>",
"name": "<string>",
"url": "<string>",
"acquirerBin": "<string>",
"categoryCode": "<string>"
},
"verificationConfig": {
"allowanceId": "<string>",
"environment": "production",
"publicApiKey": "<string>"
}
}Authorizations
API key required for authentication
The end user's JWT, sent as Authorization: Bearer <JWT> together with a client-side API key. Validated against the project's external JWT configuration.
Body
application/json
Show child attributes
Show child attributes
Required string length:
1 - 10000ISO 8601. A UTC offset is accepted. Fractional seconds are optional.
Example:
"2024-01-15T10:30:00.000Z"
Minimum string length:
1Show child attributes
Show child attributes
Response
201 - application/json
The order intent has been successfully created
Show child attributes
Show child attributes
ISO 8601. A UTC offset is accepted. Fractional seconds are optional.
Example:
"2024-01-15T10:30:00.000Z"
Pattern:
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$Minimum string length:
1- Option 1
- Option 2
- Option 3
- Option 4
- Option 5
- Option 6
Show child attributes
Show child attributes
Available options:
active, cancelled, expired Show child attributes
Show child attributes
Show child attributes
Show child attributes
Was this page helpful?

