---
title: "Oauth Callback"
method: GET
path: "/api/oauth/callback"
---

# Oauth Callback

`GET /api/oauth/callback`

Handle OAuth provider redirect after user authorization.

The provider redirects here with an authorization code and the state
parameter we generated earlier. We exchange the code for tokens,
persist them, and redirect the user to the frontend success page.

## Query parameters

- `code` string, required
- `state` string, required
- `realmId` string
- `error` string
- `error_description` string

## Response `200`

Successful Response

- unknown

## Other responses

- `422` — Validation Error

## Changes

- **2026-03-20** `4c528359213d` — 2 breaking
  - the `query` request parameter `code` became required
  - the `query` request parameter `state` became required

[Change history](https://skmtc.dev/mozilla-ai/apis/clawbolt/changes/api/oauth/callback/get.md)

---

[API](https://skmtc.dev/mozilla-ai/apis/clawbolt.md) · [All operations](https://skmtc.dev/mozilla-ai/apis/clawbolt/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/mozilla-ai/clawbolt/revisions/bf5f82d4f563/schema)
