Start a sale transaction in a mobile app
To create a multi-use or durable card token (id
) when starting a sale transaction in mobile app:
Add the
create-token
field with a value oftrue
to the request body when calling the mobile transaction API endpoint to start a sale transaction in mobile app.
{
"type": "SALE",
"amount": "0.00",
"create-token": "true"
"software-type": "My Cool Software"
"software-type-version": "1.0",
"billing":
{
"zip": "85284"
}
}
Use the POST method to call the
rest/v2/mobile/transactions/sale
endpoint.
The API returns the following response:
{
"code": "200",
"status": "success",
"exchange-id": "ID-clearent-mobile-jwt-1-e4795490-49d8-4302-b2c6-fc46ea001bc9",
"links": [
{
"rel": "transaction",
"href": "/rest/v2/transactions?id=118810621",
"id": "118810621"
},
{
"rel": "token",
"href": "/rest/v2/tokens/1100000900023211111",
"id": "1100000900023211111"
}
],
"payload": {
"transaction": {
"amount": "15.55",
"id": "118810621",
"created": "2025-05-08 18:56:50.930",
"type": "SALE",
"result": "APPROVED",
"card": "XXXXXXXXXXXX1111",
"authorization-code": "TAS475",
"batch-string-id": "63",
"display-message": "Transaction approved",
"result-code": "000",
"exp-date": "1229",
"software-type": "Sally's Seashell Shore Software",
"card-type": "VISA",
"last-four": "1111",
"merchant-id": "YOUR MID",
"terminal-id": "10011111",
"create-token": true
},
"payloadType": "transaction"
}
}
The API response includes links
array with the following fields:
Name
Data type
Description
rel
String
Indicates the type of resource the link refers to.
Common values are:
transaction
token
href
String (URI)
The relative URI to access the card token.
id
String
The unique multi-use or durable card token ID.
PreviousCreating multi-use or durable card tokens (token-id or id)NextAuthorize a transaction in a mobile app
Last updated
Was this helpful?