---
title: "Exchange an MCP OAuth authorization for an API token."
method: POST
path: "/oauth/exchange"
tags: ["API tokens"]
---

# Exchange an MCP OAuth authorization for an API token.

`POST /oauth/exchange`

## Request

- Base URL: `https://www.livediagram.app/api`
- URL: `https://www.livediagram.app/api/oauth/exchange`
- Auth: HTTP bearer

## Request body

- object
  - `clientName` string

## Response `201`

Success.

## Other responses

- `400`: Error.
- `403`: Error.
- `404`: Error.
- `409`: Error.
- `429`: Rate limited. Back off and retry.

---

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