---
title: "OAuth authorize endpoint"
method: GET
path: "/auth/oauth/authorize/{provider_id}"
tags: ["Oauth"]
---

# OAuth authorize endpoint

`GET /auth/oauth/authorize/{provider_id}`

This endpoint is used to initiate the OAuth authorization flow. there are two purposes for this endpoint: 1. Authenticate a user with an OAuth provider. 2. Link an existing user with an OAuth provider.

## Path parameters

- `provider_id` string, required

## Query parameters

- `type` string
- `token` string
- `provider_scope` string
- `error_redirect_uri` string
- `after_callback_redirect_url` string
- `stack_response_mode` string
- `bot_challenge_token` string
- `bot_challenge_phase` string
- `bot_challenge_unavailable` string
- `client_id` string, required
- `client_secret` string, required
- `redirect_uri` string, required
- `scope` string, required
- `state` string, required
- `grant_type` string, required
- `code_challenge` string, required
- `code_challenge_method` string, required
- `response_type` string, required

## Response `200`

Successful response

- object
  - `location` string, required

## Other responses

- `307` — Successful response

## Changes

- **2026-05-06** `e832ef1d24dc` — 7 info
  - added the new optional `query` request parameter `bot_challenge_phase`
  - added the new optional `query` request parameter `bot_challenge_token`
  - added the new optional `query` request parameter `bot_challenge_unavailable`
  - added the new optional `query` request parameter `stack_response_mode`
  - …3 more

[Change history](https://skmtc.dev/hexclave/apis/hexclave-rest-api-3/changes/auth/oauth/authorize/:provider_id/get.md)

---

[API](https://skmtc.dev/hexclave/apis/hexclave-rest-api-3.md) · [All operations](https://skmtc.dev/hexclave/apis/hexclave-rest-api-3/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/hexclave/hexclave-rest-api-3/revisions/76ec643d488e/schema)
