This outlines how to obtain an Authorisation Token for the SwiftPOS API.
The content and related topics are targeted at Resellers and 3rd Party Application (3PA) integrators who have a sound knowledge of and experience with SwiftPOS. For further information or assistance, please contact your SwiftPOS Reseller or SwiftPOS Support.
Subjects
How To Get An Authorisation Token
Before any SwiftPOS API calls can be successfully issued an Authorisation Token must be obtained. Previously, using the local WebAPI in conjunction with IIS, this would have been referred to as the API Key. To do this now:
- Using Swagger, issue an Authorisation request. The format of the request should look something like this:
Request: { “ClerkId”:”0″, (Clerk with Cloud Connectivity Permissions) “ClientId”:”clientId”, (This is the Cloud Client Id located in Backoffice> Administration> Cloud Connectivity> Locations) “CustomerId”:”00000000″, (Customer Number located in Backoffice>Tools>Registration) “Identity”:”unencrypted connect identity”, (Key for the integrator in Venue Manager>Connect>Integrator Name:) “Signature”:”connect signature” (Name of integrator in Venue Manager> Connect. For example MPowerApos) } |
Where:
- ClerkId – Refers to the SwiftPOS Clerk ID that will be associated with all SwiftPOS API requests.
- ClientId – Refers to the Cloud Client ID generated when the Location was activated.
- CustomerId – Refers to the Customer ID associated with the SwiftPOS registration.
- Identity – Refers to the Integrator Key provided by the Reseller or SwiftPOS Support.
- Signature – Refers to the name associated with the Integrator Key above.
Notes …
To test using Swagger in a test environment, refer to How To Test Using Swagger (For Resellers Only).
- Once the request is executed/issued and is successful, an Authorisation Token will be returned in the response. The response returned should look something like this:
Response: { ”AuthorizationToken”: ”eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.xxxxxxxxxxx” } |
- The same Token should then be used in all SwiftPOS API requests going forward.
Notes …
The Authorisation Token returned (as per above) will expire after 12 hours.
This completes HOW TO OBTAIN AN AUTHORISATION TOKEN for the SwiftPOS API.