Get a user
GET
/space/user/{id}
const url = 'https://api.aelyst.ai/v1/space/user/example';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api.aelyst.ai/v1/space/user/example \ --header 'Authorization: Bearer <token>'Retrieve information about a user.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”id
required
string
User ID.
Responses
Section titled “Responses”Media typeapplication/json
object
id
required
User ID.
integer
firstName
required
string
lastName
required
string
email
required
string
role
required
User role in the workspace.
string
team
required
object
id
ID of the team.
integer
name
Name of the team.
string
restrictions
required
Any of:
Constants representing the user restrictions at the workspace-level.
Array<string>
Example
{ "id": 123, "firstName": "John", "lastName": "Wick", "email": "test@example.com", "role": "agent", "team": { "id": 123, "name": "Customer Support" }, "restrictions": [ "restrict_data_export" ]}Media typeapplication/json
object
code
integer
message
string
Example
{ "code": 400, "message": "Validation error."}Media typeapplication/json
object
code
integer
message
string
Example
{ "code": 401, "message": "UN_AUTHORIZED"}Media typeapplication/json
object
code
integer
message
string
Example
{ "code": 429, "message": "Too Many Requests"}Headers
Section titled “Headers”Retry-After
number
Example
1Number of seconds until you can retry the request
X-RateLimit-Limit
number
Example
10Number of request allowed for this end point
X-RateLimit-Remaining
number
Example
5Number of request remaining for this end point
Media typeapplication/json
object
code
integer
message
string
Example
{ "code": 500, "message": "Unexpected error occurred"}