---
title: "Google Drive Exchange Token"
method: POST
path: "/storage-providers/google-drive/callback"
tags: ["storage-providers"]
---

# Google Drive Exchange Token

`POST /storage-providers/google-drive/callback`

Exchange the OAuth authorization code for tokens and connect Google Drive.

Called by the frontend after receiving the code from the popup via postMessage.
This endpoint is authenticated — the user's JWT is used to verify ownership.

## Request body

- GoogleDriveCallbackRequest — OAuth callback with authorization code.
  - `code` string, required
  - `space_id` string, uuid, required

## Response `200`

Successful Response

- unknown

## Other responses

- `422` — Validation Error

---

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