Get info about current user
GET/users/me
The info about the current user, can be used to show a user profile
Request
Query Parameters
The attributes that will be returned together with the user info
Header Parameters
Every request should has X-Domain Header, in the UUIDv4 format. The X-Domain can be get from the Tenant Integrations page
An X-API-KEY key is a token that a client provides with a X-API-SECRET when making API calls, used instead of the JWT
An X-API-SECRET key is a token that a client provides with a X-API-KEY when making API calls, used instead of the JWT
Responses
- 200
- 401
- 404
- 500
Successful get a user info
- application/vnd.api+json
- Schema
- Example (from schema)
Schema
data
object
The type of the user
The user id in a system
attributes
object
The user email registered in a system
The flag that shows that a user was not logged in to the system and doesn't change default password that receive in the registration email
The date and time when the user the last time logged in the system
The date and time of the user creation
The date and time when the user was changed
The date and time when the user was archived
relationships
object
profile
object
data
object
The id of the profile registered user
attributes
object
The user first name
The user last name
The user avatar in the JPG, PNG, and max size of 5Mb
The international phone code
The phone number of the user
This field is a string and can be used as a position of the user in the company or some other information
The date and time of the user creation
The date and time when the info in the user profile was changed
{
"data": {
"type": "users",
"id": "t318a31a-0bcf-48d1-9350-a6ae499007c0",
"attributes": {
"email": "example@domain.com",
"factory_password": true,
"active": true,
"last_login_date": "2016-01-01 12:00:00",
"reachable": true,
"created_at": "2016-01-01 12:00:00",
"updated_at": "2016-01-01 12:00:00",
"archived_at": "2016-01-01 12:00:00",
"auth_provider": "trisk_credentials"
},
"relationships": {
"profile": {
"data": {
"type": "users_profile",
"id": "t318a31a-0bcf-48d1-9350-a6ae499007c0",
"attributes": {
"first_name": "John",
"last_name": "Doe",
"avatar": "string",
"phone_code": "1",
"phone_number": "(111) 111-11-11",
"position": "string",
"created_at": "2016-01-01 12:00:00",
"updated_at": "2016-01-01 12:00:00"
}
}
}
}
}
}
Unauthorized exception
- application/vnd.api+json
- Schema
- Example (from schema)
Schema
The response status code of the error
The title of the error
{
"status": 401,
"code": 0,
"title": "Unauthorized"
}
The response body of the Not Found Error
- application/vnd.api+json
- Schema
- Example (from schema)
Schema
The response status code of the error
The title of the error
{
"status": 404,
"code": 404,
"title": "Not Found"
}
That means something has gone wrong on the server, and the server returns more specific about what the exact problem is
- application/vnd.api+json
- Schema
- Example (from schema)
Schema
The type of the error
The status of the error
The title of the error
The request body
The internal trace
{
"id": {},
"type": "errors",
"links": [
"string"
],
"status": 0,
"code": 0,
"title": "string",
"detail": "string",
"source": {},
"meta": {}
}