# GET /api/auth/me

Canonical URL: https://developers.iagenify.com/api/auth/me/
Language: en

`GET https://api.iagenify.com/api/auth/me`

Return the public account record for the authenticated caller.

Status: Bearer or API key · JSON · read

## HTTP request {#http}

```bash
curl https://api.iagenify.com/api/auth/me \
  -X GET \
  -H "Authorization: Bearer $IAGENIFY_TOKEN"
```

## JavaScript {#javascript}

```javascript
const response = await fetch("https://api.iagenify.com/api/auth/me", {
  method: "GET",
  headers: { Authorization: `Bearer ${process.env.IAGENIFY_TOKEN}` },
});
const result = await response.json();
if (!response.ok) throw new Error(result.error);
```

## Python {#python}

```python
import os, requests

response = requests.request(
    "GET",
    "https://api.iagenify.com/api/auth/me",
    headers={"Authorization": "Bearer " + os.environ["IAGENIFY_TOKEN"]},
    timeout=30,
)
response.raise_for_status()
result = response.json()
```

## Successful response {#response}

```javascript
{ ok: true, user: { id: "…", email: "…", credits: 120 } }
```

The user object is the account's public representation. Treat additional fields as optional unless they are documented for your integration.

## Errors {#errors}

| Code | Meaning |
| --- | --- |
| no_token | No supported Authorization header was sent. |
| invalid_token | The bearer token is invalid. |
| session_expired | The bearer session is no longer active. |
| user_not_found | The account is unavailable. |
