Authentication
All APIs take an token param in the Authorization header. These key are associated with a user and allow permission to the user to request the API.
Signature Request
Send a POST request to http://52.220.113.182:8000/
by providing these arguments as application/json
with request payload:
Sign In
{
"email" : "email",
"password" : "password"
}
You will get a response similar to this:
{
"activated": {
"id": 52,
"name": "name",
"username": "username",
"company": "company",
"email": "email",
"status_aktif": 1,
"uuid": "uuid"
},
"message": "success",
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE2NDQzODM4NjEsImlzcyI6IjUyIn0.tAx9tAMfmPeLGaU0XZOlP8yhD9K4kLQX2--wUNqf_C8",
"username": "username",
"uuid": "uuid"
}
Construct Authorization Key
After you get the signature response contains token
, you can start to construct your authorization key with this format:
Authorization=Bearer {YOUR_TOKEN}
Token for AI services
You can't use the AI service API if you haven't got a special token that is sent with the image or video data along with some supporting parameters. to get it you must first create a token.
Do POST request http://52.220.113.182:8000/createtoken?uuid="your uuid"
{
"message": "success",
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE2NDQzODM4OTUsImlzcyI6IjUyIn0.KNU3IlK3qM6A-2fG9jF8retDOF6DTpSRCr3v39hFeW4"
}
Last updated