---
updatedAt: 2026-04-27T07:13:45.000Z
agentTools:
  projectIndex: https://developers.smartrecruiters.com/llms.txt
---

# Exchange credentials for an access token

SmartRecruiters will call this endpoint to exchange the credentials received from Partner for an access token.

# OpenAPI definition

```json
{
  "openapi": "3.0.1",
  "info": {
    "title": "Assessment Partner Application",
    "description": "Assessment Partner Application",
    "version": "1.0",
    "contact": {
      "name": "SmartRecruiters",
      "url": "https://developers.smartrecruiters.com"
    }
  },
  "servers": [
    {
      "url": "https://your.domain.com"
    }
  ],
  "paths": {
    "/oauth/token": {
      "post": {
        "tags": [
          "token"
        ],
        "summary": "Exchange credentials for an access token",
        "description": "SmartRecruiters will call this endpoint to exchange the credentials received from Partner for an access token.",
        "operationId": "getToken",
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "$ref": "#/components/schemas/TokenInput"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Access token",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AccessToken"
                }
              }
            }
          },
          "400": {
            "description": "Error Response https://tools.ietf.org/html/rfc6749#section-5.2",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TokenErrorResponse"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "TokenInput": {
        "type": "object",
        "required": [
          "grant_type",
          "client_id",
          "client_secret"
        ],
        "properties": {
          "grant_type": {
            "type": "string",
            "enum": [
              "client_credentials"
            ]
          },
          "client_id": {
            "type": "string"
          },
          "client_secret": {
            "type": "string"
          }
        }
      },
      "AccessToken": {
        "type": "object",
        "required": [
          "access_token",
          "expires_in"
        ],
        "properties": {
          "access_token": {
            "type": "string"
          },
          "expires_in": {
            "type": "integer",
            "description": "Indicates for how many seconds the token will be valid from the moment it was generated."
          }
        }
      },
      "TokenErrorResponse": {
        "type": "object",
        "required": [
          "error"
        ],
        "properties": {
          "error": {
            "type": "string"
          },
          "error_description": {
            "type": "string"
          }
        }
      }
    }
  },
  "x-readme": {
    "explorer-enabled": true,
    "proxy-enabled": true,
    "samples-enabled": true
  }
}
```