Authentication
In order to work with our api you need to use token. To retrieve new token you should use the endpoint below.
Authorizations
Body
passwordstringRequiredExample:
Password
BIK165*
Responses
200
Success response
application/json
401
Unauthorized response
application/json
post
POST /v2/users/login HTTP/1.1
Host: gw.new.skladon.net
authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 47
{
"username": "[email protected]",
"password": "BIK165*"
}
{
"statusCode": 200,
"message": "text",
"data": {
"token": "eaifsagf5a44f56s4rfsd4f1a5s4f5as1f5a1s5fas5fAS5fASf",
"expiresIn": 1715673259,
"user": {
"id": 1,
"name": "Jon",
"surname": "Doe",
"email": "[email protected]"
}
}
}
Token in the response is valid till unix timestamp defined in expiresIn response atributte. The token should be used within the period. It is highly adviced to save token for later usage as it reduces API usage.
Token is valid before it expires. There can be theoretically more valid tokens for one user at the time, but it is not recommended and requesting too many tokens will be forbidden in the future.
Last updated