Sample GET Token Response Message:
{ "ExpireAt": "2014-12-19T16:05:19.001Z", "APIToken": "dcfdcbba-a15e-4a5f-9388-d2db642b314f", "CredentialType": 1 } |
- The ExpireAt field indicates in UTC when the API Token will expire. This can be used as a check to indicate when the Token will expire and avoid receiving errors from our API.
- The APIToken should be extracted and placed in the header along with your UserName for all subsequent API calls.
- The CredentialType field is not needed, and only indicates whether you are using Test or Live API Keys.
Please note:
You can use an API Token for multiple orders/requests, while it is valid. Some developers have implemented Trustev by setting a timer to request a Token every 30 minutes. This is an option if convenient for your Site set up and will reduce calls to the Trustev API.
Comments