---
title: "Get access token"
method: POST
path: "/v1/oauth/token"
tags: ["Authentication"]
---

# Get access token

`POST /v1/oauth/token`

## Request `access_token` and `refresh_token`
There are three ways to exchange parameters for tokens
1. Provide client credentials `client_id` and `client_secret`
2. Provide a `refresh_token`
3. Provide `username` and `password` (client credentials is preferred)

### Using grant_type=client_credentials
Only include params: `client_id`, `client_secret`, and `grant_type`.
* The `grant_type` param value must be: `client_credentials`

### Using grant_type=refresh_token
Only include params: `refresh_token` and `grant_type`.
* The `grant_type` param value must be: `refresh_token`
* The `refresh_token` must be a unexpired JWT token, from a prior client credential token grant.

### Using username and password
Only include params: `username` and `password`.

## Response
A successful response will provide `access_token` and `refresh_token` values.
* Use the `access_token` in your `Authorization` header as a "Bearer" token to make authenticated requests to the API. E.g. `GET https://api.kajabi.com/v1/me`
* Store the `refresh_token` to exchange for a new `access_token` when it expires.
* Tokens may be invalidated using the `v1/oauth/revoke` endpoint to "log out".
### Attributes
* `access_token` (string) - The access token for the API session
* `refresh_token` (string) - The refresh token for the API session
* `token_type` (string) - The type of token, always `Bearer`
* `expires_in` (integer) - The number of seconds the access token will be valid for

## Response `200`

Authentication succeeded

- OauthTokenResponse
  - `access_token` string
  - `refresh_token` string
  - `token_type` string
  - `expires_in` integer

## Other responses

- `400` — Bad Request
- `401` — Unauthorized

---

[API](https://skmtc.net/kajabi/apis/kajabi-api-v1.md) · [All operations](https://skmtc.net/kajabi/apis/kajabi-api-v1/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/kajabi/kajabi-api-v1/versions/a98d6d843191/schema)
