---
title: "MCP OAuth callback"
method: GET
path: "/mcp/oauth/callback"
tags: ["mcp_oauth"]
---

# MCP OAuth callback

`GET /mcp/oauth/callback`

Handles OAuth callback, exchanges code for tokens, returns HTML that posts message to opener

## Query parameters

- `code` string, required
- `state` string, required

## Response `200`

HTML page with JavaScript that posts tokens to opener window and closes

---

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