---
updatedAt: 2025-06-11T22:12:37.000Z
agentTools:
  projectIndex: https://docs.aluma.io/llms.txt
---

# Get access token

The `access_token` property is your access token. The `expires_in` property specifies the number of seconds in which this access token will expire. You should make a request for a new access token at this point, or a little before.

With every request to the API you should then specify the Authorization header as follows:

```text Header
Authorization: Bearer <MY_ACCESS_TOKEN>
```

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "authentication",
    "version": "3.0"
  },
  "servers": [
    {
      "url": "https://api.aluma.io/oauth"
    }
  ],
  "security": [
    {}
  ],
  "paths": {
    "/token": {
      "post": {
        "summary": "Get access token",
        "description": "",
        "operationId": "get-access-token",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "client_id",
                  "client_secret"
                ],
                "properties": {
                  "client_id": {
                    "type": "string",
                    "description": "An API key created in the admin portal"
                  },
                  "client_secret": {
                    "type": "string",
                    "description": "The secret for an API key created using the admin portal"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n  \"access_token\": \"<MY_ACCESS_TOKEN>\",\n  \"token_type\": \"Bearer\",\n  \"expires_in\": 86400\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "access_token": {
                      "type": "string",
                      "example": "<MY_ACCESS_TOKEN>"
                    },
                    "token_type": {
                      "type": "string",
                      "example": "Bearer"
                    },
                    "expires_in": {
                      "type": "integer",
                      "example": 86400,
                      "default": 0
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "400",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {}
                }
              }
            }
          }
        },
        "deprecated": false,
        "x-readme": {
          "code-samples": [
            {
              "language": "http",
              "code": "POST /oauth/token\nContent-Type: 'application/x-www-form-urlencoded'\n\nclient_id=<MY_CLIENT_ID>&client_secret=<MY_CLIENT_SECRET>"
            },
            {
              "language": "curl",
              "code": "curl https://api.aluma.io/oauth/token \\\n-d client_id=<MY_CLIENT_ID> \\\n-d client_secret=<MY_CLIENT_SECRET> \\\n-X POST"
            }
          ],
          "samples-languages": [
            "http",
            "curl"
          ]
        }
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": false,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```