---
updatedAt: 2026-03-19T13:35:40.000Z
agentTools:
  projectIndex: https://developers.hover.to/llms.txt
---

# Generate Access Token

Use this endpoint to generate an Access Token which is used to Authenticate to access Hover data.

## Overview

This endpoint is used to exchange an authorization code or refresh token for a new `access_token` and `refresh_token` pair. It is a crucial step in authenticating your application with the Hover API using the OAuth 2.0 protocol.

The `access_token` is a credential that allows your application to securely make requests to the Hover API on behalf of a user. `access_token`s have a limited lifespan, so a `refresh_token` is provided to obtain new `access_token`s without requiring the user to re-authenticate.

For more details on how to use this endpoint, please consult our[ guide on authenticating with Hover's API](https://developers.hover.to/v3/docs/oauth-20-authentication).

## Obtaining an Access Token

This endpoint is for obtaining your initial access token.  After successfully obtaining an `authorization_code` (from the [Authorization Code Request step](https://developers.hover.to/v3/reference/get-authorization-code)), you will use this endpoint to acquire your initial `access_token` and `refresh_token` pair.

**Access Tokens are valid for 2 hours from when they are generated**. Once expired, your API requests with the existing token will throw an error. You must use your existing refresh token to obtain a [new access/refresh token pair](https://developers.hover.to/reference/refresh-access-token).

## Sample Request Body

This is a sample request body to obtain API credentials:

```json Get Access Token Sample Request Body
{
  "grant_type": "authorization_code",
  "code": "your_authorization_code_here",
  "redirect_uri": "your_redirect_uri_here",
  "client_id": "your_client_id_here",
  "client_secret": "your_client_secret_here"
}
```

## Sample Response Body

The response body, when successful, will include your` access_token`to make subsequent API requests and the `refresh_token`.

```json Get Access Token Sample Response
{
    "access_token": "eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOnsi",
    "token_type": "Bearer",
    "expires_in": 7200,
    "refresh_token": "q90aLQhunR_JZ1MQ0kivxtAV",
    "scope": "all",
    "created_at": 1750191095,
    "owner_id": 785,
    "owner_type": "orgs"
}
```

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "hover-api-v3",
    "version": "3"
  },
  "servers": [
    {
      "url": "https://hover.to"
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "oauth2",
        "flows": {}
      }
    }
  },
  "security": [
    {
      "sec0": []
    }
  ],
  "paths": {
    "/oauth/token": {
      "post": {
        "summary": "Generate Access Token",
        "description": "",
        "operationId": "generate-access-token",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "grant_type": {
                    "type": "string",
                    "description": "Required. To obtain a new access token, the required value is `authorization_code`",
                    "default": "authorization_code"
                  },
                  "client_id": {
                    "type": "string",
                    "description": "Required. The Client ID of your integration",
                    "default": "asdf1c546a2d48e41h2"
                  },
                  "client_secret": {
                    "type": "string",
                    "description": "Required. The Client Secret of your integration.",
                    "default": "8w4e2224s3s5d4f3s"
                  },
                  "redirect_uri": {
                    "type": "string",
                    "description": "Required. The Redirect URI of your integration.",
                    "default": "https://hover.to"
                  },
                  "code": {
                    "type": "string",
                    "description": "The authorization code obtained in the `Get Authorization Code` process.",
                    "default": "asdfasd1mskdhj44545"
                  }
                }
              }
            },
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "properties": {
                  "grant_type": {
                    "type": "string",
                    "description": "Required. To obtain a new access token, the required value is `authorization_code`",
                    "default": "authorization_code"
                  },
                  "client_id": {
                    "type": "string",
                    "description": "Required. The Client ID of your integration",
                    "default": "asdf1c546a2d48e41h2"
                  },
                  "client_secret": {
                    "type": "string",
                    "description": "Required. The Client Secret of your integration.",
                    "default": "8w4e2224s3s5d4f3s"
                  },
                  "redirect_uri": {
                    "type": "string",
                    "description": "Required. The Redirect URI of your integration.",
                    "default": "https://hover.to"
                  },
                  "code": {
                    "type": "string",
                    "description": "The authorization code obtained in the `Get Authorization Code` process.",
                    "default": "asdfasd1mskdhj44545"
                  }
                }
              }
            }
          }
        },
        "deprecated": false,
        "security": [
          {
            "sec0": []
          }
        ]
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```