---
title: "Get OAuth authorization URL"
method: GET
path: "/v1/users/{user_id}/integrations/connect"
tags: ["Integrations"]
---

# Get OAuth authorization URL

`GET /v1/users/{user_id}/integrations/connect`

## Request

- Base URL: `http://0.0.0.0:3000`
- URL: `http://0.0.0.0:3000/v1/users/{user_id}/integrations/connect`
- Auth: none declared

Returns an OAuth authorization URL to connect a user's Gmail, Slack, Outlook, or other integration.

**Flow**:
1. Call this GET endpoint with `provider` to get an `authUrl`
2. Redirect the user to the `authUrl`
3. After user authorizes, they're redirected back with a `code`
4. Call `POST /v1/users/:user_id/integrations/connect` with the `code` to complete the connection

**Supported providers**: `gmail`, `slack`, `outlook`, `teams`

## Path parameters

- `user_id` string, uuid, required

## Query parameters

- `provider` 'gmail' | 'slack' | 'outlook' | 'google_calendar' | 'google_meet' | 'teams', required
- `state` string
- `reconnect` string

## Response `200`

Default Response

- object
  - `success` boolean, required
  - `authUrl` string, required: OAuth authorization URL to redirect to

## Other responses

- `400`: Default Response
- `500`: Default Response

---

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