# Fetch current user

To retrieve information about the user holding the API token used, you should use the following query:

```graphql
query {
  me {
    id
    name
    email
    phone
    cpf
    cnpj
    birthday
    subscription {
      has_premium_features
      documents
      credits
    }
    organization {
      id
      uuid
      name
      cnpj
    }
  }
}
```

This is an example of a request you can make, and you can choose which data you want to receive or not. A more detailed documentation about all possible fields is available in [Altair](https://altair.autentique.com.br/).

#### Expected respose

```graphql
{
  "data": {
    "me": {
      "id": "1ac41a793ed27015abd0a381eb2846e1c3e7fe01",
      "name": "Mateus Zanella",
      "email": "mateus@autentique.com.br",
      "phone": null,
      "cpf": "012.345.678-90",
      "cnpj": null,
      "birthday": "01/01/2001",
      "subscription": {
        "has_premium_features": false,
        "documents": 20,
        "credits": 200
      },
      "organization": {
        "id": 179,
        "uuid": "91155c91-a411-4d93-b2a4-92e37548256b",
        "name": "Autentique",
        "cnpj": "29.423.653/0001-65"
      }
    }
  }
}
```

{% hint style="info" %}
You can check what each of these parameters means directly in the full GraphQL API documentation, available in the Docs menu of [Altair](https://altair.autentique.com.br/). If you're unsure how to do this, check out our tutorial on [*Using Altair*.](/api/integration-basics/altair.md)
{% endhint %}

{% hint style="info" %}
If Altair doesn’t help you integrate with the API, here are some examples of how to make these requests in other ways: <https://graphql.org/graphql-js/graphql-clients/>
{% endhint %}


---

# 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.autentique.com.br/api/queries/fetch-current-user.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.
