---
title: "Exchange an embed token for an OAuth2 access token"
method: POST
path: "/auth/embed-token/exchange"
tags: ["Auth"]
---

# Exchange an embed token for an OAuth2 access token

`POST /auth/embed-token/exchange`

Exchanges a short-lived embed token for a standard OAuth2 access token. Returns the same payload shape as the PKCE token endpoint.

## Request body

- EmbedTokenExchangeRequest
  - `embed_token` string, required

## Response `200`

OAuth2 access token response

- object
  - `access_token` string
  - `token_type` string
  - `expires_in` integer
  - `scope` string
  - `company_id` string, uuid

## Other responses

- `401` — Invalid or expired embed token

---

[API](https://skmtc.net/cubesoftware/apis/cube-api.md) · [All operations](https://skmtc.net/cubesoftware/apis/cube-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/cubesoftware/cube-api/revisions/67d9f45bb99b/schema)
