# User / Me

### Retrieve the authenticated user's data.

Interact with this API using a <mark style="color:red;">`GET`</mark> request only with your Token in headers. It informs you about the user's authentication status. If authenticated, the user's data is returned.

***

### **API Endpoint**

The following endpoint/URL should be used in order to access this API:

```
https://admin.gpt4business.ai/en/user/api/v1/me/
```

***

### **Request Headers**

The API must have the following request headers:

```
Content-Type: application/json
Authorization: Token <Your-API-Token>
```

***

### **Response Example**

Here's an example of the response:

JSON

```
{
    "message": "You are successfully logged in.",
    "data": {
        "id": 1241,
        "email": "john@domain.com",
        "first_name": "John",
        "last_name": "Smith"
    }
}
```

***

### **Error Handling**

It's essential to handle any non-200 status codes (e.g., 400, 404, 500) returned by the API. In the event of an error, the API will provide a structured response as shown below:

JSON

```
// Response when no token is provided
{
    "detail": "Authentication credentials were not provided."
}
        
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.gpt4business.ai/getting-started/apis/user-me.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
