- Support
- How do I log in to the API?
-
Account & Licensing
-
Installing & Updating
-
Power Pick Connections
-
Data Push & Data Pull
-
API
-
Reports
-
Snapshots & Dashboard
-
Workflows
How do I log in to the API?
Users
Before being able to access endpoints in the API, you'll need to have a username and password. The default user and password is available during the install process. Otherwise, you'll need to gain a username from a current authenticated user, either through the API, or the interface.
Access Tokens & Refresh Tokens
curl -L -g -X POST 'https://[yoursubdomain/IP].itempath.com/api/users/login' \
-H 'Content-Type: application/json' \
--data-raw '{
"username": "example_username",
"password": "example_password"
}'
A successful login will result in a status code of 200. If you receive a 404, double-check that your credentials are entered correctly.
On login, you'll receive a JWT access token and refresh token in the response. You'll want to save both tokens, which will be returned looking something like this:
{
"refreshToken": "refresh_token_goes_here",
"accessToken": "access_token_goes_here",
"username": "example_username",
"id": #
}
The access token will need to be passed in the header of every API request.
To keep ItemPath secure, the access token is only valid for 15 minutes. Using the refresh token will give you a new active access token.
Application Tokens
If the username/password has been tagged as a software connection, you'll be able to upgrade your access token to be non-expiring.
Read on about application tokens and more about JWT token authentication here.
Single-Sign-On
Azure MSAL SSO can also be set up for use with the ItemPath API. Check out this guide to see what's required for SSO configuration.
Resources
To learn more about ItemPath and see it in action, please book a demo with our sales team. In the meantime, here are some of our popular articles and key topics.
API
Authentication
The ItemPath API uses token-based authentication in order to validate user access. This is OAuth 2 standard. In order to make requests through the API, you must include an access token ...
API
How long does my token last?
When you log in using a regular ItemPath user, you receive two tokens. Access token: This token is used to authenticate your requests to the ItemPath API. It expires after 15 ...