Sign in with username and password
POST
Verifies a username and password and returns an access token. Send it as a Bearer token in the Authorization header, with your merchant identifier in X-TenantID, on later requests.
How to use it
- Send username and password, with your merchant identifier in the X-TenantID header; the user is looked up within that merchant.
- Use the returned token as a Bearer token in the Authorization header, with the same X-TenantID, on later calls.
X-TenantID*stringYour merchant's tenant code — the value typed in the Domain field on the iotoms login screen. See Concepts.
application/json- body
username*stringThe user's sign-in name.
password*stringThe user's password.
OK
*/*- response
token*stringAccess token for the merchant you signed in to, valid for one year. Send it as a Bearer token in the Authorization header of later requests.
Example Request
curl -X POST 'https://beta.iotoms.com/api/v1/auth/authenticate' \ -H 'X-TenantID: your-tenant-code' \ -H 'Content-Type: application/json' \ -d '{ "username": "string", "password": "string"}'Example Response
{ "token": "string"}