---
updatedAt: 2026-06-11T16:01:06.000Z
---

Fetch the complete documentation index at: https://simpay-prod.readme.io/llms.txt. Use this file to discover all available pages before exploring further. Append .md to any documentation page URL to get its markdown version.

# Auth Token

Generate OAuth 2.0 access token using client credentials. The access token is valid for 60 minutes.

# Auth Token

> POST /v2/finance/auth-token/

> 📘 **The access token is valid for 60 minutes**

## Body Details

```json
{
  "client_id": "xxxxxxxxxxxxxxxxxxxxxxxxxx",
  "client_secret": "xxxxxxxxxxxxxxxxxxxxxxx"
}
```

| Parameter      | Description                                                                                       | Required |
| :------------- | :------------------------------------------------------------------------------------------------ | :------- |
| client\_id     | Public identifier for your application (used during the OAuth 2.0 authorization request)          | Yes      |
| client\_secret | Confidential secret for authentication. **Never** expose this in client-side code or public repos | Yes      |

## Response (200 OK)

```json
{
  "access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ0b2tlbl90eXBlIjoiYWNjZXNzIiwiZXhwIjoxNzEzMzAwOTMxLCJpYXQiOjE3MTMyOTczMzEsImp0aSI6Ijc2ZWI4ZTE5ZjM4YjQ4NmZiODdmNzNjNTdkMWVmNDJhIiwidXNlcl9pZCI6MjQ2fQ.5zekMa7CUj9p-MvNHns5ke4ZPhYV3Y1CLOsYL7hDUUo",
  "token_type": "Bearer"
}
```

| Field         | Type   | Description                                                                          |
| :------------ | :----- | :----------------------------------------------------------------------------------- |
| access\_token | String | JWT access token to be used in the `Authorization` header of subsequent API requests |
| token\_type   | String | Always `"Bearer"`. Use as: `Authorization: Bearer {access_token}`                    |

## Error Responses

### 400 Bad Request

```json
{
  "error": "invalid_client",
  "error_description": "Invalid client credentials"
}
```

### 401 Unauthorized

```json
{
  "detail": "Account is disabled"
}
```

## Related Documentation

* [HMAC Documentation](hmac-documentation.md) - Implement HMAC-SHA512 signatures for secure requests
* [Authentication API Overview](index.md) - Complete authentication guide

# OpenAPI definition

```json
{
  "openapi": "3.0.0",
  "info": {
    "version": "3.0.0",
    "title": "Banking & PIX API",
    "description": "Complete API documentation for the banking and PIX payment platform."
  },
  "servers": [
    {
      "url": "https://api.somossimpay.com.br/"
    }
  ],
  "security": [],
  "tags": [
    {
      "name": "Authentication-API",
      "description": "Authentication-API endpoints"
    }
  ],
  "paths": {
    "/v2/finance/auth-token/": {
      "post": {
        "operationId": "post_auth_token",
        "summary": "Auth Token",
        "description": "Generate OAuth 2.0 access token using client credentials. The access token is valid for 60 minutes.",
        "tags": [
          "Authentication-API"
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "access_token": {
                      "type": "string",
                      "description": "JWT access token to be used in the Authorization header"
                    },
                    "token_type": {
                      "type": "string",
                      "description": "Always Bearer"
                    },
                    "expires_in": {
                      "type": "integer",
                      "description": "Token lifetime in seconds (3600)"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad request - Invalid credentials"
          },
          "401": {
            "description": "Unauthorized - Account disabled"
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "client_id": {
                    "type": "string",
                    "description": "Public identifier for your application"
                  },
                  "client_secret": {
                    "type": "string",
                    "description": "Confidential secret for authentication"
                  }
                },
                "required": [
                  "client_id",
                  "client_secret"
                ]
              }
            }
          }
        }
      }
    }
  },
  "x-readme": {
    "explorer-enabled": false,
    "proxy-enabled": true,
    "samples-languages": [
      "curl",
      "python",
      "javascript",
      "java",
      "go"
    ]
  }
}
```