---
title: "OAuth Token Exchange"
method: POST
path: "/oauth/token"
tags: ["OAuth"]
---

# OAuth Token Exchange

`POST /oauth/token`

Exchange authorization code for access token or refresh an access token. Accepts application/json or application/x-www-form-urlencoded.

## Response `200`

Token exchange successful

- object
  - `access_token` string, required — Access token for API requests
  - `token_type` 'Bearer', required — Token type, always 'Bearer'
  - `expires_in` number, required — Token expiration time in seconds
  - `refresh_token` string, required — Refresh token for obtaining new access tokens
  - `scope` string, required — Space-separated list of granted scopes

## Other responses

- `400` — Invalid request

---

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