Skip to main content

Ory APIs

Project description

ory-client

Introduction

Documentation for all public and administrative Ory APIs. Administrative APIs can only be accessed with a valid Personal Access Token. Public APIs are mostly used in browsers.

SDKs

This document describes the APIs available in the Ory Network. The APIs are available as SDKs for the following languages:

Language Download SDK Documentation
Dart pub.dev README
.NET nuget.org README
Elixir hex.pm README
Go github.com README
Java maven.org README
JavaScript npmjs.com README
JavaScript (With fetch) npmjs.com README
PHP packagist.org README
Python pypi.org README
Ruby rubygems.org README
Rust crates.io README

This Python package is automatically generated by the OpenAPI Generator project:

  • API version: v1.22.23
  • Package version: v1.22.23
  • Generator version: 7.17.0
  • Build package: org.openapitools.codegen.languages.PythonClientCodegen

Requirements.

Python 3.9+

Installation & Usage

pip install

If the python package is hosted on a repository, you can install directly using:

pip install git+https://github.com/ory/sdk.git

(you may need to run pip with root permission: sudo pip install git+https://github.com/ory/sdk.git)

Then import the package:

import ory_client

Setuptools

Install via Setuptools.

python setup.py install --user

(or sudo python setup.py install to install the package for all users)

Then import the package:

import ory_client

Tests

Execute pytest to run the tests.

Getting Started

Please follow the installation procedure and then run the following:

import ory_client
from ory_client.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://playground.projects.oryapis.com
# See configuration.py for a list of all supported configuration parameters.
configuration = ory_client.Configuration(
    host = "https://playground.projects.oryapis.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure Bearer authorization: oryAccessToken
configuration = ory_client.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)


# Enter a context with an instance of the API client
with ory_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = ory_client.CourierApi(api_client)
    id = 'id_example' # str | MessageID is the ID of the message.

    try:
        # Get a Message
        api_response = api_instance.get_courier_message(id)
        print("The response of CourierApi->get_courier_message:\n")
        pprint(api_response)
    except ApiException as e:
        print("Exception when calling CourierApi->get_courier_message: %s\n" % e)

Documentation for API Endpoints

All URIs are relative to https://playground.projects.oryapis.com

Class Method HTTP request Description
CourierApi get_courier_message GET /admin/courier/messages/{id} Get a Message
CourierApi list_courier_messages GET /admin/courier/messages List Messages
EventsApi create_event_stream POST /projects/{project_id}/eventstreams Create an event stream for your project.
EventsApi delete_event_stream DELETE /projects/{project_id}/eventstreams/{event_stream_id} Remove an event stream from a project
EventsApi list_event_streams GET /projects/{project_id}/eventstreams List all event streams for the project. This endpoint is not paginated.
EventsApi set_event_stream PUT /projects/{project_id}/eventstreams/{event_stream_id} Update an event stream for a project.
FrontendApi create_browser_login_flow GET /self-service/login/browser Create Login Flow for Browsers
FrontendApi create_browser_logout_flow GET /self-service/logout/browser Create a Logout URL for Browsers
FrontendApi create_browser_recovery_flow GET /self-service/recovery/browser Create Recovery Flow for Browsers
FrontendApi create_browser_registration_flow GET /self-service/registration/browser Create Registration Flow for Browsers
FrontendApi create_browser_settings_flow GET /self-service/settings/browser Create Settings Flow for Browsers
FrontendApi create_browser_verification_flow GET /self-service/verification/browser Create Verification Flow for Browser Clients
FrontendApi create_fedcm_flow GET /self-service/fed-cm/parameters Get FedCM Parameters
FrontendApi create_native_login_flow GET /self-service/login/api Create Login Flow for Native Apps
FrontendApi create_native_recovery_flow GET /self-service/recovery/api Create Recovery Flow for Native Apps
FrontendApi create_native_registration_flow GET /self-service/registration/api Create Registration Flow for Native Apps
FrontendApi create_native_settings_flow GET /self-service/settings/api Create Settings Flow for Native Apps
FrontendApi create_native_verification_flow GET /self-service/verification/api Create Verification Flow for Native Apps
FrontendApi disable_my_other_sessions DELETE /sessions Disable my other sessions
FrontendApi disable_my_session DELETE /sessions/{id} Disable one of my sessions
FrontendApi exchange_session_token GET /sessions/token-exchange Exchange Session Token
FrontendApi get_flow_error GET /self-service/errors Get User-Flow Errors
FrontendApi get_login_flow GET /self-service/login/flows Get Login Flow
FrontendApi get_recovery_flow GET /self-service/recovery/flows Get Recovery Flow
FrontendApi get_registration_flow GET /self-service/registration/flows Get Registration Flow
FrontendApi get_settings_flow GET /self-service/settings/flows Get Settings Flow
FrontendApi get_verification_flow GET /self-service/verification/flows Get Verification Flow
FrontendApi get_web_authn_java_script GET /.well-known/ory/webauthn.js Get WebAuthn JavaScript
FrontendApi list_my_sessions GET /sessions Get My Active Sessions
FrontendApi perform_native_logout DELETE /self-service/logout/api Perform Logout for Native Apps
FrontendApi to_session GET /sessions/whoami Check Who the Current HTTP Session Belongs To
FrontendApi update_fedcm_flow POST /self-service/fed-cm/token Submit a FedCM token
FrontendApi update_login_flow POST /self-service/login Submit a Login Flow
FrontendApi update_logout_flow GET /self-service/logout Update Logout Flow
FrontendApi update_recovery_flow POST /self-service/recovery Update Recovery Flow
FrontendApi update_registration_flow POST /self-service/registration Update Registration Flow
FrontendApi update_settings_flow POST /self-service/settings Complete Settings Flow
FrontendApi update_verification_flow POST /self-service/verification Complete Verification Flow
IdentityApi batch_patch_identities PATCH /admin/identities Create multiple identities
IdentityApi create_identity POST /admin/identities Create an Identity
IdentityApi create_recovery_code_for_identity POST /admin/recovery/code Create a Recovery Code
IdentityApi create_recovery_link_for_identity POST /admin/recovery/link Create a Recovery Link
IdentityApi delete_identity DELETE /admin/identities/{id} Delete an Identity
IdentityApi delete_identity_credentials DELETE /admin/identities/{id}/credentials/{type} Delete a credential for a specific identity
IdentityApi delete_identity_sessions DELETE /admin/identities/{id}/sessions Delete & Invalidate an Identity's Sessions
IdentityApi disable_session DELETE /admin/sessions/{id} Deactivate a Session
IdentityApi extend_session PATCH /admin/sessions/{id}/extend Extend a Session
IdentityApi get_identity GET /admin/identities/{id} Get an Identity
IdentityApi get_identity_by_external_id GET /admin/identities/by/external/{externalID} Get an Identity by its External ID
IdentityApi get_identity_schema GET /schemas/{id} Get Identity JSON Schema
IdentityApi get_session GET /admin/sessions/{id} Get Session
IdentityApi list_identities GET /admin/identities List Identities
IdentityApi list_identity_schemas GET /schemas Get all Identity Schemas
IdentityApi list_identity_sessions GET /admin/identities/{id}/sessions List an Identity's Sessions
IdentityApi list_sessions GET /admin/sessions List All Sessions
IdentityApi patch_identity PATCH /admin/identities/{id} Patch an Identity
IdentityApi update_identity PUT /admin/identities/{id} Update an Identity
JwkApi create_json_web_key_set POST /admin/keys/{set} Create JSON Web Key
JwkApi delete_json_web_key DELETE /admin/keys/{set}/{kid} Delete JSON Web Key
JwkApi delete_json_web_key_set DELETE /admin/keys/{set} Delete JSON Web Key Set
JwkApi get_json_web_key GET /admin/keys/{set}/{kid} Get JSON Web Key
JwkApi get_json_web_key_set GET /admin/keys/{set} Retrieve a JSON Web Key Set
JwkApi set_json_web_key PUT /admin/keys/{set}/{kid} Set JSON Web Key
JwkApi set_json_web_key_set PUT /admin/keys/{set} Update a JSON Web Key Set
MetadataApi get_version GET /version Return Running Software Version.
OAuth2Api accept_o_auth2_consent_request PUT /admin/oauth2/auth/requests/consent/accept Accept OAuth 2.0 Consent Request
OAuth2Api accept_o_auth2_login_request PUT /admin/oauth2/auth/requests/login/accept Accept OAuth 2.0 Login Request
OAuth2Api accept_o_auth2_logout_request PUT /admin/oauth2/auth/requests/logout/accept Accept OAuth 2.0 Session Logout Request
OAuth2Api accept_user_code_request PUT /admin/oauth2/auth/requests/device/accept Accepts a device grant user_code request
OAuth2Api create_o_auth2_client POST /admin/clients Create OAuth 2.0 Client
OAuth2Api delete_o_auth2_client DELETE /admin/clients/{id} Delete OAuth 2.0 Client
OAuth2Api delete_o_auth2_token DELETE /admin/oauth2/tokens Delete OAuth 2.0 Access Tokens from specific OAuth 2.0 Client
OAuth2Api delete_trusted_o_auth2_jwt_grant_issuer DELETE /admin/trust/grants/jwt-bearer/issuers/{id} Delete Trusted OAuth2 JWT Bearer Grant Type Issuer
OAuth2Api get_o_auth2_client GET /admin/clients/{id} Get an OAuth 2.0 Client
OAuth2Api get_o_auth2_consent_request GET /admin/oauth2/auth/requests/consent Get OAuth 2.0 Consent Request
OAuth2Api get_o_auth2_login_request GET /admin/oauth2/auth/requests/login Get OAuth 2.0 Login Request
OAuth2Api get_o_auth2_logout_request GET /admin/oauth2/auth/requests/logout Get OAuth 2.0 Session Logout Request
OAuth2Api get_trusted_o_auth2_jwt_grant_issuer GET /admin/trust/grants/jwt-bearer/issuers/{id} Get Trusted OAuth2 JWT Bearer Grant Type Issuer
OAuth2Api introspect_o_auth2_token POST /admin/oauth2/introspect Introspect OAuth2 Access and Refresh Tokens
OAuth2Api list_o_auth2_clients GET /admin/clients List OAuth 2.0 Clients
OAuth2Api list_o_auth2_consent_sessions GET /admin/oauth2/auth/sessions/consent List OAuth 2.0 Consent Sessions of a Subject
OAuth2Api list_trusted_o_auth2_jwt_grant_issuers GET /admin/trust/grants/jwt-bearer/issuers List Trusted OAuth2 JWT Bearer Grant Type Issuers
OAuth2Api o_auth2_authorize GET /oauth2/auth OAuth 2.0 Authorize Endpoint
OAuth2Api o_auth2_device_flow POST /oauth2/device/auth The OAuth 2.0 Device Authorize Endpoint
OAuth2Api oauth2_token_exchange POST /oauth2/token The OAuth 2.0 Token Endpoint
OAuth2Api patch_o_auth2_client PATCH /admin/clients/{id} Patch OAuth 2.0 Client
OAuth2Api perform_o_auth2_device_verification_flow GET /oauth2/device/verify OAuth 2.0 Device Verification Endpoint
OAuth2Api reject_o_auth2_consent_request PUT /admin/oauth2/auth/requests/consent/reject Reject OAuth 2.0 Consent Request
OAuth2Api reject_o_auth2_login_request PUT /admin/oauth2/auth/requests/login/reject Reject OAuth 2.0 Login Request
OAuth2Api reject_o_auth2_logout_request PUT /admin/oauth2/auth/requests/logout/reject Reject OAuth 2.0 Session Logout Request
OAuth2Api revoke_o_auth2_consent_sessions DELETE /admin/oauth2/auth/sessions/consent Revoke OAuth 2.0 Consent Sessions of a Subject
OAuth2Api revoke_o_auth2_login_sessions DELETE /admin/oauth2/auth/sessions/login Revokes OAuth 2.0 Login Sessions by either a Subject or a SessionID
OAuth2Api revoke_o_auth2_token POST /oauth2/revoke Revoke OAuth 2.0 Access or Refresh Token
OAuth2Api set_o_auth2_client PUT /admin/clients/{id} Set OAuth 2.0 Client
OAuth2Api set_o_auth2_client_lifespans PUT /admin/clients/{id}/lifespans Set OAuth2 Client Token Lifespans
OAuth2Api trust_o_auth2_jwt_grant_issuer POST /admin/trust/grants/jwt-bearer/issuers Trust OAuth2 JWT Bearer Grant Type Issuer
OidcApi create_oidc_dynamic_client POST /oauth2/register Register OAuth2 Client using OpenID Dynamic Client Registration
OidcApi create_verifiable_credential POST /credentials Issues a Verifiable Credential
OidcApi delete_oidc_dynamic_client DELETE /oauth2/register/{id} Delete OAuth 2.0 Client using the OpenID Dynamic Client Registration Management Protocol
OidcApi discover_oidc_configuration GET /.well-known/openid-configuration OpenID Connect Discovery
OidcApi get_oidc_dynamic_client GET /oauth2/register/{id} Get OAuth2 Client using OpenID Dynamic Client Registration
OidcApi get_oidc_user_info GET /userinfo OpenID Connect Userinfo
OidcApi revoke_oidc_session GET /oauth2/sessions/logout OpenID Connect Front- and Back-channel Enabled Logout
OidcApi set_oidc_dynamic_client PUT /oauth2/register/{id} Set OAuth2 Client using OpenID Dynamic Client Registration
PermissionApi batch_check_permission POST /relation-tuples/batch/check Batch check permissions
PermissionApi check_permission GET /relation-tuples/check/openapi Check a permission
PermissionApi check_permission_or_error GET /relation-tuples/check Check a permission
PermissionApi expand_permissions GET /relation-tuples/expand Expand a Relationship into permissions.
PermissionApi post_check_permission POST /relation-tuples/check/openapi Check a permission
PermissionApi post_check_permission_or_error POST /relation-tuples/check Check a permission
ProjectApi create_organization POST /projects/{project_id}/organizations Create an Enterprise SSO Organization
ProjectApi create_organization_onboarding_portal_link POST /projects/{project_id}/organizations/{organization_id}/onboarding-portal-links Create organization onboarding portal link
ProjectApi create_project POST /projects Create a Project
ProjectApi create_project_api_key POST /projects/{project}/tokens Create project API key
ProjectApi delete_organization DELETE /projects/{project_id}/organizations/{organization_id} Delete Enterprise SSO Organization
ProjectApi delete_organization_onboarding_portal_link DELETE /projects/{project_id}/organizations/{organization_id}/onboarding-portal-links/{onboarding_portal_link_id} Delete an organization onboarding portal link
ProjectApi delete_project_api_key DELETE /projects/{project}/tokens/{token_id} Delete project API key
ProjectApi get_organization GET /projects/{project_id}/organizations/{organization_id} Get Enterprise SSO Organization by ID
ProjectApi get_organization_onboarding_portal_links GET /projects/{project_id}/organizations/{organization_id}/onboarding-portal-links Get the organization onboarding portal links
ProjectApi get_project GET /projects/{project_id} Get a Project
ProjectApi get_project_members GET /projects/{project}/members Get all members associated with this project
ProjectApi list_organizations GET /projects/{project_id}/organizations List all Enterprise SSO organizations
ProjectApi list_project_api_keys GET /projects/{project}/tokens List a project's API keys
ProjectApi list_projects GET /projects List All Projects
ProjectApi patch_project PATCH /projects/{project_id} Patch an Ory Network Project Configuration
ProjectApi patch_project_with_revision PATCH /projects/{project_id}/revision/{revision_id} Patch an Ory Network Project Configuration based on a revision ID
ProjectApi purge_project DELETE /projects/{project_id} Irrecoverably purge a project
ProjectApi remove_project_member DELETE /projects/{project}/members/{member} Remove a member associated with this project
ProjectApi set_project PUT /projects/{project_id} Update an Ory Network Project Configuration
ProjectApi update_organization PUT /projects/{project_id}/organizations/{organization_id} Update an Enterprise SSO Organization
ProjectApi update_organization_onboarding_portal_link POST /projects/{project_id}/organizations/{organization_id}/onboarding-portal-links/{onboarding_portal_link_id} Update organization onboarding portal link
RelationshipApi check_opl_syntax POST /opl/syntax/check Check the syntax of an OPL file
RelationshipApi create_relationship PUT /admin/relation-tuples Create a Relationship
RelationshipApi delete_relationships DELETE /admin/relation-tuples Delete Relationships
RelationshipApi get_relationships GET /relation-tuples Query relationships
RelationshipApi list_relationship_namespaces GET /namespaces Query namespaces
RelationshipApi patch_relationships PATCH /admin/relation-tuples Patch Multiple Relationships
WellknownApi discover_json_web_keys GET /.well-known/jwks.json Discover Well-Known JSON Web Keys
WorkspaceApi create_workspace POST /workspaces Create a new workspace
WorkspaceApi create_workspace_api_key POST /workspaces/{workspace}/tokens Create workspace API key
WorkspaceApi delete_workspace_api_key DELETE /workspaces/{workspace}/tokens/{token_id} Delete workspace API key
WorkspaceApi get_workspace GET /workspaces/{workspace} Get a workspace
WorkspaceApi list_workspace_api_keys GET /workspaces/{workspace}/tokens List a workspace's API keys
WorkspaceApi list_workspace_projects GET /workspaces/{workspace}/projects List all projects of a workspace
WorkspaceApi list_workspaces GET /workspaces List workspaces the user is a member of
WorkspaceApi update_workspace PUT /workspaces/{workspace} Update an workspace

Documentation For Models

Documentation For Authorization

Authentication schemes defined for the API:

basic

  • Type: HTTP basic authentication

bearer

  • Type: Bearer authentication

oauth2

  • Type: OAuth
  • Flow: accessCode
  • Authorization URL: https://hydra.demo.ory.sh/oauth2/auth
  • Scopes:
  • offline: A scope required when requesting refresh tokens (alias for offline_access)
  • offline_access: A scope required when requesting refresh tokens
  • openid: Request an OpenID Connect ID Token

oryAccessToken

  • Type: Bearer authentication

oryWorkspaceApiKey

  • Type: Bearer authentication

Author

support@ory.sh

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ory_client-1.22.23.tar.gz (408.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ory_client-1.22.23-py3-none-any.whl (855.7 kB view details)

Uploaded Python 3

File details

Details for the file ory_client-1.22.23.tar.gz.

File metadata

  • Download URL: ory_client-1.22.23.tar.gz
  • Upload date:
  • Size: 408.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.2

File hashes

Hashes for ory_client-1.22.23.tar.gz
Algorithm Hash digest
SHA256 d56623f7129f257471c6057b93d2d32acc16891f86ebf755d31236841f05b425
MD5 7dcd61a0bb96af7e2e9dd4f83c63cda9
BLAKE2b-256 d95da5241e16c6331585655ec590ede002fad9085e5465f42a38aefde47ef73e

See more details on using hashes here.

File details

Details for the file ory_client-1.22.23-py3-none-any.whl.

File metadata

  • Download URL: ory_client-1.22.23-py3-none-any.whl
  • Upload date:
  • Size: 855.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.2

File hashes

Hashes for ory_client-1.22.23-py3-none-any.whl
Algorithm Hash digest
SHA256 2e8ff3c9d5f78a335931b2c7c5e581fc395b998a2013146eb714907000130f9b
MD5 79c673476e2c9a26d34e46730a966231
BLAKE2b-256 0dbc8b64cf1f327f28c58145282b241cb12399b05e431a4de798bf60643e04c5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page