Authorization Resources
This page documents the resources related to Authorizations. For the complete list of all resources, see Resources.
Authorization
Authorization is a JSON:API resource representing a card authorization. Top-level fields:
| Name | Type | Description |
|---|---|---|
| id | string | Identifier of the authorization resource. |
| type | string | Type of the resource. The value is always authorization. |
| attributes | JSON Object | JSON object representing the authorization data. |
| relationships | JSON:API Relationships | Describes relationships between the authorization and other resources. |
Attributes
| Name | Type | Description |
|---|---|---|
| createdAt | RFC3339 Date string | The date the resource was created. |
| amount | integer | The amount (cents) of the authorization. |
| cardLast4Digits | string | The last 4 digits of the card number. |
| status | string | The status of the authorization. One of Authorized, Completed, Canceled, Declined. |
| declineReason Optional | string | Optional. The reason the authorization was declined. Available only when status is Declined. |
| declineDescription Optional | string | Optional. A human-readable description providing additional detail about the decline. Only present on some declined authorizations. |
| declinedBy Optional | string | Optional. The entity that declined the authorization. One of Visa, Org, or Unit. Available only when status is Declined. |
| merchant | object | Information about the merchant including name, type, and id. |
| recurring | boolean | Whether this is a recurring authorization. |
| tags | object | See Tags. |
Relationships
| Name | Type | Description |
|---|---|---|
| account | JSON:API Relationship | The Deposit Account. |
| customer | JSON:API Relationship | The Customer. |
| card | JSON:API Relationship | The Card. |
Example Authorization resource:
{
"type": "authorization",
"id": "1",
"attributes": {
"createdAt": "2021-06-24T08:10:08.081Z",
"amount": 2000,
"cardLast4Digits": "1234",
"status": "Authorized",
"merchant": {
"name": "Merchant name",
"type": "6012",
"id": "311204598883"
},
"recurring": false,
"tags": {}
},
"relationships": {
"account": {
"data": {
"type": "account",
"id": "10001"
}
},
"customer": {
"data": {
"type": "customer",
"id": "10000"
}
},
"card": {
"data": {
"type": "card",
"id": "7"
}
}
}
}