> ## Documentation Index
> Fetch the complete documentation index at: https://docs.scute.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Initiate OAuth authorization

> Initiate OAuth authorization flow by redirecting to the provider's authorization endpoint. The provider must be configured for the app.



## OpenAPI

````yaml /swagger.json get /v1/auth/{app_id}/oauth/authorize
openapi: 3.0.1
info:
  title: Scute API
  version: v1
  description: API for managing users in Scute applications
servers:
  - url: https://{defaultHost}
    variables:
      defaultHost:
        default: api.scute.io
  - url: http://localhost:3333
    description: Development server
security:
  - apiSecret: []
    userAccess: []
paths:
  /v1/auth/{app_id}/oauth/authorize:
    parameters:
      - name: app_id
        in: path
        required: true
        description: App ID
        schema:
          type: string
      - name: provider
        in: query
        description: OAuth provider (e.g., google_oauth2, github)
        required: true
        schema:
          type: string
    get:
      tags:
        - OAuth
      summary: Initiate OAuth authorization
      description: >-
        Initiate OAuth authorization flow by redirecting to the provider's
        authorization endpoint. The provider must be configured for the app.
      operationId: initiateOAuthAuthorization
      responses:
        '302':
          description: redirect to provider
          content:
            application/json:
              schema:
                type: object
                properties:
                  url:
                    type: string
                    description: OAuth provider authorization URL
                description: Redirects to the OAuth provider authorization page
        '422':
          description: provider not allowed
          content:
            application/json:
              schema:
                type: object
                properties:
                  errors:
                    type: string
                    example: Provider not allowed
components:
  securitySchemes:
    apiSecret:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: API Secret token
    userAccess:
      type: apiKey
      name: X-Authorization
      in: header
      description: User Access token

````