Ory

Ory OAuth2 (Public) API

Public OAuth2 / OpenID Connect provider endpoints (Hydra).

Operations 6

GET /oauth2/auth OAuth2 authorization endpoint #
POST /oauth2/token OAuth2 token endpoint #
POST /oauth2/revoke Revoke an OAuth2 token #
GET /userinfo OpenID Connect UserInfo #
GET /.well-known/openid-configuration OpenID Connect discovery document #
GET /.well-known/jwks.json JSON Web Key Set #

Documentation

Specifications

Other Resources

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/ory-oauth2-public-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

ory-oauth2-public-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Ory Network Billing OAuth2 (Public) OAuth2 (Public) API
  description: 'Ory is open-source identity and access infrastructure, delivered as the Ory Network managed cloud. This document models the primary public and admin REST surfaces of an Ory Network project and the Ory Network Console (control plane).

    Two base URLs are in play. Project data-plane endpoints - Ory Kratos (identities, sessions, self-service flows), Ory Hydra (OAuth2 / OIDC), Ory Keto (permissions and relationship tuples), and courier messages - are served on the project-scoped host https://{project-slug}.projects.oryapis.com. The Ory Network Console API (workspaces, projects, project tokens, event streams, subscriptions) is served on https://api.console.ory.sh.

    Public self-service and OAuth2/OIDC endpoints are unauthenticated or use the end-user session; admin, Keto write, courier, and Console endpoints require an Ory API key / project or workspace API token passed as a Bearer token. Ory SDKs are auto-generated from these OpenAPI specifications. Endpoint set is representative and grounded in Ory''s published specs; consult the live reference for the exhaustive parameter and schema detail.'
  version: '1.0'
  contact:
    name: Ory
    url: https://www.ory.com
  license:
    name: Apache-2.0
    url: https://github.com/ory/kratos/blob/master/LICENSE
servers:
- url: https://{project-slug}.projects.oryapis.com
  description: Ory Network project (Kratos, Hydra, Keto, Courier)
  variables:
    project-slug:
      default: your-project-slug
      description: The slug of your Ory Network project.
- url: https://api.console.ory.sh
  description: Ory Network Console API (control plane)
security:
- oryApiKey: []
tags:
- name: OAuth2 (Public)
  description: Public OAuth2 / OpenID Connect provider endpoints (Hydra).
paths:
  /oauth2/auth:
    get:
      operationId: oAuth2Authorize
      tags:
      - OAuth2 (Public)
      summary: OAuth2 authorization endpoint
      security: []
      responses:
        '302':
          description: Redirect to login/consent or back to the client with a code.
  /oauth2/token:
    post:
      operationId: oauth2TokenExchange
      tags:
      - OAuth2 (Public)
      summary: OAuth2 token endpoint
      security: []
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                grant_type:
                  type: string
                code:
                  type: string
                refresh_token:
                  type: string
                client_id:
                  type: string
                client_secret:
                  type: string
      responses:
        '200':
          description: The issued tokens.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TokenResponse'
  /oauth2/revoke:
    post:
      operationId: revokeOAuth2Token
      tags:
      - OAuth2 (Public)
      summary: Revoke an OAuth2 token
      security: []
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                token:
                  type: string
      responses:
        '200':
          description: Token revoked.
  /userinfo:
    get:
      operationId: getOidcUserInfo
      tags:
      - OAuth2 (Public)
      summary: OpenID Connect UserInfo
      responses:
        '200':
          description: Claims about the authenticated end-user.
  /.well-known/openid-configuration:
    get:
      operationId: discoverOidcConfiguration
      tags:
      - OAuth2 (Public)
      summary: OpenID Connect discovery document
      security: []
      responses:
        '200':
          description: The OIDC provider metadata.
  /.well-known/jwks.json:
    get:
      operationId: discoverJsonWebKeys
      tags:
      - OAuth2 (Public)
      summary: JSON Web Key Set
      security: []
      responses:
        '200':
          description: The public signing keys.
components:
  schemas:
    TokenResponse:
      type: object
      properties:
        access_token:
          type: string
        token_type:
          type: string
        expires_in:
          type: integer
        refresh_token:
          type: string
        id_token:
          type: string
        scope:
          type: string
  securitySchemes:
    oryApiKey:
      type: http
      scheme: bearer
      description: 'Ory API key. Project admin endpoints use an Ory project API key (ory_pat_...); Console endpoints use a workspace API key (ory_wak_...). Passed as `Authorization: Bearer <token>`.'