Authentication
Use these APIs to create your user account and get bearer token

Create User
post
Creates a New User
Body
usernamestringOptionalExample:
gandalf_the_greypasswordstringOptionalExample:
i_love_hobbitsfirst_namestringOptionalExample:
Gandalflast_namestringOptionalExample:
GreyemailstringOptionalExample:
[email protected]mobile_numberintegerOptionalExample:
9999999999profilestring · binaryOptional
Responses
200
Successful response
application/json
400
unexpected error
application/json
post
/api/v1/user/create/POST /api/v1/user/create/ HTTP/1.1
Host: prod.server.tryonlabs.ai
Content-Type: application/json
Accept: */*
Content-Length: 179
{
"username": "gandalf_the_grey",
"password": "i_love_hobbits",
"first_name": "Gandalf",
"last_name": "Grey",
"email": "[email protected]",
"mobile_number": "9999999999",
"profile": "binary"
}{
"success": "User created successfully."
}Get Auth. Token
post
Generates an access token for your account.
You'll need the access token for subsequent APIs
Body
usernamestringOptionalExample:
gandalf_the_greypasswordstringOptionalExample:
i_love_hobbitsResponses
200
Successful response
application/json
401
unexpected error
application/json
post
/api/token/POST /api/token/ HTTP/1.1
Host: prod.server.tryonlabs.ai
Content-Type: application/json
Accept: */*
Content-Length: 59
{
"username": "gandalf_the_grey",
"password": "i_love_hobbits"
}{
"refresh": "xxxx-xxxxxxxxxx-access-token-xxxxxxxxxxx-xxxxxxxxxxx",
"access": "xxxx-xxxxxxxxxx-access-token-xxxxxxxxxxx-xxxxxxxxxxx"
}Get User
get
API to get your user account details.
Use your access_token as Bearer Auth Token to get these details
Authorizations
Responses
200
Successful response
application/json
401
unexpected error
application/json
get
/api/v1/user/get/GET /api/v1/user/get/ HTTP/1.1
Host: prod.server.tryonlabs.ai
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"id": "xxxxxxxxxx",
"username": "gandalf_the_grey",
"first_name": "Gandalf",
"last_name": "Grey",
"profile": "null",
"profile_url": "null",
"email": "[email protected]",
"mobile_number": "9999999999",
"password": "<encrypted_password>",
"created_on": "2024-08-28T19:58:19.585432Z",
"credits": 20
}Last updated