---
title: "Get access token for authentication of requests"
method: POST
path: "/auth/get_token"
tags: ["Authentication"]
---

# Get access token for authentication of requests

`POST /auth/get_token`

## Request

- Base URL: `https://socialbu.com/api/v1`
- URL: `https://socialbu.com/api/v1/auth/get_token`
- Auth: none required

Generates an access token for API authentication.

## Request body

- object
  - `email` string, required: User's email address e.g, (user@example.com)
  - `password` string, required: User's password.

## Response `200`

Access token

- object
  - `authToken` string: New access token. Any old token will be invalidated.
  - `id` integer: User's Socialbu Account ID.
  - `name` string: User's Socialbu Account Name.
  - `email` string: User's Socialbu Account Email.
  - `verified` boolean: User's email verification status.

## Other responses

- `400`: Bad Request
- `422`: The given data was incorrect.

---

[API](https://skmtc.dev/socialbu/apis/socialbu-api.md) · [All operations](https://skmtc.dev/socialbu/apis/socialbu-api/llms.txt) · [OpenAPI document](https://skmtc.dev/socialbu/apis/socialbu-api/revisions/841b3ab0f671?raw)
