From 09c403e55482e91a5bfe9a253e514b7a90826709 Mon Sep 17 00:00:00 2001 From: Vincent Date: Tue, 10 Aug 2021 10:50:13 +0200 Subject: [PATCH] docs: change model to schema (#1639) --- docs/docs/admin/managing-users-identities.mdx | 5 ++--- .../openid-connect-oidc-oauth2.mdx | 2 +- .../credentials/username-email-password.mdx | 12 +++++------ ...ity-data-model.mdx => identity-schema.mdx} | 12 +++++------ docs/docs/concepts/index.md | 4 ++-- docs/docs/concepts/ui-user-interface.md | 4 ++-- .../account-activation-email-verification.mdx | 4 ++-- .../account-recovery-password-reset.mdx | 4 ++-- docs/docs/index.md | 2 +- docs/docs/reference/html-forms.md | 6 +++--- docs/docs/reference/json-schema-json-paths.md | 4 ++-- .../self-service/flows/account-recovery.mdx | 2 +- .../self-service/flows/user-registration.mdx | 4 ++-- .../docs/self-service/flows/user-settings.mdx | 6 +++--- .../flows/verify-email-account-activation.mdx | 2 +- docs/faq.yaml | 2 +- docs/sidebar.json | 2 +- .../admin/managing-users-identities.mdx | 4 ++-- .../openid-connect-oidc-oauth2.mdx | 2 +- .../credentials/username-email-password.mdx | 8 +++---- ...ity-data-model.mdx => identity-schema.mdx} | 21 +++++++++++++------ .../version-v0.7/concepts/index.md | 4 ++-- .../concepts/ui-user-interface.md | 2 +- .../account-activation-email-verification.mdx | 2 +- .../account-recovery-password-reset.mdx | 2 +- docs/versioned_docs/version-v0.7/index.md | 2 +- .../version-v0.7/reference/html-forms.md | 4 ++-- .../reference/json-schema-json-paths.md | 2 +- .../self-service/flows/account-recovery.mdx | 2 +- .../self-service/flows/user-registration.mdx | 4 ++-- .../self-service/flows/user-settings.mdx | 6 +++--- .../flows/verify-email-account-activation.mdx | 2 +- .../version-v0.7-sidebars.json | 4 ++-- spec/api.json | 10 ++++----- 34 files changed, 83 insertions(+), 75 deletions(-) rename docs/docs/concepts/{identity-data-model.mdx => identity-schema.mdx} (96%) rename docs/versioned_docs/version-v0.7/concepts/{identity-data-model.mdx => identity-schema.mdx} (93%) diff --git a/docs/docs/admin/managing-users-identities.mdx b/docs/docs/admin/managing-users-identities.mdx index 34d7aa545991..1d289aabf968 100644 --- a/docs/docs/admin/managing-users-identities.mdx +++ b/docs/docs/admin/managing-users-identities.mdx @@ -8,8 +8,7 @@ import TabItem from '@theme/TabItem' This document walks you through the administrative identity management in Ory Kratos. You should already be familiar with the -[Identity Data Model](../concepts/identity-data-model.mdx) before reading this -guide. +[Identity Schema](../concepts/identity-schema.mdx) before reading this guide. ## Creating an Identity @@ -167,7 +166,7 @@ selfservice: ``` To specify that an identity's trait is a recovery email, use the following -Identity JSON Schema: +Identity Schema: ```diff { diff --git a/docs/docs/concepts/credentials/openid-connect-oidc-oauth2.mdx b/docs/docs/concepts/credentials/openid-connect-oidc-oauth2.mdx index dfed4fa8bfed..0cf3fe0d430a 100644 --- a/docs/docs/concepts/credentials/openid-connect-oidc-oauth2.mdx +++ b/docs/docs/concepts/credentials/openid-connect-oidc-oauth2.mdx @@ -12,7 +12,7 @@ provider (for example [Ory Hydra](https://www.ory.sh/hydra)). "Social Sign In" or "Sign in with ..." are common aliases for this flow. This strategy expects that you've set up your -[Default Identity JSON Schema](../identity-data-model.mdx). +[Default Identity Schema](../identity-schema.mdx). ## Configuration diff --git a/docs/docs/concepts/credentials/username-email-password.mdx b/docs/docs/concepts/credentials/username-email-password.mdx index 48485d974fb7..a48180992783 100644 --- a/docs/docs/concepts/credentials/username-email-password.mdx +++ b/docs/docs/concepts/credentials/username-email-password.mdx @@ -69,8 +69,8 @@ hashers: To determine the ideal parameters, head over to the [setup guide](../../guides/setting-up-password-hashing-parameters). -When a user signs up using this method, the Default Identity JSON Schema (set -using `identity.default_schema_url`) is used: +When a user signs up using this method, the Default Identity Schema (set using +`identity.default_schema_url`) is used: ```yaml title="path/to/my/kratos/config.yml" identity: @@ -81,8 +81,8 @@ identity: ``` If you don't know what that means, please read the -[Identity Data Model Chapter](../../concepts/identity-data-model.mdx) in the -docs' concepts section. +[Identity Schema Chapter](../../concepts/identity-schema.mdx) in the docs' +concepts section. For a complete reference, defaults, and description please check the [Configuration Reference](../../reference/configuration.md). @@ -146,7 +146,7 @@ special meaning for some E-Mail Providers (e.g. GMail) are not normalized: You need to decide which route you want to take. -### Picking the right Identity JSON Schema +### Picking the right Identity Schema When processing an identity and its traits, the method will use [JSON Schema](../../reference/json-schema-json-paths.md) to extract one or more @@ -298,7 +298,7 @@ You may also mix usernames and passwords: ## Example -Assuming your Identity JSON Schema is as follows: +Assuming your Identity Schema is as follows: ```json { diff --git a/docs/docs/concepts/identity-data-model.mdx b/docs/docs/concepts/identity-schema.mdx similarity index 96% rename from docs/docs/concepts/identity-data-model.mdx rename to docs/docs/concepts/identity-schema.mdx index 1803d84bf9db..421f41bcb150 100644 --- a/docs/docs/concepts/identity-data-model.mdx +++ b/docs/docs/concepts/identity-schema.mdx @@ -1,6 +1,6 @@ --- -id: identity-data-model -title: Identity Data Model +id: identity-schema +title: Identity Schema --- import Mermaid from '@theme/Mermaid' @@ -119,8 +119,8 @@ in the following situations: support or staff; - the system includes both users and robots sometimes also known as named service accounts; -- the system needs to ingest another company's identity model, and -- the system's identity model changes or grows over time and requires +- the system needs to ingest another company's Identity Schema, and +- the system's Identity Schema changes or grows over time and requires versioning. The following example illustrates a usage scenario with three types of @@ -174,10 +174,10 @@ switch (session.Identity.SchemaID) { :::warning -Please keep in mind that the Identity Model is not a place to store sensitive +Please keep in mind that the Identity Schema is not a place to store sensitive information that should not be visible to the end-user! Users can see traits and other data - except credentials - using the `sessions/whoami` endpoint. The -Identity Model is not the right place to store data that should be obfuscated +Identity Schema is not the right place to store data that should be obfuscated from the user! ::: diff --git a/docs/docs/concepts/index.md b/docs/docs/concepts/index.md index 1c5045e8b628..196496fd117f 100644 --- a/docs/docs/concepts/index.md +++ b/docs/docs/concepts/index.md @@ -260,7 +260,7 @@ very easy to get started there is a reference implementation For more details about each individual flow, consult the [Self-Service Flows Chapter](../self-service.mdx). -### Bring your own Identity Model(s) +### Bring your own Identity Schema(s) Sometimes it is necessary to store more than one type of identity in your system: @@ -271,7 +271,7 @@ system: attached to the profile. Ory Kratos implements both scenarios by using -[JSON Schemas for Identities](./identity-data-model.mdx) +[Identity Schemas](./identity-schema.mdx) ### Forget passport-js, oidc-client, ... diff --git a/docs/docs/concepts/ui-user-interface.md b/docs/docs/concepts/ui-user-interface.md index a2a9069474c8..c5477745a357 100644 --- a/docs/docs/concepts/ui-user-interface.md +++ b/docs/docs/concepts/ui-user-interface.md @@ -167,8 +167,8 @@ use for the labels: #### Node Order and Labels -For all traits, the labels and orders are taken from the Identity JSON Schema. A -JSON Schema such as +For all traits, the labels and orders are taken from the Identity Schema. A JSON +Schema such as ```json { diff --git a/docs/docs/guides/account-activation-email-verification.mdx b/docs/docs/guides/account-activation-email-verification.mdx index 4a2ece4e1a9a..de38c633bd45 100644 --- a/docs/docs/guides/account-activation-email-verification.mdx +++ b/docs/docs/guides/account-activation-email-verification.mdx @@ -8,8 +8,8 @@ title: Setting up Account Activation and E-Mail Verification To send emails, you need to [setup the mail courier](../concepts/email-sms.md) To set up email verification, your -[Identity JSON Schema](../concepts/identity-data-model.mdx) must have an email -in its traits and add +[Identity Schema](../concepts/identity-schema.mdx) must have an email in its +traits and add ```json { diff --git a/docs/docs/guides/account-recovery-password-reset.mdx b/docs/docs/guides/account-recovery-password-reset.mdx index c6756a0023b5..8d4a14581236 100644 --- a/docs/docs/guides/account-recovery-password-reset.mdx +++ b/docs/docs/guides/account-recovery-password-reset.mdx @@ -4,8 +4,8 @@ title: Setting up Account Recovery and Password Reset --- To set up account recovery, your -[Identity JSON Schema](../concepts/identity-data-model.mdx) must have an email -in its traits and add +[Identity Schema](../concepts/identity-schema.mdx) must have an email in its +traits and add ```json { diff --git a/docs/docs/index.md b/docs/docs/index.md index 07c536c99484..49d6da42a963 100644 --- a/docs/docs/index.md +++ b/docs/docs/index.md @@ -36,7 +36,7 @@ Kubernetes) most: - The workflow engine allows you to fully customize your user experience. Whether your users need to activate their account after registration, or have a multi-step (progressive) registration - it's all possible! -- One Identity Data Model does not fit all - you may have customers that need a +- One Identity Schema does not fit all - you may have customers that need a billing address, internal support staff that is assigned to a cost center, and that smart fridge on floor 4. You can express the different data models using [JSON Schema](https://json-schema.org/) and make the system work for you - not diff --git a/docs/docs/reference/html-forms.md b/docs/docs/reference/html-forms.md index 6bb020291b68..2cdfaf8470e2 100644 --- a/docs/docs/reference/html-forms.md +++ b/docs/docs/reference/html-forms.md @@ -6,12 +6,12 @@ title: HTML Form Parser If you're using HTML Forms to sign users up or update profiles, Ory Kratos needs to assert the type of each field, as HTML Form Field Values are untyped. -Ory Kratos uses the Identity JSON Schema to assert form field types. There are a -few tricks you should know when using this feature. +Ory Kratos uses the Identity Schema to assert form field types. There are a few +tricks you should know when using this feature. ## Nesting -Assuming this Identity JSON Schema: +Assuming this Identity Schema: ```json { diff --git a/docs/docs/reference/json-schema-json-paths.md b/docs/docs/reference/json-schema-json-paths.md index 9c3559ce95d4..0de4b16c0ebe 100644 --- a/docs/docs/reference/json-schema-json-paths.md +++ b/docs/docs/reference/json-schema-json-paths.md @@ -10,8 +10,8 @@ payloads. We rely on JSON Schema heavily internally, from configuration validation to generating OpenAPI Spec to writing documentation. By using Ory Kratos, you will -be exposed to JSON Schema as it is used for defining Identity data models and -other things. +be exposed to JSON Schema as it is used for defining Identity Schemas and other +things. To learn more about JSON Schema, head over to [json-schema.org/learn/](https://json-schema.org/learn/). diff --git a/docs/docs/self-service/flows/account-recovery.mdx b/docs/docs/self-service/flows/account-recovery.mdx index d5397b1317c4..61f7c121634a 100644 --- a/docs/docs/self-service/flows/account-recovery.mdx +++ b/docs/docs/self-service/flows/account-recovery.mdx @@ -181,7 +181,7 @@ selfservice: To specify that an identity's trait is a recovery email, use the following -Identity JSON Schema: +Identity Schema: ```diff { diff --git a/docs/docs/self-service/flows/user-registration.mdx b/docs/docs/self-service/flows/user-registration.mdx index 7d4a95c103eb..bd90ee9d92a7 100644 --- a/docs/docs/self-service/flows/user-registration.mdx +++ b/docs/docs/self-service/flows/user-registration.mdx @@ -297,9 +297,9 @@ first. ::: When the `password` method is enabled, it will be part of the `methods` payload -in the Registration Flow. Ory Kratos uses the Identity JSON Schema defined in +in the Registration Flow. Ory Kratos uses the Identity Schema defined in `identity.default_schema_url` to generate a list of form fields and add it to -the Registration Flow. Assuming we are using the Identity JSON Schema from the +the Registration Flow. Assuming we are using the Identity Schema from the Quickstart To specify that an identity's trait is a recovery email, use the following -Identity JSON Schema: +Identity Schema: ```diff { diff --git a/docs/versioned_docs/version-v0.7/self-service/flows/user-registration.mdx b/docs/versioned_docs/version-v0.7/self-service/flows/user-registration.mdx index 7d4a95c103eb..bd90ee9d92a7 100644 --- a/docs/versioned_docs/version-v0.7/self-service/flows/user-registration.mdx +++ b/docs/versioned_docs/version-v0.7/self-service/flows/user-registration.mdx @@ -297,9 +297,9 @@ first. ::: When the `password` method is enabled, it will be part of the `methods` payload -in the Registration Flow. Ory Kratos uses the Identity JSON Schema defined in +in the Registration Flow. Ory Kratos uses the Identity Schema defined in `identity.default_schema_url` to generate a list of form fields and add it to -the Registration Flow. Assuming we are using the Identity JSON Schema from the +the Registration Flow. Assuming we are using the Identity Schema from the Quickstart