---
title: "Gmail Authorize"
method: GET
path: "/api/gmail/authorize/{agent_id}"
tags: ["gmail-connect"]
---

# Gmail Authorize

`GET /api/gmail/authorize/{agent_id}`

## Request

- Base URL: `https://api.maritime.sh` (the document declares no server; this is the origin it was published from)
- URL: `https://api.maritime.sh/api/gmail/authorize/{agent_id}`
- Auth: HTTP bearer

Generate Google OAuth consent URL for Gmail access.

Returns a URL that the frontend opens in a popup window.
After consent, Google redirects to /api/gmail/callback.

## Path parameters

- `agent_id` string, required

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

---

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