Authentication
This API allows you to retrieve the authenticated user's information by providing the API key.
Endpoint
See guidelines on how to generate or obtain your API Key
Authentication
You must provide an API key as a query parameter to authenticate the request. The key is used to identify and authorize the user making the request.
Query Parameters
api_key
(required): The API key for authenticating the request. You can obtain this from the Panda IDX dashboard.
Request Examples
Response
The API returns a JSON object containing the authenticated user's information. The token is not included, but the user's account details are returned.
Response Fields
Field | Type | Description |
---|---|---|
_id | String | The unique identifier of the authenticated user. |
email | String | The email address of the authenticated user. |
name | String | The full name of the authenticated user. |
role | String | The role of the authenticated user (e.g., user, admin). |
createdAt | String | The date and time when the user was created (ISO 8601 format). |
updatedAt | String | The date and time when the user's information was last updated. |
domain | String | The domain associated with the authenticated user. |
Example Response
Errors
In the case of an error, the API will return an appropriate HTTP status code and an error message.
Error Codes
HTTP Code | Error Type | Description |
---|---|---|
401 | Unauthorized | The API key is invalid or missing. |
500 | ServerError | An internal server error occurred. |
Example Error Response
Notes
- Ensure that the API key provided is valid and belongs to an authenticated user.