mirror of
https://github.com/andwati/zitadel.git
synced 2026-10-18 05:52:51 +00:00
docs: introduce versioned docs and migrate to fuma (#11166)
## Todos for release - [x] Configure Env in docs project on vercel - [x] Configure Root Path in the docs project on vercel - [ ] Remove old CSP https://github.com/zitadel/website/pull/1592 ## What we did This pull request migrates the project documentation from the old `docs/` directory to the new `apps/docs/` directory, introduces a new documentation system built with Next.js and Fumadocs, and updates all relevant references, configuration files, and documentation to reflect this change. It also adds new configuration and ignore files for the new documentation app, updates CI and linting to exclude the new docs from certain checks, and revises the contributing guidelines accordingly. **Documentation System Migration and New Docs App** * Migrated all documentation from `docs/` to `apps/docs/`, and updated all references in `README.md`, `CONTRIBUTING.md`, and other files to point to the new location. [[1]](diffhunk://#diff-eca12c0a30e25b4b46522ebf89465a03ba72a03f540796c979137931d8f92055L585-L640) [[2]](diffhunk://#diff-eca12c0a30e25b4b46522ebf89465a03ba72a03f540796c979137931d8f92055L660-R607) [[3]](diffhunk://#diff-eca12c0a30e25b4b46522ebf89465a03ba72a03f540796c979137931d8f92055L740-R687) [[4]](diffhunk://#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5L2-R3) [[5]](diffhunk://#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5L30-R30) * Added a new Next.js/Fumadocs-based documentation app under `apps/docs/`, including core app files, layouts, routing, search API, and a comprehensive `README.md` with development and contribution instructions. [[1]](diffhunk://#diff-5a1b07344a2c1b4d3f37b23ff1388b62cd9f57dea3c1cd23d8a0412b7602b132R1-R74) [[2]](diffhunk://#diff-462b9ad1eabbb7d1c29bb9c36e4931eb180fd7190900e6d2babf8f4d66ad1c28R1-R39) [[3]](diffhunk://#diff-e16ae25660ded787b10ac35dea96d5ecaacf895dae0afc8a9bd4382dc79a8c87R1-R7) [apps/docs/app/[[...slug]]/layout.tsxR1-R81](diffhunk://#diff-59e08acde4e805b7aeccef1dcf98f1d71dfc550777e6b9402085cee0e9fa4e0aR1-R81), [apps/docs/app/[[...slug]]/page.tsxR1-R79](diffhunk://#diff-e5df3f80d0fa01e12d63d81f29c57a9d14e846c78fd3beabb2ef768e38fd9580R1-R79), [[4]](diffhunk://#diff-389b34918e040cacaa87cd7201ffa462cc2b0b716736f537e3d3c660ac69353bR1-R7) [[5]](diffhunk://#diff-d3b03416d1c457b19f1c27b26f2db741412df841b875c26ccadc36e4522247f4R1-R29) [[6]](diffhunk://#diff-c8fb8339570a5305809be7c618e14705fd86390dc278e6ce8ba224a7bc8b0c3cR1-R25) **Configuration and Tooling Updates** * Updated `.github/workflows/codeql.yml`, `.golangci.yaml`, and `.github/dependabot.yml` to properly handle the new docs app: excluded `apps/docs` from certain checks, added npm dependency updates for the docs app, and excluded generated content. [[1]](diffhunk://#diff-12783128521e452af0cfac94b99b8d250413c516ec71fe6d97dbea666ff7ba27L8-R14) [[2]](diffhunk://#diff-9917ddc9f1c3304218f7269265b746d997c5c0615478177b5fceecd33ef47cb5R5-R6) [[3]](diffhunk://#diff-9917ddc9f1c3304218f7269265b746d997c5c0615478177b5fceecd33ef47cb5R126-R129) [[4]](diffhunk://#diff-dd4fbda47e51f1e35defb9275a9cd9c212ecde0b870cba89ddaaae65c5f3cd28R89-R106) * Updated `.devcontainer/devcontainer.json` to use the latest Go 1.25.3 version for consistency. **Licensing and Miscellaneous** * Added `apps/docs/` to the list of licensed directories in `LICENSING.md`. These changes ensure the documentation is now maintained in a modern, scalable system and all project tooling is updated to support the new structure. --------- Co-authored-by: Federico Coppede <[email protected]>
This commit is contained in:
co-authored by
Federico Coppede
parent
7b6395c348
commit
d8ea041c56
@@ -33,7 +33,7 @@
|
|||||||
},
|
},
|
||||||
"features": {
|
"features": {
|
||||||
"ghcr.io/devcontainers/features/go:1": {
|
"ghcr.io/devcontainers/features/go:1": {
|
||||||
"version": "1.25"
|
"version": "1.25.3"
|
||||||
},
|
},
|
||||||
"ghcr.io/devcontainers/features/docker-outside-of-docker": {},
|
"ghcr.io/devcontainers/features/docker-outside-of-docker": {},
|
||||||
"ghcr.io/schlich/devcontainer-features/cypress:1": {
|
"ghcr.io/schlich/devcontainer-features/cypress:1": {
|
||||||
|
|||||||
@@ -86,3 +86,21 @@ updates:
|
|||||||
commit-message:
|
commit-message:
|
||||||
prefix: chore
|
prefix: chore
|
||||||
include: scope
|
include: scope
|
||||||
|
- package-ecosystem: npm
|
||||||
|
directory: '/apps/docs'
|
||||||
|
open-pull-requests-limit: 10
|
||||||
|
schedule:
|
||||||
|
interval: weekly
|
||||||
|
time: "02:00"
|
||||||
|
groups:
|
||||||
|
prod:
|
||||||
|
dependency-type: production
|
||||||
|
dev:
|
||||||
|
dependency-type: development
|
||||||
|
commit-message:
|
||||||
|
prefix: chore
|
||||||
|
include: scope
|
||||||
|
labels:
|
||||||
|
- "npm"
|
||||||
|
- "dependencies"
|
||||||
|
- "documentation"
|
||||||
|
|||||||
@@ -5,13 +5,13 @@ on:
|
|||||||
branches:
|
branches:
|
||||||
- 'main'
|
- 'main'
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- 'docs/**'
|
- 'apps/docs/content/**'
|
||||||
pull_request:
|
pull_request:
|
||||||
# The branches below must be a subset of the branches above
|
# The branches below must be a subset of the branches above
|
||||||
branches:
|
branches:
|
||||||
- 'main'
|
- 'main'
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- 'docs/**'
|
- 'apps/docs/content/**'
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
|
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
|
||||||
|
|||||||
+8
-7
@@ -57,19 +57,18 @@ console/.angular
|
|||||||
pkg/**/**.connect.go
|
pkg/**/**.connect.go
|
||||||
**.gen.go
|
**.gen.go
|
||||||
openapi/**/*.json
|
openapi/**/*.json
|
||||||
|
# multi-version proto artifacts
|
||||||
|
/proto/latest/
|
||||||
|
/proto/v*/
|
||||||
/internal/api/assets/authz.go
|
/internal/api/assets/authz.go
|
||||||
/internal/api/assets/router.go
|
/internal/api/assets/router.go
|
||||||
internal/api/ui/console/static
|
internal/api/ui/console/static
|
||||||
!internal/api/ui/console/static/gitkeep
|
!internal/api/ui/console/static/gitkeep
|
||||||
docs/docs/apis/auth
|
apps/docs/content/apis/assets/assets.mdx
|
||||||
docs/docs/apis/admin
|
apps/docs/content/reference/api/
|
||||||
docs/docs/apis/mgmt
|
|
||||||
docs/docs/apis/system
|
|
||||||
docs/docs/apis/proto
|
|
||||||
**/.sass-cache
|
|
||||||
/internal/api/ui/login/static/resources/themes/zitadel/css/zitadel.css
|
/internal/api/ui/login/static/resources/themes/zitadel/css/zitadel.css
|
||||||
/internal/api/ui/login/static/resources/themes/zitadel/css/zitadel.css.map
|
/internal/api/ui/login/static/resources/themes/zitadel/css/zitadel.css.map
|
||||||
zitadel-*-*
|
/zitadel-*-*
|
||||||
!apps/**/zitadel-*-*
|
!apps/**/zitadel-*-*
|
||||||
|
|
||||||
# local
|
# local
|
||||||
@@ -106,3 +105,5 @@ CLAUDE.md
|
|||||||
AGENTS.md
|
AGENTS.md
|
||||||
.mcp.json
|
.mcp.json
|
||||||
.gemini/*
|
.gemini/*
|
||||||
|
|
||||||
|
docs_old
|
||||||
@@ -2,6 +2,8 @@ version: "2"
|
|||||||
run:
|
run:
|
||||||
concurrency: 4
|
concurrency: 4
|
||||||
go: "1.24"
|
go: "1.24"
|
||||||
|
skip-dirs:
|
||||||
|
- apps/docs
|
||||||
linters:
|
linters:
|
||||||
enable:
|
enable:
|
||||||
- asciicheck
|
- asciicheck
|
||||||
@@ -121,6 +123,10 @@ issues:
|
|||||||
max-issues-per-linter: 0
|
max-issues-per-linter: 0
|
||||||
max-same-issues: 0
|
max-same-issues: 0
|
||||||
new-from-rev: origin/main
|
new-from-rev: origin/main
|
||||||
|
exclude-rules:
|
||||||
|
- path: apps/docs/.*
|
||||||
|
linters:
|
||||||
|
- typecheck
|
||||||
formatters:
|
formatters:
|
||||||
enable:
|
enable:
|
||||||
- gci
|
- gci
|
||||||
|
|||||||
@@ -2,3 +2,5 @@
|
|||||||
!console/src/app/proto/generated
|
!console/src/app/proto/generated
|
||||||
!internal/api/ui/console/static
|
!internal/api/ui/console/static
|
||||||
!.artifacts/bin/*/*/zitadel.local
|
!.artifacts/bin/*/*/zitadel.local
|
||||||
|
!apps/docs/content/apis/assets/assets.mdx
|
||||||
|
!apps/docs/content/reference/api/
|
||||||
|
|||||||
+5
-58
@@ -129,7 +129,7 @@ The code consists of the following parts:
|
|||||||
| API definitions | Specifications of the API | [Protobuf](https://developers.google.com/protocol-buffers) | [./proto/zitadel](./proto/zitadel) | [Contribute to API](#contribute-to-api) |
|
| API definitions | Specifications of the API | [Protobuf](https://developers.google.com/protocol-buffers) | [./proto/zitadel](./proto/zitadel) | [Contribute to API](#contribute-to-api) |
|
||||||
| Management Console | Frontend the user interacts with after log in | [Angular](https://angular.io), [Typescript](https://www.typescriptlang.org) | [./console](./console) | [Contribute to Frontend](#contribute-to-frontend) |
|
| Management Console | Frontend the user interacts with after log in | [Angular](https://angular.io), [Typescript](https://www.typescriptlang.org) | [./console](./console) | [Contribute to Frontend](#contribute-to-frontend) |
|
||||||
| Login | Modern authentication UI built with Next.js | [Next.js](https://nextjs.org), [React](https://reactjs.org), [TypeScript](https://www.typescriptlang.org) | [./apps/login](./apps/login) | [Contribute to Frontend](#contribute-to-frontend) |
|
| Login | Modern authentication UI built with Next.js | [Next.js](https://nextjs.org), [React](https://reactjs.org), [TypeScript](https://www.typescriptlang.org) | [./apps/login](./apps/login) | [Contribute to Frontend](#contribute-to-frontend) |
|
||||||
| Docs | Project documentation made with docusaurus | [Docusaurus](https://docusaurus.io/) | [./docs](./docs) | [Contribute to Frontend](#contribute-to-frontend) |
|
| Docs | Project documentation made with docusaurus | [Docusaurus](https://docusaurus.io/) | [./apps/docs](./apps/docs) | [Contribute to Frontend](#contribute-to-frontend) |
|
||||||
| translations | Internationalization files for default languages | YAML | [./console](./console) and [./internal](./internal) | [Contribute Translations](#contribute-translations) |
|
| translations | Internationalization files for default languages | YAML | [./console](./console) and [./internal](./internal) | [Contribute Translations](#contribute-translations) |
|
||||||
|
|
||||||
Please follow the guides to validate and test the code before you contribute.
|
Please follow the guides to validate and test the code before you contribute.
|
||||||
@@ -582,62 +582,9 @@ pnpm nx run @zitadel/client:build # Build after changes
|
|||||||
|
|
||||||
### Contribute to Docs
|
### Contribute to Docs
|
||||||
|
|
||||||
Project documentation is made with Docusaurus and is located under [./docs](./docs). The documentation uses **pnpm** and **Nx** for development and build processes.
|
Project documentation is located under [./apps/docs](./apps/docs).
|
||||||
|
Please refer to the [Docs README](./apps/docs/README.md) for detailed instructions on how to contribute to the documentation.
|
||||||
|
|
||||||
To start developing, make sure you followed the [quick start](#quick-start) steps.
|
|
||||||
|
|
||||||
#### Local Development
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Start development server (recommended)
|
|
||||||
pnpm nx run @zitadel/docs:dev
|
|
||||||
|
|
||||||
# Or start production server
|
|
||||||
pnpm nx run @zitadel/docs:prod
|
|
||||||
```
|
|
||||||
|
|
||||||
The Docs build process automatically:
|
|
||||||
|
|
||||||
1. Downloads required protoc plugins
|
|
||||||
2. Generates gRPC documentation from proto files
|
|
||||||
3. Generates API documentation from OpenAPI specs
|
|
||||||
4. Copies configuration files
|
|
||||||
5. Builds the Docusaurus site
|
|
||||||
|
|
||||||
#### Local testing
|
|
||||||
|
|
||||||
The documentation server will be available at http://localhost:3000 with live reload for fast development feedback.
|
|
||||||
|
|
||||||
#### Style guide
|
|
||||||
|
|
||||||
- **Code with variables**: Make sure that code snippets can be used by setting environment variables, instead of manually replacing a placeholder.
|
|
||||||
- **Embedded files**: When embedding mdx files, make sure the template ist prefixed by "\_" (lowdash). The content will be rendered inside the parent page, but is not accessible individually (eg, by search).
|
|
||||||
- **Don't repeat yourself**: When using the same content in multiple places, save and manage the content as separate file and make use of embedded files to import it into other docs pages.
|
|
||||||
- **Embedded code**: You can embed code snippets from a repository. See the [plugin](https://github.com/saucelabs/docusaurus-theme-github-codeblock#usage) for usage.
|
|
||||||
|
|
||||||
Following the [Google style guide](https://developers.google.com/style) is highly recommended. Its clear and concise guidelines ensure consistency and effective communication within the wider developer community.
|
|
||||||
|
|
||||||
The style guide covers a lot of material, so their [highlights](https://developers.google.com/style/highlights) page provides an overview of its most important points. Some of the points stated in the highlights that we care about most are given below:
|
|
||||||
|
|
||||||
- Be conversational and friendly without being frivolous.
|
|
||||||
- Use sentence case for document titles and section headings.
|
|
||||||
- Use active voice: make clear who's performing the action.
|
|
||||||
- Use descriptive link text.
|
|
||||||
|
|
||||||
#### Docs pull request
|
|
||||||
|
|
||||||
When making a pull request use `docs(<scope>): <short summary>` as title for the semantic release.
|
|
||||||
Scope can be left empty (omit the brackets) or refer to the top navigation sections.
|
|
||||||
|
|
||||||
#### Pass Quality Checks
|
|
||||||
|
|
||||||
Verify the Docs build correctly.
|
|
||||||
|
|
||||||
```bash
|
|
||||||
pnpm nx run @zitadel/docs:build
|
|
||||||
```
|
|
||||||
|
|
||||||
Fix the quality checks, add new checks that cover your changes and mark your pull request as ready for review when the pipeline checks pass.
|
|
||||||
|
|
||||||
## Contribute Translations
|
## Contribute Translations
|
||||||
|
|
||||||
@@ -657,7 +604,7 @@ You also have to add some changes to the following files:
|
|||||||
- [Register Local File](./console/src/app/app.module.ts) - Import and register the Angular locale, register `i18n-iso-countries` locale
|
- [Register Local File](./console/src/app/app.module.ts) - Import and register the Angular locale, register `i18n-iso-countries` locale
|
||||||
- [Exclude from Angular prebundle](./console/angular.json) - Add `i18n-iso-countries/langs/<locale>.json` to `prebundle.exclude`
|
- [Exclude from Angular prebundle](./console/angular.json) - Add `i18n-iso-countries/langs/<locale>.json` to `prebundle.exclude`
|
||||||
- [Add Supported Language](./console/src/app/utils/language.ts)
|
- [Add Supported Language](./console/src/app/utils/language.ts)
|
||||||
- [Customized Text Docs](./docs/docs/guides/manage/customize/texts.md)
|
- [Customized Text Docs](./apps/docs/docs/guides/manage/customize/texts.md)
|
||||||
- [Add language option](./internal/api/ui/login/static/templates/external_not_found_option.html)
|
- [Add language option](./internal/api/ui/login/static/templates/external_not_found_option.html)
|
||||||
|
|
||||||
### Login v2 (Next.js)
|
### Login v2 (Next.js)
|
||||||
@@ -737,7 +684,7 @@ The category shows which part of Zitadel is affected.
|
|||||||
- **category: backend**: The backend includes the APIs, event store, command and query side. This is developed in golang.
|
- **category: backend**: The backend includes the APIs, event store, command and query side. This is developed in golang.
|
||||||
- **category: ci**: ci is all about continuous integration and pipelines.
|
- **category: ci**: ci is all about continuous integration and pipelines.
|
||||||
- **category: design**: All about the ux/ui of Zitadel
|
- **category: design**: All about the ux/ui of Zitadel
|
||||||
- **category: docs**: Adjustments or new documentations, this can be found in the docs folder.
|
- **category: docs**: Adjustments or new documentations, this can be found in the apps/docs folder.
|
||||||
- **category: frontend**: The frontend concerns on the one hand the Zitadel Management Console (Angular) and on the other hand the Login (gohtml)
|
- **category: frontend**: The frontend concerns on the one hand the Zitadel Management Console (Angular) and on the other hand the Login (gohtml)
|
||||||
- **category: infra**: Infrastructure does include many different parts. E.g Terraform-provider, docker, metrics, etc.
|
- **category: infra**: Infrastructure does include many different parts. E.g Terraform-provider, docker, metrics, etc.
|
||||||
- **category: translation**: Everything concerning translations or new languages
|
- **category: translation**: Everything concerning translations or new languages
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ The following files and directories, including their subdirectories, are license
|
|||||||
|
|
||||||
```
|
```
|
||||||
proto/
|
proto/
|
||||||
|
apps/docs/
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<p align="center">
|
<p align="center">
|
||||||
<img src="./docs/static/logos/zitadel-logo-dark@2x.png#gh-light-mode-only" alt="Zitadel Logo" max-height="200px" width="auto" />
|
<img src="./apps/docs/static/logos/zitadel-logo-dark@2x.png#gh-light-mode-only" alt="Zitadel Logo" max-height="200px" width="auto" />
|
||||||
<img src="./docs/static/logos/zitadel-logo-light@2x.png#gh-dark-mode-only" alt="Zitadel Logo" max-height="200px" width="auto" />
|
<img src="./apps/docs/static/logos/zitadel-logo-light@2x.png#gh-dark-mode-only" alt="Zitadel Logo" max-height="200px" width="auto" />
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p align="center">
|
<p align="center">
|
||||||
@@ -27,7 +27,7 @@
|
|||||||
|
|
||||||
<p align="center">
|
<p align="center">
|
||||||
<a href="https://openid.net/certification/#OPs" alt="OpenID Connect Certified">
|
<a href="https://openid.net/certification/#OPs" alt="OpenID Connect Certified">
|
||||||
<img src="./docs/static/logos/oidc-cert.png" /></a>
|
<img src="./apps/docs/static/logos/oidc-cert.png" /></a>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
Are you searching for a user management tool that is quickly set up like Auth0 and open source like Keycloak?
|
Are you searching for a user management tool that is quickly set up like Auth0 and open source like Keycloak?
|
||||||
|
|||||||
+67
-29
@@ -20,7 +20,9 @@
|
|||||||
"!{workspaceRoot}/**/integration_test/**/*"
|
"!{workspaceRoot}/**/integration_test/**/*"
|
||||||
],
|
],
|
||||||
"pack": [
|
"pack": [
|
||||||
{ "env": "VERSION" },
|
{
|
||||||
|
"env": "VERSION"
|
||||||
|
},
|
||||||
"runtime"
|
"runtime"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
@@ -65,10 +67,16 @@
|
|||||||
],
|
],
|
||||||
"command": "bash -c 'CGO_ENABLED=0 go build -o .artifacts/bin/$(go env GOOS)/$(go env GOARCH)/zitadel.local -ldflags=\"-s -w\"'",
|
"command": "bash -c 'CGO_ENABLED=0 go build -o .artifacts/bin/$(go env GOOS)/$(go env GOARCH)/zitadel.local -ldflags=\"-s -w\"'",
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{ "runtime": "go env GOOS" },
|
{
|
||||||
{ "runtime": "go env GOARCH" },
|
"runtime": "go env GOOS"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"runtime": "go env GOARCH"
|
||||||
|
},
|
||||||
"runtime",
|
"runtime",
|
||||||
{"dependentTasksOutputFiles": "internal/api/ui/console/static/**/*"}
|
{
|
||||||
|
"dependentTasksOutputFiles": "internal/api/ui/console/static/**/*"
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"outputs": [
|
"outputs": [
|
||||||
"{workspaceRoot}/.artifacts/bin/*/*/zitadel.local"
|
"{workspaceRoot}/.artifacts/bin/*/*/zitadel.local"
|
||||||
@@ -82,13 +90,17 @@
|
|||||||
"generate-statik"
|
"generate-statik"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"lint-install":{
|
"lint-install": {
|
||||||
"description": "Installs golangci-lint binary for linting. Using go install is not recommended in the official docs, because this can produce non-deterministic results.",
|
"description": "Installs golangci-lint binary for linting. Using go install is not recommended in the official docs, because this can produce non-deterministic results.",
|
||||||
"cache": true,
|
"cache": true,
|
||||||
"command": "curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/HEAD/install.sh | sh -s -- -b .artifacts/bin/$(go env GOOS)/$(go env GOARCH) v2.5.0",
|
"command": "curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/HEAD/install.sh | sh -s -- -b .artifacts/bin/$(go env GOOS)/$(go env GOARCH) v2.5.0",
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{ "runtime": "go env GOOS" },
|
{
|
||||||
{ "runtime": "go env GOARCH" }
|
"runtime": "go env GOOS"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"runtime": "go env GOARCH"
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"outputs": [
|
"outputs": [
|
||||||
"{workspaceRoot}/.artifacts/bin/*/*/golangci-lint"
|
"{workspaceRoot}/.artifacts/bin/*/*/golangci-lint"
|
||||||
@@ -137,8 +149,12 @@
|
|||||||
"command": "go build -cover -race -tags integration -o .artifacts/bin/$(go env GOOS)/$(go env GOARCH)/zitadel.test main.go",
|
"command": "go build -cover -race -tags integration -o .artifacts/bin/$(go env GOOS)/$(go env GOARCH)/zitadel.test main.go",
|
||||||
"cache": true,
|
"cache": true,
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{ "runtime": "go env GOOS" },
|
{
|
||||||
{ "runtime": "go env GOARCH" },
|
"runtime": "go env GOOS"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"runtime": "go env GOARCH"
|
||||||
|
},
|
||||||
"sources",
|
"sources",
|
||||||
"{workspaceRoot}/internal/integration/**",
|
"{workspaceRoot}/internal/integration/**",
|
||||||
"{workspaceRoot}/go*"
|
"{workspaceRoot}/go*"
|
||||||
@@ -193,8 +209,12 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{ "runtime": "go env GOOS" },
|
{
|
||||||
{ "runtime": "go env GOARCH" },
|
"runtime": "go env GOOS"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"runtime": "go env GOARCH"
|
||||||
|
},
|
||||||
"sources",
|
"sources",
|
||||||
"{workspaceRoot}/internal/integration/**",
|
"{workspaceRoot}/internal/integration/**",
|
||||||
"{workspaceRoot}/go*"
|
"{workspaceRoot}/go*"
|
||||||
@@ -215,7 +235,9 @@
|
|||||||
"command": "find internal/api/ui/console/static -mindepth 1 ! -name 'gitkeep' -delete -print && cp -r -v console/dist/console/* internal/api/ui/console/static",
|
"command": "find internal/api/ui/console/static -mindepth 1 ! -name 'gitkeep' -delete -print && cp -r -v console/dist/console/* internal/api/ui/console/static",
|
||||||
"cache": true,
|
"cache": true,
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{"dependentTasksOutputFiles": "console/dist/console/**/*"}
|
{
|
||||||
|
"dependentTasksOutputFiles": "console/dist/console/**/*"
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"outputs": [
|
"outputs": [
|
||||||
"{workspaceRoot}/internal/api/ui/console/static"
|
"{workspaceRoot}/internal/api/ui/console/static"
|
||||||
@@ -231,7 +253,6 @@
|
|||||||
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install go.uber.org/mock/[email protected]",
|
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install go.uber.org/mock/[email protected]",
|
||||||
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install golang.org/x/tools/cmd/[email protected]",
|
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install golang.org/x/tools/cmd/[email protected]",
|
||||||
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install github.com/rakyll/[email protected]",
|
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install github.com/rakyll/[email protected]",
|
||||||
|
|
||||||
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install github.com/bufbuild/buf/cmd/[email protected]",
|
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install github.com/bufbuild/buf/cmd/[email protected]",
|
||||||
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install google.golang.org/protobuf/cmd/[email protected]",
|
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install google.golang.org/protobuf/cmd/[email protected]",
|
||||||
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install google.golang.org/grpc/cmd/[email protected]",
|
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install google.golang.org/grpc/cmd/[email protected]",
|
||||||
@@ -240,15 +261,18 @@
|
|||||||
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install github.com/envoyproxy/[email protected]",
|
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install github.com/envoyproxy/[email protected]",
|
||||||
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install connectrpc.com/connect/cmd/[email protected]",
|
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install connectrpc.com/connect/cmd/[email protected]",
|
||||||
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install google.golang.org/protobuf/cmd/[email protected]",
|
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install google.golang.org/protobuf/cmd/[email protected]",
|
||||||
|
|
||||||
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install ./internal/protoc/protoc-gen-authoption",
|
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install ./internal/protoc/protoc-gen-authoption",
|
||||||
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install ./internal/protoc/protoc-gen-zitadel"
|
"GOBIN=${PWD}/.artifacts/bin/$(go env GOOS)/$(go env GOARCH) go install ./internal/protoc/protoc-gen-zitadel"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"cache": true,
|
"cache": true,
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{ "runtime": "go env GOOS" },
|
{
|
||||||
{ "runtime": "go env GOARCH" },
|
"runtime": "go env GOOS"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"runtime": "go env GOARCH"
|
||||||
|
},
|
||||||
"{workspaceRoot}/internal/protoc/protoc-gen-authoption/**/*",
|
"{workspaceRoot}/internal/protoc/protoc-gen-authoption/**/*",
|
||||||
"{workspaceRoot}/internal/protoc/protoc-gen-zitadel/**/*"
|
"{workspaceRoot}/internal/protoc/protoc-gen-zitadel/**/*"
|
||||||
],
|
],
|
||||||
@@ -257,7 +281,6 @@
|
|||||||
"{workspaceRoot}/.artifacts/bin/*/*/mockgen",
|
"{workspaceRoot}/.artifacts/bin/*/*/mockgen",
|
||||||
"{workspaceRoot}/.artifacts/bin/*/*/stringer",
|
"{workspaceRoot}/.artifacts/bin/*/*/stringer",
|
||||||
"{workspaceRoot}/.artifacts/bin/*/*/statik",
|
"{workspaceRoot}/.artifacts/bin/*/*/statik",
|
||||||
|
|
||||||
"{workspaceRoot}/.artifacts/bin/*/*/buf",
|
"{workspaceRoot}/.artifacts/bin/*/*/buf",
|
||||||
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-go",
|
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-go",
|
||||||
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-go-grpc",
|
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-go-grpc",
|
||||||
@@ -265,7 +288,6 @@
|
|||||||
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-openapiv2",
|
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-openapiv2",
|
||||||
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-validate",
|
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-validate",
|
||||||
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-connect-go",
|
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-connect-go",
|
||||||
|
|
||||||
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-authoption",
|
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-authoption",
|
||||||
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-zitadel"
|
"{workspaceRoot}/.artifacts/bin/*/*/protoc-gen-zitadel"
|
||||||
]
|
]
|
||||||
@@ -313,8 +335,12 @@
|
|||||||
},
|
},
|
||||||
"cache": true,
|
"cache": true,
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{ "runtime": "go env GOOS" },
|
{
|
||||||
{ "runtime": "go env GOARCH" },
|
"runtime": "go env GOOS"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"runtime": "go env GOARCH"
|
||||||
|
},
|
||||||
"{workspaceRoot}/internal/statik/generate.go",
|
"{workspaceRoot}/internal/statik/generate.go",
|
||||||
"{workspaceRoot}/internal/notification/statik/generate.go",
|
"{workspaceRoot}/internal/notification/statik/generate.go",
|
||||||
"{workspaceRoot}/internal/api/ui/login/static/resources/generate.go",
|
"{workspaceRoot}/internal/api/ui/login/static/resources/generate.go",
|
||||||
@@ -332,7 +358,7 @@
|
|||||||
"dependsOn": [
|
"dependsOn": [
|
||||||
"generate-install"
|
"generate-install"
|
||||||
],
|
],
|
||||||
"command": "mkdir -p docs/apis/assets && go run internal/api/assets/generator/asset_generator.go -directory=internal/api/assets/generator/ -assets=docs/apis/assets/assets.md",
|
"command": "mkdir -p apps/docs/content/apis/assets && go run internal/api/assets/generator/asset_generator.go -directory=internal/api/assets/generator/ -assets=apps/docs/content/apis/assets/assets.mdx",
|
||||||
"cache": true,
|
"cache": true,
|
||||||
"inputs": [
|
"inputs": [
|
||||||
"{workspaceRoot}/internal/api/assets/generator/asset_generator.go"
|
"{workspaceRoot}/internal/api/assets/generator/asset_generator.go"
|
||||||
@@ -340,7 +366,7 @@
|
|||||||
"outputs": [
|
"outputs": [
|
||||||
"{workspaceRoot}/internal/api/assets/authz.go",
|
"{workspaceRoot}/internal/api/assets/authz.go",
|
||||||
"{workspaceRoot}/internal/api/assets/router.go",
|
"{workspaceRoot}/internal/api/assets/router.go",
|
||||||
"{workspaceRoot}/docs/apis/assets/assets.md"
|
"{workspaceRoot}/apps/docs/content/apis/assets/assets.mdx"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"generate-go": {
|
"generate-go": {
|
||||||
@@ -372,7 +398,9 @@
|
|||||||
"cache": true,
|
"cache": true,
|
||||||
"inputs": [
|
"inputs": [
|
||||||
"pack",
|
"pack",
|
||||||
{ "env": "ZITADEL_VERSION" }
|
{
|
||||||
|
"env": "ZITADEL_VERSION"
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"outputs": [
|
"outputs": [
|
||||||
"{workspaceRoot}/.artifacts/pack/zitadel-darwin-amd64.tar.gz",
|
"{workspaceRoot}/.artifacts/pack/zitadel-darwin-amd64.tar.gz",
|
||||||
@@ -389,7 +417,9 @@
|
|||||||
"cache": true,
|
"cache": true,
|
||||||
"inputs": [
|
"inputs": [
|
||||||
"pack",
|
"pack",
|
||||||
{ "env": "ZITADEL_VERSION" }
|
{
|
||||||
|
"env": "ZITADEL_VERSION"
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"outputs": [
|
"outputs": [
|
||||||
"{workspaceRoot}/.artifacts/pack/zitadel-darwin-arm64.tar.gz",
|
"{workspaceRoot}/.artifacts/pack/zitadel-darwin-arm64.tar.gz",
|
||||||
@@ -406,7 +436,9 @@
|
|||||||
"cache": true,
|
"cache": true,
|
||||||
"inputs": [
|
"inputs": [
|
||||||
"pack",
|
"pack",
|
||||||
{ "env": "ZITADEL_VERSION" }
|
{
|
||||||
|
"env": "ZITADEL_VERSION"
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"outputs": [
|
"outputs": [
|
||||||
"{workspaceRoot}/.artifacts/pack/zitadel-linux-amd64.tar.gz",
|
"{workspaceRoot}/.artifacts/pack/zitadel-linux-amd64.tar.gz",
|
||||||
@@ -423,7 +455,9 @@
|
|||||||
"cache": true,
|
"cache": true,
|
||||||
"inputs": [
|
"inputs": [
|
||||||
"pack",
|
"pack",
|
||||||
{ "env": "ZITADEL_VERSION" }
|
{
|
||||||
|
"env": "ZITADEL_VERSION"
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"outputs": [
|
"outputs": [
|
||||||
"{workspaceRoot}/.artifacts/pack/zitadel-linux-arm64.tar.gz",
|
"{workspaceRoot}/.artifacts/pack/zitadel-linux-arm64.tar.gz",
|
||||||
@@ -440,7 +474,9 @@
|
|||||||
"cache": true,
|
"cache": true,
|
||||||
"inputs": [
|
"inputs": [
|
||||||
"pack",
|
"pack",
|
||||||
{ "env": "ZITADEL_VERSION" }
|
{
|
||||||
|
"env": "ZITADEL_VERSION"
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"outputs": [
|
"outputs": [
|
||||||
"{workspaceRoot}/.artifacts/pack/zitadel-windows-amd64.tar.gz",
|
"{workspaceRoot}/.artifacts/pack/zitadel-windows-amd64.tar.gz",
|
||||||
@@ -457,7 +493,9 @@
|
|||||||
"cache": true,
|
"cache": true,
|
||||||
"inputs": [
|
"inputs": [
|
||||||
"pack",
|
"pack",
|
||||||
{ "env": "ZITADEL_VERSION" }
|
{
|
||||||
|
"env": "ZITADEL_VERSION"
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"outputs": [
|
"outputs": [
|
||||||
"{workspaceRoot}/.artifacts/pack/zitadel-windows-arm64.tar.gz",
|
"{workspaceRoot}/.artifacts/pack/zitadel-windows-arm64.tar.gz",
|
||||||
@@ -465,4 +503,4 @@
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,39 @@
|
|||||||
|
# deps
|
||||||
|
/node_modules
|
||||||
|
|
||||||
|
# generated content
|
||||||
|
.source
|
||||||
|
scanned-urls.json
|
||||||
|
|
||||||
|
# test & build
|
||||||
|
/coverage
|
||||||
|
/.next/
|
||||||
|
/out/
|
||||||
|
/build
|
||||||
|
*.tsbuildinfo
|
||||||
|
|
||||||
|
# misc
|
||||||
|
.DS_Store
|
||||||
|
*.pem
|
||||||
|
/.pnp
|
||||||
|
.pnp.js
|
||||||
|
npm-debug.log*
|
||||||
|
yarn-debug.log*
|
||||||
|
yarn-error.log*
|
||||||
|
|
||||||
|
# others
|
||||||
|
.env*.local
|
||||||
|
.vercel
|
||||||
|
next-env.d.ts
|
||||||
|
|
||||||
|
# generated api docs
|
||||||
|
/content/reference/api
|
||||||
|
/content/reference/api-v1
|
||||||
|
/openapi/
|
||||||
|
|
||||||
|
# multi-version artifacts
|
||||||
|
/content/versions.json
|
||||||
|
/content/v*/
|
||||||
|
/public/v*
|
||||||
|
/.temp/
|
||||||
|
/.source
|
||||||
@@ -0,0 +1,83 @@
|
|||||||
|
# @zitadel/docs
|
||||||
|
|
||||||
|
Documentation for Zitadel, built with [Fumadocs](https://fumadocs.dev) and [Next.js](https://nextjs.org).
|
||||||
|
|
||||||
|
## Getting Started
|
||||||
|
|
||||||
|
Ensure you have followed the [root quick start](../../CONTRIBUTING.md#quick-start) to set up dependencies.
|
||||||
|
|
||||||
|
### Local Development
|
||||||
|
|
||||||
|
Start the development server:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
pnpm nx run @zitadel/docs:dev
|
||||||
|
```
|
||||||
|
|
||||||
|
The site will be available at http://localhost:3000.
|
||||||
|
|
||||||
|
### Scripts
|
||||||
|
|
||||||
|
Key scripts for documentation workflows:
|
||||||
|
|
||||||
|
| Script | Description |
|
||||||
|
| :--- | :--- |
|
||||||
|
| `dev` | Starts the development server. |
|
||||||
|
| `build` | Builds the production application. |
|
||||||
|
| `fetch:remote-content` | Fetches remote tags and referenced content. |
|
||||||
|
| `generate` | Runs all generation steps (`fetch:remote-content`, `generate:proto-docs`, `generate:api-reference`, `generate:index-pages`). |
|
||||||
|
| `check:links` | Validates content integrity (broken links, missing frontmatter, schema errors). |
|
||||||
|
| `check-types` | Validates typescript types. |
|
||||||
|
| `test` | Runs all validation steps (`check-types`, `check:links`). |
|
||||||
|
| `lint` | checks for code style and syntax errors (ESLint). |
|
||||||
|
| `clean` | Cleans the build output and generated files. |
|
||||||
|
|
||||||
|
### Validation
|
||||||
|
|
||||||
|
* **Code Quality**: Run `pnpm lint` to check for syntax and style issues in JS/TS/MDX files.
|
||||||
|
* **Content Integrity**: Run `pnpm check:links` to validate content structure, including:
|
||||||
|
* Broken internal links
|
||||||
|
* Missing required frontmatter (e.g., `title`)
|
||||||
|
* Image references
|
||||||
|
|
||||||
|
## Contributing
|
||||||
|
|
||||||
|
### Build Process
|
||||||
|
|
||||||
|
The docs build process automatically handling the following steps via `generate`:
|
||||||
|
1. Downloads required protoc plugins.
|
||||||
|
2. Generates gRPC documentation from proto files.
|
||||||
|
3. Generates API documentation from OpenAPI specs.
|
||||||
|
4. Generates index files for directory structures.
|
||||||
|
|
||||||
|
### Style Guide
|
||||||
|
|
||||||
|
- **Variables**: Use environment variables in code snippets where possible.
|
||||||
|
- **Embedded Content**: Use `_filename.mdx` for content embedded in other pages (not indexed individually).
|
||||||
|
- **Code Embedding**: Use the `file` property in code blocks to embed code from the repo.
|
||||||
|
- **Voice**: Use active voice and sentence case for titles.
|
||||||
|
|
||||||
|
Refer to the [Google Developer Style Guide](https://developers.google.com/style) for general guidelines.
|
||||||
|
|
||||||
|
### Adding Content
|
||||||
|
|
||||||
|
All documentation content is located in the `content` directory. Note that the system strictly accepts **only `.mdx` files**.
|
||||||
|
|
||||||
|
To add a new page:
|
||||||
|
1. Create a `.mdx` file in the appropriate subdirectory of [`content`](./content).
|
||||||
|
2. Register the new page in the sidebar configuration at [`lib/sidebar-data.ts`](./lib/sidebar-data.ts) to make it accessible in the navigation.
|
||||||
|
|
||||||
|
|
||||||
|
### Pull Requests
|
||||||
|
|
||||||
|
Use `docs(<scope>): <short summary>` for PR titles.
|
||||||
|
Pass quality checks before submitting:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
pnpm nx run @zitadel/docs:build
|
||||||
|
pnpm nx run @zitadel/docs:check:links
|
||||||
|
```
|
||||||
|
|
||||||
|
You can also run specific steps individually:
|
||||||
|
* `pnpm fetch:remote-content`
|
||||||
|
* `pnpm generate:api-reference`
|
||||||
@@ -0,0 +1,7 @@
|
|||||||
|
import { HomeLayout } from 'fumadocs-ui/layouts/home';
|
||||||
|
import { baseOptions } from '@/lib/layout.shared';
|
||||||
|
import { ReactNode } from 'react';
|
||||||
|
|
||||||
|
export default function Layout({ children }: { children: ReactNode }) {
|
||||||
|
return <HomeLayout {...baseOptions()}>{children}</HomeLayout>;
|
||||||
|
}
|
||||||
@@ -0,0 +1,81 @@
|
|||||||
|
import { source, versionSource } from '@/lib/source';
|
||||||
|
import { ReactNode } from 'react';
|
||||||
|
import { DocsLayout } from 'fumadocs-ui/layouts/docs';
|
||||||
|
import { baseOptions } from '@/lib/layout.shared';
|
||||||
|
import { buildCustomTree } from '@/lib/custom-tree';
|
||||||
|
import rawVersions from '@/content/versions.json';
|
||||||
|
|
||||||
|
const versions = rawVersions as any[];
|
||||||
|
import { VersionSelector } from '@/components/version-selector';
|
||||||
|
|
||||||
|
export default async function Layout(props: { children: ReactNode; params: Promise<{ slug?: string[] }> }) {
|
||||||
|
const params = await props.params;
|
||||||
|
const slug = params.slug || [];
|
||||||
|
|
||||||
|
// Determine current version and tail path
|
||||||
|
// If first slug segment matches a version param (e.g. v4.10), that's the version.
|
||||||
|
// Otherwise it's latest.
|
||||||
|
const versionParam = slug[0] && versions.find(v => v.param === slug[0]) ? slug[0] : undefined;
|
||||||
|
const currentVersion = versionParam || 'latest';
|
||||||
|
|
||||||
|
const allPages = [...source.getPages(), ...versionSource.getPages()];
|
||||||
|
const labelsMap = new Map<string, string>();
|
||||||
|
allPages.forEach(p => {
|
||||||
|
if (p.data.sidebar_label) {
|
||||||
|
labelsMap.set(p.url, p.data.sidebar_label);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
let tree = source.pageTree;
|
||||||
|
if (currentVersion !== 'latest') {
|
||||||
|
// Hoist the version folder to root to flatten sidebar
|
||||||
|
// versionSource.pageTree -> [ v4.10 folder, v4.9 folder ... ]
|
||||||
|
// We want the children of the specific version folder.
|
||||||
|
|
||||||
|
const children = (versionSource.pageTree as any).children || [];
|
||||||
|
|
||||||
|
const versionFolder = children.find((node: any) => {
|
||||||
|
if (node.type !== 'folder') return false;
|
||||||
|
// Check if the folder's index page belongs to this version
|
||||||
|
if (node.index?.url && node.index.url.includes(`/${currentVersion}`)) return true;
|
||||||
|
// Fallback: check first child if index missing
|
||||||
|
if (node.children?.[0]?.url?.includes(`/${currentVersion}`)) return true;
|
||||||
|
return false;
|
||||||
|
});
|
||||||
|
|
||||||
|
if (versionFolder) {
|
||||||
|
// Hoist children
|
||||||
|
const hoistedTree = {
|
||||||
|
name: versionFolder.name,
|
||||||
|
children: versionFolder.children,
|
||||||
|
} as any;
|
||||||
|
|
||||||
|
// Apply custom sidebar structure (from local sidebar-data.ts)
|
||||||
|
// We strip the prefix '/v4.10' so the lookup matches generic keys 'guides/...'
|
||||||
|
// The logs showed the URLs start with /[version] not /docs/[version]
|
||||||
|
const prefix = currentVersion === 'latest' ? '/docs' : `/${currentVersion}`;
|
||||||
|
tree = buildCustomTree(hoistedTree, {
|
||||||
|
stripPrefix: prefix,
|
||||||
|
labels: labelsMap
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
tree = buildCustomTree(versionSource.pageTree, { labels: labelsMap });
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
tree = buildCustomTree(source.pageTree, { labels: labelsMap });
|
||||||
|
}
|
||||||
|
|
||||||
|
return (
|
||||||
|
<DocsLayout
|
||||||
|
tree={tree}
|
||||||
|
{...baseOptions()}
|
||||||
|
sidebar={{
|
||||||
|
banner: (
|
||||||
|
<VersionSelector />
|
||||||
|
),
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
{props.children}
|
||||||
|
</DocsLayout>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -0,0 +1,79 @@
|
|||||||
|
import { getPageImage, getPage, source } from '@/lib/source';
|
||||||
|
import {
|
||||||
|
DocsBody,
|
||||||
|
DocsDescription,
|
||||||
|
DocsPage,
|
||||||
|
DocsTitle,
|
||||||
|
} from 'fumadocs-ui/layouts/docs/page';
|
||||||
|
import { notFound } from 'next/navigation';
|
||||||
|
import { getMDXComponents } from '@/mdx-components';
|
||||||
|
import type { Metadata } from 'next';
|
||||||
|
import { createRelativeLink } from 'fumadocs-ui/mdx';
|
||||||
|
import { Callout } from 'fumadocs-ui/components/callout';
|
||||||
|
import { Tab, Tabs } from 'fumadocs-ui/components/tabs';
|
||||||
|
import { Feedback } from '@/components/feedback';
|
||||||
|
|
||||||
|
export default async function Page(props: any) {
|
||||||
|
const params = await props.params;
|
||||||
|
const { page, source: pageSource } = getPage(params.slug);
|
||||||
|
if (!page) notFound();
|
||||||
|
|
||||||
|
const MDX = page.data.body;
|
||||||
|
|
||||||
|
return (
|
||||||
|
<DocsPage toc={page.data.toc} full={page.data.full}>
|
||||||
|
<DocsTitle>{page.data.title}</DocsTitle>
|
||||||
|
<DocsDescription>{page.data.description}</DocsDescription>
|
||||||
|
<DocsBody>
|
||||||
|
<MDX
|
||||||
|
components={getMDXComponents({
|
||||||
|
Callout,
|
||||||
|
Tab,
|
||||||
|
Tabs,
|
||||||
|
// this allows you to link to other pages with relative file paths
|
||||||
|
a: createRelativeLink(pageSource, page),
|
||||||
|
})}
|
||||||
|
/>
|
||||||
|
</DocsBody>
|
||||||
|
<Feedback />
|
||||||
|
</DocsPage>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
export const dynamicParams = true;
|
||||||
|
export const revalidate = 3600;
|
||||||
|
|
||||||
|
export async function generateStaticParams() {
|
||||||
|
return source.generateParams();
|
||||||
|
}
|
||||||
|
|
||||||
|
export async function generateMetadata(
|
||||||
|
props: any,
|
||||||
|
): Promise<Metadata> {
|
||||||
|
const params = await props.params;
|
||||||
|
const { page } = getPage(params.slug);
|
||||||
|
if (!page) notFound();
|
||||||
|
const baseUrl = 'https://zitadel.com/docs';
|
||||||
|
const url = params.slug ? `${baseUrl}/${params.slug.join('/')}` : baseUrl;
|
||||||
|
|
||||||
|
let canonicalUrl = url;
|
||||||
|
|
||||||
|
if (params.slug?.[0]?.startsWith('v')) {
|
||||||
|
const unversionedSlug = params.slug.slice(1);
|
||||||
|
const unversionedPage = source.getPage(unversionedSlug);
|
||||||
|
if (unversionedPage) {
|
||||||
|
canonicalUrl = `${baseUrl}${unversionedPage.url === '/' ? '' : unversionedPage.url}`;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
title: page.data.title,
|
||||||
|
description: page.data.description,
|
||||||
|
alternates: {
|
||||||
|
canonical: canonicalUrl,
|
||||||
|
},
|
||||||
|
openGraph: {
|
||||||
|
images: getPageImage(page).url,
|
||||||
|
},
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -0,0 +1,7 @@
|
|||||||
|
import { source } from '@/lib/source';
|
||||||
|
import { createFromSource } from 'fumadocs-core/search/server';
|
||||||
|
|
||||||
|
export const { GET } = createFromSource(source, {
|
||||||
|
// https://docs.orama.com/docs/orama-js/supported-languages
|
||||||
|
language: 'english',
|
||||||
|
});
|
||||||
@@ -0,0 +1,408 @@
|
|||||||
|
@import 'tailwindcss';
|
||||||
|
@import 'fumadocs-ui/css/neutral.css';
|
||||||
|
@import 'fumadocs-ui/css/preset.css';
|
||||||
|
@import 'fumadocs-openapi/css/preset.css';
|
||||||
|
|
||||||
|
@theme {
|
||||||
|
/* 1. REGISTER STANDARD UTILITIES */
|
||||||
|
--color-background: hsl(var(--background));
|
||||||
|
--color-foreground: hsl(var(--foreground));
|
||||||
|
--color-card: hsl(var(--card));
|
||||||
|
--color-card-foreground: hsl(var(--card-foreground));
|
||||||
|
--color-popover: hsl(var(--popover));
|
||||||
|
--color-popover-foreground: hsl(var(--popover-foreground));
|
||||||
|
--color-primary: hsl(var(--primary));
|
||||||
|
--color-primary-foreground: hsl(var(--primary-foreground));
|
||||||
|
--color-secondary: hsl(var(--secondary));
|
||||||
|
--color-secondary-foreground: hsl(var(--secondary-foreground));
|
||||||
|
--color-muted: hsl(var(--muted));
|
||||||
|
--color-muted-foreground: hsl(var(--muted-foreground));
|
||||||
|
--color-accent: hsl(var(--accent));
|
||||||
|
--color-accent-foreground: hsl(var(--accent-foreground));
|
||||||
|
--color-destructive: hsl(var(--destructive));
|
||||||
|
--color-destructive-foreground: hsl(var(--destructive-foreground));
|
||||||
|
--color-border: hsl(var(--border));
|
||||||
|
--color-input: hsl(var(--input));
|
||||||
|
--color-ring: hsl(var(--ring));
|
||||||
|
|
||||||
|
/* 2. MAP FUMADOCS VARIABLES */
|
||||||
|
--color-fd-primary: var(--color-primary);
|
||||||
|
--color-fd-primary-foreground: var(--color-primary-foreground);
|
||||||
|
--color-fd-background: var(--color-background);
|
||||||
|
--color-fd-foreground: var(--color-foreground);
|
||||||
|
--color-fd-card: var(--color-card);
|
||||||
|
--color-fd-card-foreground: var(--color-card-foreground);
|
||||||
|
--color-fd-popover: var(--color-popover);
|
||||||
|
--color-fd-popover-foreground: var(--color-popover-foreground);
|
||||||
|
--color-fd-muted: var(--color-muted);
|
||||||
|
--color-fd-muted-foreground: var(--color-muted-foreground);
|
||||||
|
--color-fd-accent: var(--color-accent);
|
||||||
|
--color-fd-accent-foreground: var(--color-accent-foreground);
|
||||||
|
--color-fd-border: var(--color-border);
|
||||||
|
--color-fd-ring: var(--color-ring);
|
||||||
|
|
||||||
|
--color-zitadelpink: #ff2069;
|
||||||
|
--font-sans: var(--font-lato), "Lato", "ui-sans-serif", "system-ui";
|
||||||
|
}
|
||||||
|
|
||||||
|
/* --- LIGHT MODE VARIABLES --- */
|
||||||
|
:root {
|
||||||
|
--primary: 230 59% 58%;
|
||||||
|
--primary-foreground: 0 0% 100%;
|
||||||
|
|
||||||
|
--background: 0 0% 98%;
|
||||||
|
--foreground: 0 0% 10%;
|
||||||
|
|
||||||
|
--card: 0 0% 93%;
|
||||||
|
--card-foreground: 0 0% 10%;
|
||||||
|
|
||||||
|
--muted: 0 0% 96%;
|
||||||
|
--muted-foreground: 0 0% 45%;
|
||||||
|
|
||||||
|
--accent: 0 0% 92%;
|
||||||
|
--accent-foreground: 230 59% 58%;
|
||||||
|
|
||||||
|
--secondary: 240 4.8% 95.9%;
|
||||||
|
--secondary-foreground: 240 5.9% 10%;
|
||||||
|
|
||||||
|
--destructive: 0 84.2% 60.2%;
|
||||||
|
--destructive-foreground: 0 0% 98%;
|
||||||
|
|
||||||
|
--border: 0 0% 90%;
|
||||||
|
--input: 0 0% 90%;
|
||||||
|
--ring: 230 59% 58%;
|
||||||
|
|
||||||
|
--radius: 0.5rem;
|
||||||
|
--overlaycolor: #6c90b420;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* --- DARK MODE VARIABLES --- */
|
||||||
|
:root[class~="dark"], [data-theme="dark"] {
|
||||||
|
--primary: 340 100% 56%;
|
||||||
|
--primary-foreground: 0 0% 100%;
|
||||||
|
|
||||||
|
--background: 235 45% 14%;
|
||||||
|
--foreground: 0 0% 98%;
|
||||||
|
|
||||||
|
--card: 220 40% 25%;
|
||||||
|
--card-foreground: 0 0% 98%;
|
||||||
|
|
||||||
|
--muted: 230 43% 15%;
|
||||||
|
--muted-foreground: 230 20% 70%;
|
||||||
|
|
||||||
|
--accent: 230 43% 20%;
|
||||||
|
--accent-foreground: 340 100% 65%;
|
||||||
|
|
||||||
|
--secondary: 240 3.7% 15.9%;
|
||||||
|
--secondary-foreground: 0 0% 98%;
|
||||||
|
|
||||||
|
--destructive: 0 62.8% 30.6%;
|
||||||
|
--destructive-foreground: 0 0% 98%;
|
||||||
|
|
||||||
|
--border: 230 43% 25%;
|
||||||
|
--input: 230 43% 25%;
|
||||||
|
--ring: 340 100% 56%;
|
||||||
|
|
||||||
|
--overlaycolor: #ffffff15;
|
||||||
|
|
||||||
|
/* FORCE OVERRIDE for Fumadocs Variables */
|
||||||
|
--color-fd-background: hsl(var(--background));
|
||||||
|
--color-fd-foreground: hsl(var(--foreground));
|
||||||
|
--color-fd-primary: hsl(var(--primary));
|
||||||
|
--color-fd-primary-foreground: hsl(var(--primary-foreground));
|
||||||
|
--color-fd-card: hsl(var(--card));
|
||||||
|
--color-fd-card-foreground: hsl(var(--card-foreground));
|
||||||
|
--color-fd-popover: hsl(var(--card));
|
||||||
|
--color-fd-popover-foreground: hsl(var(--foreground));
|
||||||
|
--color-fd-muted: hsl(var(--muted));
|
||||||
|
--color-fd-muted-foreground: hsl(var(--muted-foreground));
|
||||||
|
--color-fd-accent: hsl(var(--accent));
|
||||||
|
--color-fd-accent-foreground: hsl(var(--accent-foreground));
|
||||||
|
--color-fd-border: hsl(var(--border));
|
||||||
|
--color-fd-ring: hsl(var(--ring));
|
||||||
|
}
|
||||||
|
|
||||||
|
@layer components {
|
||||||
|
|
||||||
|
/* 1. VISIBILITY HELPERS */
|
||||||
|
.hideondark { display: block !important; }
|
||||||
|
.hideonlight { display: none !important; }
|
||||||
|
|
||||||
|
:root[class~="dark"] .hideondark, [data-theme="dark"] .hideondark {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
:root[class~="dark"] .hideonlight, [data-theme="dark"] .hideonlight {
|
||||||
|
display: block !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 2. MAIN CARD LAYOUT (Tile Wrapper) */
|
||||||
|
.tile-wrapper {
|
||||||
|
@apply flex flex-row flex-wrap gap-6 my-6;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tile-wrapper > * {
|
||||||
|
@apply flex flex-col items-center text-center rounded-lg border relative;
|
||||||
|
|
||||||
|
background-color: hsl(var(--card)) !important;
|
||||||
|
border-color: hsl(var(--border));
|
||||||
|
|
||||||
|
justify-content: flex-start;
|
||||||
|
min-width: 160px;
|
||||||
|
min-height: 180px;
|
||||||
|
padding: 2rem;
|
||||||
|
padding-bottom: 3rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tile-wrapper > * > :last-child {
|
||||||
|
margin-top: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tile-wrapper > * > h3,
|
||||||
|
.tile-wrapper > * > h4,
|
||||||
|
.tile-wrapper > * > strong {
|
||||||
|
@apply mt-0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 3. ICON STYLING */
|
||||||
|
.custom-rounded {
|
||||||
|
@apply flex items-center justify-center p-2 rounded-full w-14 h-14 shrink-0 m-0;
|
||||||
|
}
|
||||||
|
.custom-rounded svg {
|
||||||
|
@apply fill-white h-7 w-7;
|
||||||
|
}
|
||||||
|
.custom-rounded i {
|
||||||
|
@apply text-white;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Gradients */
|
||||||
|
.custom-rounded-start { background: linear-gradient(40deg, #059669 30%, #047857); }
|
||||||
|
.custom-rounded-password { background: linear-gradient(40deg, #f59e0b 30%, #b45309); }
|
||||||
|
.custom-rounded-login, .custom-rounded-register { background: linear-gradient(40deg, #059669 30%, #047857); }
|
||||||
|
.custom-rounded-privatelabel, .custom-rounded-phone, .custom-rounded-email, .custom-rounded-storage, .custom-rounded-service { background: linear-gradient(40deg, #ff2069 30%, #cc1a54); }
|
||||||
|
.custom-rounded-split { background: linear-gradient(40deg, #ff2069, #cc1a54); }
|
||||||
|
.custom-rounded-texts, .custom-rounded-help, .custom-rounded-architecture { background: linear-gradient(40deg, #dc2626 30%, #db2777); }
|
||||||
|
.custom-rounded-system, .custom-rounded-apis, .custom-rounded-policy, .custom-rounded-instance { background: linear-gradient(40deg, #1f2937, #111827); }
|
||||||
|
|
||||||
|
/* 4. B2B / DIAGRAM LAYOUTS (Fixes the B2B Component) */
|
||||||
|
.flexrowbetween {
|
||||||
|
@apply flex flex-row items-center justify-around gap-4 my-8 w-full;
|
||||||
|
}
|
||||||
|
|
||||||
|
.arrowright {
|
||||||
|
@apply w-8 h-8 shrink-0 text-muted-foreground;
|
||||||
|
}
|
||||||
|
|
||||||
|
.b2borg, .b2bproject, .b2bapp, .b2buser {
|
||||||
|
@apply rounded-xl p-4 border text-left;
|
||||||
|
background: var(--overlaycolor);
|
||||||
|
border-color: hsl(var(--border));
|
||||||
|
}
|
||||||
|
|
||||||
|
.b2buser { @apply mt-4; }
|
||||||
|
|
||||||
|
.b2borg span, .b2bproject span, .b2bapp span, .b2buser span {
|
||||||
|
@apply ml-4 mb-2 block font-semibold;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Specific styling for the role text */
|
||||||
|
.b2bprojectrole {
|
||||||
|
@apply mt-2 ml-4 block text-sm opacity-80 font-normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 5. FOOTER / PAGINATION CARDS */
|
||||||
|
a.\@max-lg\:col-span-full {
|
||||||
|
@apply flex flex-col p-6 rounded-xl border transition-all no-underline;
|
||||||
|
background-color: hsl(var(--card)) !important;
|
||||||
|
border-color: hsl(var(--border)) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
a.\@max-lg\:col-span-full:hover {
|
||||||
|
@apply shadow-sm;
|
||||||
|
border-color: hsl(var(--primary)) !important;
|
||||||
|
background-color: hsl(var(--card)) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
a.\@max-lg\:col-span-full > div:first-child {
|
||||||
|
@apply flex items-center gap-3;
|
||||||
|
}
|
||||||
|
|
||||||
|
a.\@max-lg\:col-span-full svg {
|
||||||
|
@apply w-5 h-5 m-0;
|
||||||
|
}
|
||||||
|
|
||||||
|
a.\@max-lg\:col-span-full p {
|
||||||
|
margin-bottom: 0 !important;
|
||||||
|
margin-top: 0 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
a.\@max-lg\:col-span-full p.text-fd-muted-foreground {
|
||||||
|
@apply mt-2 text-sm opacity-80;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 6. VIDEO PLAYER WRAPPER */
|
||||||
|
/* Fixes aspect ratio for ReactPlayer embeds */
|
||||||
|
.player-wrapper {
|
||||||
|
@apply relative mb-8;
|
||||||
|
padding-top: 56.25%; /* 16:9 Aspect Ratio */
|
||||||
|
}
|
||||||
|
.react-player {
|
||||||
|
@apply absolute top-0 left-0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 7. GET STARTED BUTTON */
|
||||||
|
.get-started {
|
||||||
|
@apply inline-flex items-center justify-center px-6 py-2 rounded-full font-bold border-2 transition-all;
|
||||||
|
border-color: #ff2069;
|
||||||
|
background-color: #ff2069;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.get-started:hover {
|
||||||
|
@apply opacity-90;
|
||||||
|
color: white !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Target any div that uses the callout color variable */
|
||||||
|
div[style*="--callout-color"] {
|
||||||
|
@apply rounded-lg shadow-sm mb-4;
|
||||||
|
|
||||||
|
/* Force Docusaurus Layout: Left Border Only */
|
||||||
|
border: 1px solid rgba(0,0,0,0.05) !important;
|
||||||
|
border-left-width: 4px !important;
|
||||||
|
|
||||||
|
/* Hide the default Fumadocs vertical colored bar inside */
|
||||||
|
& > div[role="none"] {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* --- INFO (Blue) --- */
|
||||||
|
/* We match the variable name in the style string */
|
||||||
|
div[style*="--color-fd-info"] {
|
||||||
|
background-color: #eff6ff !important;
|
||||||
|
border-left-color: #3b82f6 !important;
|
||||||
|
color: #1e3a8a !important;
|
||||||
|
}
|
||||||
|
div[style*="--color-fd-info"] svg {
|
||||||
|
color: #3b82f6 !important;
|
||||||
|
fill: transparent !important; /* Remove fill to look cleaner */
|
||||||
|
}
|
||||||
|
/* Dark Mode Info */
|
||||||
|
:is(.dark div[style*="--color-fd-info"]) {
|
||||||
|
background-color: rgba(59, 130, 246, 0.1) !important;
|
||||||
|
color: #dbeafe !important;
|
||||||
|
border-top-color: rgba(255,255,255,0.05) !important;
|
||||||
|
border-right-color: rgba(255,255,255,0.05) !important;
|
||||||
|
border-bottom-color: rgba(255,255,255,0.05) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* --- WARNING (Amber) --- */
|
||||||
|
div[style*="--color-fd-warn"] {
|
||||||
|
background-color: #fffbeb !important;
|
||||||
|
border-left-color: #f59e0b !important;
|
||||||
|
color: #78350f !important;
|
||||||
|
}
|
||||||
|
div[style*="--color-fd-warn"] svg {
|
||||||
|
color: #f59e0b !important;
|
||||||
|
fill: transparent !important;
|
||||||
|
}
|
||||||
|
/* Dark Mode Warning */
|
||||||
|
:is(.dark div[style*="--color-fd-warn"]) {
|
||||||
|
background-color: rgba(245, 158, 11, 0.1) !important;
|
||||||
|
color: #fef3c7 !important;
|
||||||
|
border-top-color: rgba(255,255,255,0.05) !important;
|
||||||
|
border-right-color: rgba(255,255,255,0.05) !important;
|
||||||
|
border-bottom-color: rgba(255,255,255,0.05) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* --- ERROR (Red) --- */
|
||||||
|
div[style*="--color-fd-error"] {
|
||||||
|
background-color: #fef2f2 !important;
|
||||||
|
border-left-color: #ef4444 !important;
|
||||||
|
color: #7f1d1d !important;
|
||||||
|
}
|
||||||
|
div[style*="--color-fd-error"] svg {
|
||||||
|
color: #ef4444 !important;
|
||||||
|
fill: transparent !important;
|
||||||
|
}
|
||||||
|
/* Dark Mode Error */
|
||||||
|
:is(.dark div[style*="--color-fd-error"]) {
|
||||||
|
background-color: rgba(239, 68, 68, 0.12) !important;
|
||||||
|
color: #fee2e2 !important;
|
||||||
|
border-top-color: rgba(255,255,255,0.05) !important;
|
||||||
|
border-right-color: rgba(255,255,255,0.05) !important;
|
||||||
|
border-bottom-color: rgba(255,255,255,0.05) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* --- TITLE BOLD --- */
|
||||||
|
div[style*="--callout-color"] strong,
|
||||||
|
div[style*="--callout-color"] p:first-child strong {
|
||||||
|
font-weight: 700 !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@layer base {
|
||||||
|
/* HEADINGS */
|
||||||
|
h1, h2, h3, h4, h5, h6 {
|
||||||
|
font-family: var(--font-sans);
|
||||||
|
color: hsl(var(--foreground)) !important;
|
||||||
|
margin-bottom: 1rem;
|
||||||
|
letter-spacing: -0.025em;
|
||||||
|
-webkit-font-smoothing: antialiased;
|
||||||
|
-moz-osx-font-smoothing: grayscale;
|
||||||
|
}
|
||||||
|
|
||||||
|
h1 a, h2 a, h3 a, h4 a, h5 a, h6 a {
|
||||||
|
color: inherit !important;
|
||||||
|
text-decoration: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
h1 {
|
||||||
|
font-size: 3.5rem !important;
|
||||||
|
font-weight: 700 !important;
|
||||||
|
line-height: 1.1 !important;
|
||||||
|
margin-bottom: 1.5rem !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
h2 {
|
||||||
|
font-size: 2.25rem !important;
|
||||||
|
font-weight: 600 !important;
|
||||||
|
margin-top: 3rem !important;
|
||||||
|
margin-bottom: 1rem !important;
|
||||||
|
padding-bottom: 0.5rem !important;
|
||||||
|
border-bottom: 1px solid hsl(var(--border)) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
h3 {
|
||||||
|
font-size: 2rem !important;
|
||||||
|
font-weight: 600 !important;
|
||||||
|
margin-top: 2.5rem !important;
|
||||||
|
margin-bottom: 1rem !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
h4 {
|
||||||
|
font-size: 1.5rem !important;
|
||||||
|
font-weight: 600 !important;
|
||||||
|
margin-top: 2.5rem !important;
|
||||||
|
margin-bottom: 1rem !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
p {
|
||||||
|
font-size: 1rem;
|
||||||
|
line-height: 1.7;
|
||||||
|
margin-bottom: 1.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
html, body {
|
||||||
|
background-color: hsl(var(--background));
|
||||||
|
color: hsl(var(--foreground));
|
||||||
|
}
|
||||||
|
|
||||||
|
a {
|
||||||
|
color: hsl(var(--primary));
|
||||||
|
text-decoration: none;
|
||||||
|
transition: opacity 0.2s;
|
||||||
|
}
|
||||||
|
a:hover {
|
||||||
|
opacity: 0.8;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,29 @@
|
|||||||
|
import { type BaseLayoutProps } from 'fumadocs-ui/layouts/shared';
|
||||||
|
import { BookOpen, Code2, Server } from 'lucide-react';
|
||||||
|
|
||||||
|
export const baseOptions: BaseLayoutProps = {
|
||||||
|
nav: {
|
||||||
|
title: 'ZITADEL Docs',
|
||||||
|
},
|
||||||
|
links: [
|
||||||
|
{
|
||||||
|
text: 'Guides',
|
||||||
|
url: '/',
|
||||||
|
active: 'nested-url',
|
||||||
|
icon: <BookOpen />,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
text: 'APIs',
|
||||||
|
url: '/apis/introduction',
|
||||||
|
active: 'nested-url',
|
||||||
|
icon: <Code2 />,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
text: 'Legal',
|
||||||
|
url: '/legal/terms-of-service',
|
||||||
|
active: 'nested-url',
|
||||||
|
icon: <Server />, // Using Server icon as placeholder or pick another one
|
||||||
|
},
|
||||||
|
],
|
||||||
|
githubUrl: 'https://github.com/zitadel/zitadel',
|
||||||
|
};
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
import './global.css';
|
||||||
|
import type { Metadata } from 'next';
|
||||||
|
import { Providers } from './providers';
|
||||||
|
|
||||||
|
export const metadata: Metadata = {
|
||||||
|
metadataBase: new URL(process.env.NEXT_PUBLIC_SITE_URL || 'http://localhost:3000'),
|
||||||
|
icons: {
|
||||||
|
other: [
|
||||||
|
{
|
||||||
|
rel: 'stylesheet',
|
||||||
|
url: '/docs/img/icons/line-awesome/css/line-awesome.min.css',
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
};
|
||||||
|
|
||||||
|
export default function Layout({ children }: any) {
|
||||||
|
return (
|
||||||
|
<html lang="en" suppressHydrationWarning>
|
||||||
|
<body className="flex flex-col min-h-screen font-sans bg-fd-background text-fd-foreground">
|
||||||
|
<Providers>{children}</Providers>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
import { getLLMText, source } from '@/lib/source';
|
||||||
|
|
||||||
|
export const revalidate = false;
|
||||||
|
|
||||||
|
export async function GET() {
|
||||||
|
const scan = source.getPages().map(getLLMText);
|
||||||
|
const scanned = await Promise.all(scan);
|
||||||
|
|
||||||
|
return new Response(scanned.join('\n\n'));
|
||||||
|
}
|
||||||
@@ -0,0 +1,28 @@
|
|||||||
|
import { ImageResponse } from 'next/og';
|
||||||
|
import { notFound } from 'next/navigation';
|
||||||
|
import { source } from '@/lib/source';
|
||||||
|
import { generate as DefaultImage } from 'fumadocs-ui/og';
|
||||||
|
|
||||||
|
export const revalidate = false;
|
||||||
|
|
||||||
|
export async function GET(request: Request, context: any) {
|
||||||
|
const { slug } = context.params;
|
||||||
|
const page = source.getPage(slug.slice(0, -1));
|
||||||
|
if (!page) notFound();
|
||||||
|
|
||||||
|
return new ImageResponse(
|
||||||
|
<DefaultImage
|
||||||
|
title={page.data.title}
|
||||||
|
description={page.data.description}
|
||||||
|
site="My App"
|
||||||
|
/>,
|
||||||
|
{
|
||||||
|
width: 1200,
|
||||||
|
height: 630,
|
||||||
|
},
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
export function generateStaticParams() {
|
||||||
|
return [];
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
'use client';
|
||||||
|
|
||||||
|
import { RootProvider } from 'fumadocs-ui/provider/next';
|
||||||
|
import dynamic from "next/dynamic";
|
||||||
|
import { ThemeProvider } from 'next-themes';
|
||||||
|
|
||||||
|
import MixpanelProvider from '@/components/mixpanel-provider';
|
||||||
|
import PlausibleProvider from '@/components/plausible-provider';
|
||||||
|
|
||||||
|
const SearchDialog = dynamic(() => import("@/components/inkeep-search"));
|
||||||
|
|
||||||
|
export function Providers({ children }: { children: React.ReactNode }) {
|
||||||
|
return (
|
||||||
|
<RootProvider
|
||||||
|
search={{
|
||||||
|
enabled: true,
|
||||||
|
SearchDialog: SearchDialog as any,
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<PlausibleProvider />
|
||||||
|
<MixpanelProvider>
|
||||||
|
{children}
|
||||||
|
</MixpanelProvider>
|
||||||
|
</RootProvider>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
import { MetadataRoute } from 'next';
|
||||||
|
import { source } from '@/lib/source';
|
||||||
|
|
||||||
|
export default function sitemap(): MetadataRoute.Sitemap {
|
||||||
|
const baseUrl = 'https://zitadel.com/docs';
|
||||||
|
|
||||||
|
const docsPages = source.getPages().map((page) => ({
|
||||||
|
url: `${baseUrl}${page.url === '/' ? '' : page.url}`,
|
||||||
|
lastModified: new Date(),
|
||||||
|
changeFrequency: 'weekly' as const,
|
||||||
|
priority: 0.8,
|
||||||
|
}));
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
return [
|
||||||
|
{
|
||||||
|
url: baseUrl,
|
||||||
|
lastModified: new Date(),
|
||||||
|
changeFrequency: 'daily' as const,
|
||||||
|
priority: 1,
|
||||||
|
},
|
||||||
|
...docsPages,
|
||||||
|
].filter((item, index, self) =>
|
||||||
|
index === self.findIndex((t) => t.url === item.url)
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
version: v2
|
||||||
|
plugins:
|
||||||
|
- remote: buf.build/community/sudorandom-connect-openapi:v0.19.1
|
||||||
|
out: .
|
||||||
|
opt:
|
||||||
|
- format=json
|
||||||
@@ -0,0 +1,111 @@
|
|||||||
|
import React, { useMemo } from 'react';
|
||||||
|
import yaml from 'js-yaml';
|
||||||
|
import { Check, X } from 'lucide-react';
|
||||||
|
import { cn } from '@/utils/cn'; // Assuming utils/cn exists or I'll use clsx/tailwind-merge directly if not sure
|
||||||
|
|
||||||
|
// Fallback utility if generic cn doesn't exist, checking imports first is safer but I'll inline a simple merge if needed
|
||||||
|
// Checking package.json I saw clsx and tailwind-merge are dependencies.
|
||||||
|
|
||||||
|
function classNames(...classes) {
|
||||||
|
return classes.filter(Boolean).join(' ');
|
||||||
|
}
|
||||||
|
|
||||||
|
export default function PermissionTable({ data }) {
|
||||||
|
const { roles, permissions, matrix } = useMemo(() => {
|
||||||
|
if (!data) return { roles: [], permissions: [], matrix: {} };
|
||||||
|
|
||||||
|
let parsedData = data;
|
||||||
|
if (typeof data === 'string') {
|
||||||
|
try {
|
||||||
|
parsedData = yaml.load(data);
|
||||||
|
} catch (e) {
|
||||||
|
console.error('Failed to parse YAML data:', e);
|
||||||
|
return { roles: [], permissions: [], matrix: {} };
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 1. Identify all sources.
|
||||||
|
const sources = [
|
||||||
|
parsedData?.InternalAuthZ?.RolePermissionMappings,
|
||||||
|
parsedData?.SystemAuthZ?.RolePermissionMappings,
|
||||||
|
].filter(Boolean).flat();
|
||||||
|
|
||||||
|
// 2. Aggregate Data
|
||||||
|
const roleMap = new Map();
|
||||||
|
const allPermissions = new Set();
|
||||||
|
|
||||||
|
sources.forEach((mapping) => {
|
||||||
|
const roleName = mapping.Role;
|
||||||
|
const rolePerms = mapping.Permissions || [];
|
||||||
|
|
||||||
|
if (!roleMap.has(roleName)) {
|
||||||
|
roleMap.set(roleName, new Set());
|
||||||
|
}
|
||||||
|
|
||||||
|
rolePerms.forEach((perm) => {
|
||||||
|
roleMap.get(roleName).add(perm);
|
||||||
|
allPermissions.add(perm);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
// 3. Sort for display
|
||||||
|
const sortedRoles = Array.from(roleMap.keys()).sort();
|
||||||
|
const sortedPermissions = Array.from(allPermissions).sort();
|
||||||
|
|
||||||
|
return {
|
||||||
|
roles: sortedRoles,
|
||||||
|
permissions: sortedPermissions,
|
||||||
|
matrix: roleMap,
|
||||||
|
};
|
||||||
|
}, [data]);
|
||||||
|
|
||||||
|
if (!roles.length) {
|
||||||
|
return <div className="p-4 text-sm text-fd-muted-foreground bg-fd-muted rounded-md border border-fd-border">No permission data available.</div>;
|
||||||
|
}
|
||||||
|
|
||||||
|
return (
|
||||||
|
<div className="overflow-x-auto my-6 rounded-lg border border-fd-border bg-fd-card shadow-sm">
|
||||||
|
<table className="w-full text-sm text-left">
|
||||||
|
<thead className="text-xs font-semibold text-fd-muted-foreground uppercase bg-fd-muted/50 border-b border-fd-border">
|
||||||
|
<tr>
|
||||||
|
<th scope="col" className="px-4 py-3 sticky left-0 z-10 bg-fd-muted/95 backdrop-blur shadow-[1px_0_0_0_rgba(0,0,0,0.1)] dark:shadow-[1px_0_0_0_rgba(255,255,255,0.1)]">
|
||||||
|
Permission
|
||||||
|
</th>
|
||||||
|
{roles.map((role) => (
|
||||||
|
<th key={role} scope="col" className="px-4 py-3 whitespace-nowrap text-center min-w-[100px]">
|
||||||
|
{role.replace(/_/g, ' ')}
|
||||||
|
</th>
|
||||||
|
))}
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody className="divide-y divide-fd-border">
|
||||||
|
{permissions.map((perm) => (
|
||||||
|
<tr key={perm} className="hover:bg-fd-accent/50 transition-colors">
|
||||||
|
<th scope="row" className="px-4 py-2 font-medium text-fd-foreground whitespace-nowrap sticky left-0 z-10 bg-fd-card shadow-[1px_0_0_0_rgba(0,0,0,0.1)] dark:shadow-[1px_0_0_0_rgba(255,255,255,0.1)]">
|
||||||
|
{perm}
|
||||||
|
</th>
|
||||||
|
{roles.map((role) => {
|
||||||
|
const hasPermission = matrix.get(role).has(perm);
|
||||||
|
return (
|
||||||
|
<td
|
||||||
|
key={`${role}-${perm}`}
|
||||||
|
className={classNames(
|
||||||
|
"px-4 py-2 text-center",
|
||||||
|
hasPermission ? "bg-green-50/50 dark:bg-green-900/10" : ""
|
||||||
|
)}
|
||||||
|
>
|
||||||
|
{hasPermission ? (
|
||||||
|
<Check className="w-4 h-4 text-green-600 dark:text-green-400 mx-auto" strokeWidth={3} />
|
||||||
|
) : (
|
||||||
|
<span className="sr-only">No</span>
|
||||||
|
)}
|
||||||
|
</td>
|
||||||
|
);
|
||||||
|
})}
|
||||||
|
</tr>
|
||||||
|
))}
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
'use client';
|
||||||
|
import { defineClientConfig } from 'fumadocs-openapi/ui/client';
|
||||||
|
|
||||||
|
export default defineClientConfig();
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
import { createOpenAPI } from 'fumadocs-openapi/server';
|
||||||
|
import { createAPIPage } from 'fumadocs-openapi/ui';
|
||||||
|
import path from 'path';
|
||||||
|
import client from './api-page.client';
|
||||||
|
|
||||||
|
export function APIPage({ document, operations }: { document: string; operations: any[] }) {
|
||||||
|
|
||||||
|
|
||||||
|
if (!path.isAbsolute(document) && !document.startsWith('openapi/')) {
|
||||||
|
throw new Error(`APIPage document path MUST start with 'openapi/'. Received: ${document}`);
|
||||||
|
}
|
||||||
|
|
||||||
|
const absoluteDocument = path.isAbsolute(document)
|
||||||
|
? document
|
||||||
|
: path.join(process.cwd(), 'openapi', document.slice('openapi/'.length));
|
||||||
|
|
||||||
|
const openapi = createOpenAPI({
|
||||||
|
input: [absoluteDocument],
|
||||||
|
});
|
||||||
|
|
||||||
|
const InnerAPIPage = createAPIPage(openapi, {
|
||||||
|
client,
|
||||||
|
});
|
||||||
|
|
||||||
|
return <InnerAPIPage document={absoluteDocument} operations={operations} />;
|
||||||
|
}
|
||||||
|
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
import React from "react";
|
import React from "react";
|
||||||
|
|
||||||
import styles from "../css/apicard.module.css";
|
import styles from "@/css/apicard.module.css";
|
||||||
|
|
||||||
export function ApiCard({ type, children }) {
|
export function ApiCard({ type, children }) {
|
||||||
let classes = "";
|
let classes = "";
|
||||||
@@ -1,3 +1,4 @@
|
|||||||
|
"use client";
|
||||||
import React from "react";
|
import React from "react";
|
||||||
import Chart from "react-google-charts";
|
import Chart from "react-google-charts";
|
||||||
|
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
import { Callout } from 'fumadocs-ui/components/callout';
|
||||||
|
|
||||||
|
export default function Admonition({ type, title, children, icon }: any) {
|
||||||
|
let calloutType: 'info' | 'warn' | 'error' = 'info';
|
||||||
|
switch (type) {
|
||||||
|
case 'note': calloutType = 'info'; break;
|
||||||
|
case 'tip': calloutType = 'info'; break;
|
||||||
|
case 'info': calloutType = 'info'; break;
|
||||||
|
case 'warning': calloutType = 'warn'; break;
|
||||||
|
case 'danger': calloutType = 'error'; break;
|
||||||
|
case 'caution': calloutType = 'warn'; break;
|
||||||
|
}
|
||||||
|
|
||||||
|
return (
|
||||||
|
<Callout title={title} type={calloutType} icon={icon}>
|
||||||
|
{children}
|
||||||
|
</Callout>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
"use client";
|
||||||
|
import { useEffect, useState } from 'react';
|
||||||
|
|
||||||
|
export default function BrowserOnly({ children, fallback }: any) {
|
||||||
|
const [mounted, setMounted] = useState(false);
|
||||||
|
|
||||||
|
useEffect(() => setMounted(true), []);
|
||||||
|
|
||||||
|
if (!mounted) return fallback || null;
|
||||||
|
|
||||||
|
return children();
|
||||||
|
}
|
||||||
@@ -0,0 +1,14 @@
|
|||||||
|
import React from 'react';
|
||||||
|
|
||||||
|
export default function CodeBlock({ children, language, title, className, showLineNumbers: _showLineNumbers }: any) {
|
||||||
|
return (
|
||||||
|
<div className="my-4">
|
||||||
|
{title && <div className="bg-secondary text-secondary-foreground px-4 py-2 text-sm font-medium rounded-t-md">{title}</div>}
|
||||||
|
<pre className={`p-4 overflow-x-auto bg-secondary/50 rounded-b-md ${title ? 'rounded-t-none' : 'rounded-md'} ${className || ''}`}>
|
||||||
|
<code className={language ? `language-${language}` : ''}>
|
||||||
|
{children}
|
||||||
|
</code>
|
||||||
|
</pre>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -0,0 +1,30 @@
|
|||||||
|
import React from 'react';
|
||||||
|
import { Cards, Card } from 'fumadocs-ui/components/card';
|
||||||
|
|
||||||
|
export default function DocCardList({ items }: { items?: any[] }) {
|
||||||
|
// If items are provided (manual list), render them
|
||||||
|
if (items) {
|
||||||
|
return (
|
||||||
|
<Cards>
|
||||||
|
{items.map((item, index) => (
|
||||||
|
<Card key={index} href={item.href} title={item.label} />
|
||||||
|
))}
|
||||||
|
</Cards>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
// If no items, it's likely an auto-generated list for the current sidebar category.
|
||||||
|
// Fumadocs doesn't have a direct equivalent to "current sidebar category items" in a component easily accessible here without context.
|
||||||
|
// For now, we'll render a placeholder or nothing to avoid build errors.
|
||||||
|
// In a real migration, we'd use `useTreeContext` or similar if available, or rely on Fumadocs' index page generation.
|
||||||
|
return (
|
||||||
|
<div className="admonition admonition-info alert alert--info">
|
||||||
|
<div className="admonition-heading">
|
||||||
|
<h5>DocCardList Placeholder</h5>
|
||||||
|
</div>
|
||||||
|
<div className="admonition-content">
|
||||||
|
<p>Auto-generated card lists are not yet fully supported in the migration.</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -0,0 +1,58 @@
|
|||||||
|
import { Tabs as FumadocsTabs, Tab as FumadocsTab } from 'fumadocs-ui/components/tabs';
|
||||||
|
import React, { isValidElement } from 'react';
|
||||||
|
|
||||||
|
export function TabItem({ value, label: _label, children, default: _isDefault, className, attributes }: any) {
|
||||||
|
return <FumadocsTab value={value} className={className} {...attributes}>{children}</FumadocsTab>;
|
||||||
|
}
|
||||||
|
|
||||||
|
export default function Tabs({ children, defaultValue, values, groupId, className }: any) {
|
||||||
|
let items: string[] = [];
|
||||||
|
|
||||||
|
const childrenArray = React.Children.toArray(children);
|
||||||
|
|
||||||
|
if (values) {
|
||||||
|
items = values.map((v: any) => v.label);
|
||||||
|
} else {
|
||||||
|
childrenArray.forEach((child) => {
|
||||||
|
if (isValidElement(child)) {
|
||||||
|
const props = child.props as any;
|
||||||
|
const label = props.label || props.value;
|
||||||
|
items.push(label);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
const newChildren = childrenArray.map((child, index) => {
|
||||||
|
if (isValidElement(child)) {
|
||||||
|
const props = child.props as any;
|
||||||
|
let label = props.label;
|
||||||
|
if (!label && values) {
|
||||||
|
const valObj = values.find((v: any) => v.value === props.value);
|
||||||
|
if (valObj) label = valObj.label;
|
||||||
|
}
|
||||||
|
if (!label) label = props.value;
|
||||||
|
|
||||||
|
return <FumadocsTab key={index} value={label} {...props}>{props.children}</FumadocsTab>;
|
||||||
|
}
|
||||||
|
return child;
|
||||||
|
});
|
||||||
|
|
||||||
|
let newDefaultValue = defaultValue;
|
||||||
|
if (defaultValue && values) {
|
||||||
|
const valObj = values.find((v: any) => v.value === defaultValue);
|
||||||
|
if (valObj) newDefaultValue = valObj.label;
|
||||||
|
} else if (defaultValue) {
|
||||||
|
const child = childrenArray.find((c: any) => (c as any).props.value === defaultValue);
|
||||||
|
if (child) {
|
||||||
|
newDefaultValue = (child as any).props.label || (child as any).props.value;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return (
|
||||||
|
<FumadocsTabs items={items} defaultValue={newDefaultValue} groupId={groupId} className={className}>
|
||||||
|
{newChildren}
|
||||||
|
</FumadocsTabs>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
"use client";
|
||||||
|
import Image from 'next/image';
|
||||||
|
import { useTheme } from 'next-themes';
|
||||||
|
import { useEffect, useState } from 'react';
|
||||||
|
|
||||||
|
export default function ThemedImage({ sources, alt, ...props }: any) {
|
||||||
|
const { resolvedTheme } = useTheme();
|
||||||
|
const [mounted, setMounted] = useState(false);
|
||||||
|
|
||||||
|
useEffect(() => setMounted(true), []);
|
||||||
|
|
||||||
|
if (!mounted) return <Image src={sources.light} alt={alt} {...props} />;
|
||||||
|
|
||||||
|
const src = resolvedTheme === 'dark' ? sources.dark : sources.light;
|
||||||
|
|
||||||
|
return <Image src={src} alt={alt} {...props} />;
|
||||||
|
}
|
||||||
@@ -0,0 +1,56 @@
|
|||||||
|
'use client';
|
||||||
|
|
||||||
|
import { useState } from 'react';
|
||||||
|
import { mixpanelClient } from '@/utils/mixpanel';
|
||||||
|
import { usePathname } from 'next/navigation';
|
||||||
|
import { ThumbsUp, ThumbsDown } from 'lucide-react';
|
||||||
|
import { cn } from '@/utils/cn';
|
||||||
|
|
||||||
|
export function Feedback() {
|
||||||
|
const pathname = usePathname();
|
||||||
|
const [voted, setVoted] = useState<boolean | null>(null);
|
||||||
|
|
||||||
|
const handleVote = (useful: boolean) => {
|
||||||
|
setVoted(useful);
|
||||||
|
mixpanelClient.track('helpfulness_vote', {
|
||||||
|
path: pathname,
|
||||||
|
useful: useful,
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
if (voted !== null) {
|
||||||
|
return (
|
||||||
|
<div className="flex flex-col gap-2 border-t pt-8 mt-8">
|
||||||
|
<p className="text-sm text-fd-muted-foreground">
|
||||||
|
Thanks for your feedback!
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
return (
|
||||||
|
<div className="flex flex-col gap-2 border-t pt-8 mt-8">
|
||||||
|
<p className="text-sm text-fd-muted-foreground">Was this page helpful?</p>
|
||||||
|
<div className="flex gap-2">
|
||||||
|
<button
|
||||||
|
onClick={() => handleVote(true)}
|
||||||
|
className={cn(
|
||||||
|
"p-2 rounded-md transition-colors border hover:bg-fd-accent hover:text-fd-accent-foreground border-fd-border text-fd-muted-foreground"
|
||||||
|
)}
|
||||||
|
aria-label="Helpful"
|
||||||
|
>
|
||||||
|
<ThumbsUp className="size-4" />
|
||||||
|
</button>
|
||||||
|
<button
|
||||||
|
onClick={() => handleVote(false)}
|
||||||
|
className={cn(
|
||||||
|
"p-2 rounded-md transition-colors border hover:bg-fd-accent hover:text-fd-accent-foreground border-fd-border text-fd-muted-foreground"
|
||||||
|
)}
|
||||||
|
aria-label="Not helpful"
|
||||||
|
>
|
||||||
|
<ThumbsDown className="size-4" />
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
import React from "react";
|
import React from "react";
|
||||||
import { Tile } from "./tile";
|
import { Tile } from "./tile";
|
||||||
import frameworks from "../../frameworks.json";
|
import frameworks from "../frameworks.json";
|
||||||
|
|
||||||
export function Frameworks({ filter }) {
|
export function Frameworks({ filter }) {
|
||||||
const filteredFrameworks = frameworks.filter((framework) => {
|
const filteredFrameworks = frameworks.filter((framework) => {
|
||||||
@@ -0,0 +1,71 @@
|
|||||||
|
"use client";
|
||||||
|
|
||||||
|
import type { SharedProps } from "fumadocs-ui/components/dialog/search";
|
||||||
|
import {
|
||||||
|
InkeepModalSearchAndChat,
|
||||||
|
type InkeepModalSearchAndChatProps,
|
||||||
|
} from "@inkeep/cxkit-react";
|
||||||
|
import { useEffect, useState } from "react";
|
||||||
|
|
||||||
|
export default function CustomDialog(props: SharedProps) {
|
||||||
|
const [syncTarget, setSyncTarget] = useState<HTMLElement | null>(null);
|
||||||
|
const { open, onOpenChange } = props;
|
||||||
|
// We do this because document is not available in the server
|
||||||
|
useEffect(() => {
|
||||||
|
setSyncTarget(document.documentElement);
|
||||||
|
}, []);
|
||||||
|
|
||||||
|
const config: InkeepModalSearchAndChatProps = {
|
||||||
|
baseSettings: {
|
||||||
|
apiKey: process.env.NEXT_PUBLIC_INKEEP_API_KEY,
|
||||||
|
primaryBrandColor: '#425b76',
|
||||||
|
organizationDisplayName: "Zitadel",
|
||||||
|
colorMode: {
|
||||||
|
sync: {
|
||||||
|
target: syncTarget,
|
||||||
|
attributes: ["class"],
|
||||||
|
isDarkMode: (attributes) => !!attributes.class?.includes("dark"),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
modalSettings: {
|
||||||
|
isOpen: open,
|
||||||
|
onOpenChange,
|
||||||
|
// optional settings
|
||||||
|
},
|
||||||
|
searchSettings: {
|
||||||
|
// optional settings
|
||||||
|
},
|
||||||
|
aiChatSettings: {
|
||||||
|
aiAssistantName: 'Zitadel AI Assistant',
|
||||||
|
chatSubjectName: 'Zitadel',
|
||||||
|
placeholder: 'How can I enable MFA?',
|
||||||
|
introMessage: 'Hey! I’m the Zitadel AI assistant 🤖 — throw your questions my way!',
|
||||||
|
aiAssistantAvatar: '/icons/favicon-32x32.png',
|
||||||
|
userAvatar: '/icons/user.png',
|
||||||
|
exampleQuestionsLabel: 'Example Questions:',
|
||||||
|
exampleQuestions: [
|
||||||
|
'What is an Instance?',
|
||||||
|
'What is an Organization?',
|
||||||
|
'How to create an Action?',
|
||||||
|
'How to integrate Zitadel to my React app?',
|
||||||
|
],
|
||||||
|
isFirstExampleQuestionHighlighted: true,
|
||||||
|
shouldOpenLinksInNewTab: true,
|
||||||
|
isCopyChatButtonVisible: true,
|
||||||
|
disclaimerSettings: {
|
||||||
|
isEnabled: true,
|
||||||
|
label: 'AI Assistant',
|
||||||
|
tooltip: 'Responses are AI-generated and may require verification.',
|
||||||
|
},
|
||||||
|
toolbarButtonLabels: {
|
||||||
|
clear: 'Start Over',
|
||||||
|
share: 'Share Chat',
|
||||||
|
getHelp: 'Get Help',
|
||||||
|
stop: 'Stop',
|
||||||
|
copyChat: 'Copy Chat',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
};
|
||||||
|
return <InkeepModalSearchAndChat {...config} />;
|
||||||
|
}
|
||||||
@@ -0,0 +1,51 @@
|
|||||||
|
'use client';
|
||||||
|
|
||||||
|
import { initMixpanel, mixpanelClient, optInTracking, optOutTracking } from '@/utils/mixpanel';
|
||||||
|
import React, { useEffect } from 'react';
|
||||||
|
|
||||||
|
export default function MixpanelProvider({ children }: { children: React.ReactNode }) {
|
||||||
|
useEffect(() => {
|
||||||
|
const setup = async () => {
|
||||||
|
await initMixpanel();
|
||||||
|
|
||||||
|
const CookieConsent = await import('vanilla-cookieconsent');
|
||||||
|
const cookie = CookieConsent.getCookie();
|
||||||
|
|
||||||
|
// @ts-ignore
|
||||||
|
if (!cookie || !cookie.services || !cookie.services.analytics) {
|
||||||
|
// We only send data when people opt-in, not just if they have not opted out.
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// @ts-ignore
|
||||||
|
const hasMixpanelConsent = cookie?.services?.analytics?.indexOf('mixpanel') !== -1;
|
||||||
|
if (hasMixpanelConsent) {
|
||||||
|
optInTracking();
|
||||||
|
} else {
|
||||||
|
optOutTracking();
|
||||||
|
}
|
||||||
|
};
|
||||||
|
setup().catch((error) => {
|
||||||
|
console.error('Error setting up Mixpanel:', error);
|
||||||
|
});
|
||||||
|
|
||||||
|
const handleConsentChange = async () => {
|
||||||
|
const CookieConsent = await import('vanilla-cookieconsent');
|
||||||
|
const cookie = CookieConsent.getCookie();
|
||||||
|
// @ts-ignore
|
||||||
|
const hasMixpanelConsent = cookie?.services?.analytics?.indexOf('mixpanel') !== -1;
|
||||||
|
if (hasMixpanelConsent) {
|
||||||
|
optInTracking();
|
||||||
|
} else {
|
||||||
|
optOutTracking();
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
window.addEventListener('cc:onChange:mixpanel', handleConsentChange);
|
||||||
|
|
||||||
|
return () => {
|
||||||
|
window.removeEventListener('cc:onChange:mixpanel', handleConsentChange);
|
||||||
|
};
|
||||||
|
}, []);
|
||||||
|
|
||||||
|
return <>{children}</>;
|
||||||
|
}
|
||||||
@@ -81,26 +81,34 @@ export function PiiTable() {
|
|||||||
],
|
],
|
||||||
subjects: "All users"
|
subjects: "All users"
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<table className="text-xs">
|
<table className="text-xs">
|
||||||
<tr>
|
<thead>
|
||||||
<th>Type of personal data</th>
|
<tr>
|
||||||
<th>Examples</th>
|
<th>Type of personal data</th>
|
||||||
<th>Affected data subjects</th>
|
<th>Examples</th>
|
||||||
</tr>
|
<th>Affected data subjects</th>
|
||||||
{
|
</tr>
|
||||||
pii.map((row, rowID) => {
|
</thead>
|
||||||
return (
|
<tbody>
|
||||||
<tr>
|
{
|
||||||
<td key={rowID}>{row.type}</td>
|
pii.map((row) => (
|
||||||
<td><ul>{row.examples.map((example) => { return ( <li>{example}</li> )})}</ul></td>
|
<tr key={row.type}>
|
||||||
|
<td>{row.type}</td>
|
||||||
|
<td>
|
||||||
|
<ul>
|
||||||
|
{row.examples.map((example) => (
|
||||||
|
<li key={example}>{example}</li>
|
||||||
|
))}
|
||||||
|
</ul>
|
||||||
|
</td>
|
||||||
<td>{row.subjects}</td>
|
<td>{row.subjects}</td>
|
||||||
</tr>
|
</tr>
|
||||||
)
|
))
|
||||||
})
|
}
|
||||||
}
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
'use client';
|
||||||
|
|
||||||
|
import Script from 'next/script';
|
||||||
|
|
||||||
|
export default function PlausibleProvider() {
|
||||||
|
const domain = process.env.NEXT_PUBLIC_PLAUSIBLE_DOMAIN || 'zitadel.com';
|
||||||
|
|
||||||
|
return (
|
||||||
|
<Script
|
||||||
|
defer
|
||||||
|
data-domain={domain}
|
||||||
|
data-api="/docs/pl/api/event"
|
||||||
|
src="/docs/pl/js/script.js"
|
||||||
|
strategy="afterInteractive"
|
||||||
|
/>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
"use client";
|
||||||
|
import React from "react";
|
||||||
|
|
||||||
|
export function ResponsivePlayer({ url }) {
|
||||||
|
const getYouTubeId = (url) => {
|
||||||
|
if (!url) return null;
|
||||||
|
const regExp = /^.*(youtu.be\/|v\/|u\/\w\/|embed\/|watch\?v=|&v=)([^#&?]*).*/;
|
||||||
|
const match = url.match(regExp);
|
||||||
|
return (match && match[2].length === 11) ? match[2] : null;
|
||||||
|
};
|
||||||
|
|
||||||
|
const videoId = getYouTubeId(url);
|
||||||
|
|
||||||
|
if (videoId) {
|
||||||
|
return (
|
||||||
|
/* 1. Removed 'player-wrapper' class to avoid global.css conflict (double height).
|
||||||
|
2. Reduced max-width to 'max-w-2xl' so it fits better in the text flow.
|
||||||
|
*/
|
||||||
|
<div className="relative w-full max-w-2xl mx-auto h-0 pb-[56.25%] mb-8 rounded-lg overflow-hidden border border-zinc-200 dark:border-zinc-800 bg-black shadow-md">
|
||||||
|
<iframe
|
||||||
|
src={`https://www.youtube.com/embed/${videoId}`}
|
||||||
|
title="YouTube video player"
|
||||||
|
className="absolute top-0 left-0 w-full h-full"
|
||||||
|
frameBorder="0"
|
||||||
|
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
|
||||||
|
allowFullScreen
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
return (
|
||||||
|
<div className="p-4 mb-8 border border-red-200 bg-red-50 text-red-600 rounded-lg text-sm">
|
||||||
|
Video source not supported: {url}
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
import React from "react";
|
import React from "react";
|
||||||
import styles from "../css/tile.module.css";
|
import styles from '@/css/tile.module.css';
|
||||||
|
|
||||||
export function Tile({ title, imageSource, imageSourceLight, link, external }) {
|
export function Tile({ title, imageSource, imageSourceLight, link, external }) {
|
||||||
return (
|
return (
|
||||||
@@ -0,0 +1,93 @@
|
|||||||
|
'use client';
|
||||||
|
|
||||||
|
import * as React from 'react';
|
||||||
|
import { usePathname, useRouter } from 'next/navigation';
|
||||||
|
interface DocVersion {
|
||||||
|
param: string;
|
||||||
|
label: string;
|
||||||
|
url: string;
|
||||||
|
ref: string;
|
||||||
|
refType: string;
|
||||||
|
type?: 'external';
|
||||||
|
}
|
||||||
|
|
||||||
|
import rawVersions from '../content/versions.json';
|
||||||
|
const versions = rawVersions as DocVersion[];
|
||||||
|
|
||||||
|
export function VersionSelector() {
|
||||||
|
const pathname = usePathname();
|
||||||
|
const router = useRouter();
|
||||||
|
|
||||||
|
// Handle basePath issues: usePathname() typically returns path relative to basePath if configured?
|
||||||
|
// But purely relying on that is tricky. Let's normalize.
|
||||||
|
// If pathname starts with /docs, assume it's the full path and we strip it for logic,
|
||||||
|
// then let router handle re-adding it if needed (or we check behaviors).
|
||||||
|
// Actually, Next.js router.push() expects path relative to basePath usually?
|
||||||
|
// Let's implement robust segment swapping.
|
||||||
|
|
||||||
|
const normalizePath = (p: string) => {
|
||||||
|
if (p.startsWith('/docs')) return p.slice(5) || '/';
|
||||||
|
return p;
|
||||||
|
};
|
||||||
|
|
||||||
|
const normalizedPath = normalizePath(pathname);
|
||||||
|
|
||||||
|
const currentVersionObj = versions.find((v) => {
|
||||||
|
if (!v.param || v.param === 'latest') return false;
|
||||||
|
return normalizedPath.startsWith(`/${v.param}`);
|
||||||
|
});
|
||||||
|
|
||||||
|
const currentVersion = currentVersionObj ? currentVersionObj.param : 'latest';
|
||||||
|
|
||||||
|
const handleChange = (e: React.ChangeEvent<HTMLSelectElement>) => {
|
||||||
|
const value = e.target.value;
|
||||||
|
const version = versions.find((v) => (v.param || v.label) === value);
|
||||||
|
|
||||||
|
if (!version) return;
|
||||||
|
|
||||||
|
if (!version.param) return;
|
||||||
|
|
||||||
|
// Calculate the 'tail' of the path (content path)
|
||||||
|
let tail = normalizedPath;
|
||||||
|
if (currentVersion !== 'latest') {
|
||||||
|
// Strip current version prefix
|
||||||
|
// e.g. /v4.10/foo -> /foo
|
||||||
|
tail = normalizedPath.replace(new RegExp(`^/${currentVersion}`), '') || '/';
|
||||||
|
}
|
||||||
|
|
||||||
|
// Construct new path
|
||||||
|
let newPath = tail;
|
||||||
|
if (version.param !== 'latest') {
|
||||||
|
// Add new version prefix
|
||||||
|
// e.g. /foo -> /v4.9/foo
|
||||||
|
// Handle root slash
|
||||||
|
if (tail === '/') {
|
||||||
|
newPath = `/${version.param}`;
|
||||||
|
} else {
|
||||||
|
newPath = `/${version.param}${tail}`;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Next.js router handles basePath automatically if configured correctly.
|
||||||
|
// If we push '/v4.10', it becomes '/docs/v4.10'.
|
||||||
|
router.push(newPath);
|
||||||
|
};
|
||||||
|
|
||||||
|
return (
|
||||||
|
<select
|
||||||
|
value={currentVersion}
|
||||||
|
onChange={handleChange}
|
||||||
|
className="p-2 bg-transparent text-sm font-medium rounded-md border border-fd-border hover:bg-fd-accent/50 focus:outline-none focus:ring-2 focus:ring-fd-ring text-fd-foreground w-full mb-4"
|
||||||
|
>
|
||||||
|
{versions.map((v) => (
|
||||||
|
<option
|
||||||
|
key={v.param || v.label}
|
||||||
|
value={v.param || v.label}
|
||||||
|
className="bg-fd-background text-fd-foreground"
|
||||||
|
>
|
||||||
|
{v.label}
|
||||||
|
</option>
|
||||||
|
))}
|
||||||
|
</select>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -0,0 +1,203 @@
|
|||||||
|
{
|
||||||
|
"root": true,
|
||||||
|
"pages": [
|
||||||
|
"introduction",
|
||||||
|
{
|
||||||
|
"title": "Core Resources",
|
||||||
|
"pages": [
|
||||||
|
{
|
||||||
|
"title": "V2",
|
||||||
|
"pages": [
|
||||||
|
{
|
||||||
|
"title": "User",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/user"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Session",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/session"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "OIDC",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/oidc"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "SAML",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/saml"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Settings",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/settings"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Feature",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/feature"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Organization",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/org"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Identity Provider",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/idp"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Web Key",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/webkey"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Action",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/action"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Instance",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/instance"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Project",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/project"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Application",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/application"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Authorizations",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/authorization"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Internal Permissions",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api/internal_permission"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "V1",
|
||||||
|
"pages": [
|
||||||
|
{
|
||||||
|
"title": "Authenticated User",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api-v1/auth"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Organization Objects",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api-v1/management"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Instance Objects",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api-v1/admin"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Instance Lifecycle",
|
||||||
|
"pages": [
|
||||||
|
"../reference/api-v1/system"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"migration_v1_to_v2"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Assets",
|
||||||
|
"pages": [
|
||||||
|
"assets/assets"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Observability",
|
||||||
|
"pages": [
|
||||||
|
"observability/metrics",
|
||||||
|
"observability/health"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Provision Users",
|
||||||
|
"pages": [
|
||||||
|
"scim2"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "gRPC Status Codes",
|
||||||
|
"url": "statuscodes"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Rate Limits (Cloud)",
|
||||||
|
"url": "/legal/policies/rate-limit-policy"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "Benchmarks",
|
||||||
|
"pages": [
|
||||||
|
{
|
||||||
|
"title": "v2.65.0",
|
||||||
|
"pages": [
|
||||||
|
"benchmarks/v2.65.0/machine_jwt_profile_grant/index"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "v2.66.0",
|
||||||
|
"pages": [
|
||||||
|
"benchmarks/v2.66.0/machine_jwt_profile_grant/index"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "v2.70.0",
|
||||||
|
"pages": [
|
||||||
|
"benchmarks/v2.70.0/machine_jwt_profile_grant/index",
|
||||||
|
"benchmarks/v2.70.0/oidc_session/index"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "v4",
|
||||||
|
"pages": [
|
||||||
|
"benchmarks/v4/add_session/index",
|
||||||
|
"benchmarks/v4/human_password_login/index",
|
||||||
|
"benchmarks/v4/introspect/index",
|
||||||
|
"benchmarks/v4/machine_client_credentials_login/index",
|
||||||
|
"benchmarks/v4/machine_jwt_profile_grant/index",
|
||||||
|
"benchmarks/v4/machine_pat_login/index",
|
||||||
|
"benchmarks/v4/manipulate_user/index",
|
||||||
|
"benchmarks/v4/oidc_session/index",
|
||||||
|
"benchmarks/v4/otp_session/index",
|
||||||
|
"benchmarks/v4/password_session/index",
|
||||||
|
"benchmarks/v4/user_info/index"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
+21
-21
@@ -13,7 +13,7 @@ Append claims returned on OIDC requests.
|
|||||||
### Triggers
|
### Triggers
|
||||||
|
|
||||||
- Complement token
|
- Complement token
|
||||||
- [Pre Userinfo creation](./complement-token#pre-userinfo-creation-id_token--userinfo--introspection-endpoint)
|
- [Pre Userinfo creation](./complement-token#pre-userinfo-creation-id-token-userinfo-introspection-endpoint)
|
||||||
- [Pre access token creation](./complement-token#pre-access-token-creation)
|
- [Pre access token creation](./complement-token#pre-access-token-creation)
|
||||||
|
|
||||||
### Set hardcoded claim
|
### Set hardcoded claim
|
||||||
@@ -88,7 +88,7 @@ Append attributes returned on SAML requests.
|
|||||||
### Triggers
|
### Triggers
|
||||||
|
|
||||||
- Complement SAMLResponse
|
- Complement SAMLResponse
|
||||||
- [Pre SAMLResponse creation](./customize-samlresponse#pre-samlresponse-creation)
|
- [Pre SAMLResponse creation](./customize-samlresponse#pre-saml-response-creation)
|
||||||
|
|
||||||
### Custom role mapping in attributes
|
### Custom role mapping in attributes
|
||||||
|
|
||||||
@@ -127,9 +127,9 @@ Useful if you trust the provided information or don't want the users to verify t
|
|||||||
#### Triggers
|
#### Triggers
|
||||||
|
|
||||||
- Internal Authentication
|
- Internal Authentication
|
||||||
- [Pre Creation](/docs/apis/actions/internal-authentication#pre-creation)
|
- [Pre Creation](/apis/actions/internal-authentication#pre-creation)
|
||||||
- External Authentication
|
- External Authentication
|
||||||
- [Pre Creation](/docs/apis/actions/external-authentication#pre-creation)
|
- [Pre Creation](/apis/actions/external-authentication#pre-creation)
|
||||||
|
|
||||||
<details open="">
|
<details open="">
|
||||||
<summary>Code example</summary>
|
<summary>Code example</summary>
|
||||||
@@ -147,9 +147,9 @@ Allows you to add default user grants to a user after it was created or federate
|
|||||||
#### Triggers
|
#### Triggers
|
||||||
|
|
||||||
- Internal Authentication
|
- Internal Authentication
|
||||||
- [Post Creation](/docs/apis/actions/internal-authentication#post-creation)
|
- [Post Creation](/apis/actions/internal-authentication#post-creation)
|
||||||
- External Authentication
|
- External Authentication
|
||||||
- [Post Creation](/docs/apis/actions/external-authentication#post-creation)
|
- [Post Creation](/apis/actions/external-authentication#post-creation)
|
||||||
|
|
||||||
<details open="">
|
<details open="">
|
||||||
<summary>Code example</summary>
|
<summary>Code example</summary>
|
||||||
@@ -167,11 +167,11 @@ Adding metadata to users allows you to set default metadata on users.
|
|||||||
#### Triggers
|
#### Triggers
|
||||||
|
|
||||||
- Internal Authentication
|
- Internal Authentication
|
||||||
- [Pre Creation](/docs/apis/actions/internal-authentication#pre-creation)
|
- [Pre Creation](/apis/actions/internal-authentication#pre-creation)
|
||||||
- [Post Authentication](/docs/apis/actions/internal-authentication#post-authentication)
|
- [Post Authentication](/apis/actions/internal-authentication#post-authentication)
|
||||||
- External Authentication
|
- External Authentication
|
||||||
- [Pre Creation](/docs/apis/actions/internal-authentication#pre-creation)
|
- [Pre Creation](/apis/actions/internal-authentication#pre-creation)
|
||||||
- [Post Authentication](/docs/apis/actions/internal-authentication#post-authentication)
|
- [Post Authentication](/apis/actions/internal-authentication#post-authentication)
|
||||||
|
|
||||||
<details open="">
|
<details open="">
|
||||||
<summary>Code example</summary>
|
<summary>Code example</summary>
|
||||||
@@ -245,7 +245,7 @@ https://github.com/zitadel/actions/blob/main/examples/set_idp_picture_metadata.j
|
|||||||
|
|
||||||
### Attributes provided by Okta as SAML IDP
|
### Attributes provided by Okta as SAML IDP
|
||||||
|
|
||||||
If you use [Okta as an identity provider](/guides/integrate/identity-providers/okta-saml#add-attribute-statements) you can improve the onboarding experience of new users by prefilling some basic information during authentication.
|
If you use [Okta as an identity provider](/guides/integrate/identity-providers/okta_saml#add-attribute-statements) you can improve the onboarding experience of new users by prefilling some basic information during authentication.
|
||||||
|
|
||||||
<details open="">
|
<details open="">
|
||||||
<summary>Code example</summary>
|
<summary>Code example</summary>
|
||||||
@@ -293,13 +293,13 @@ Execution paths might change based on the application initiating the authenticat
|
|||||||
#### Triggers
|
#### Triggers
|
||||||
|
|
||||||
- Internal Authentication
|
- Internal Authentication
|
||||||
- [Pre Creation](/docs/apis/actions/internal-authentication#pre-creation)
|
- [Pre Creation](/apis/actions/internal-authentication#pre-creation)
|
||||||
- [Post Creation](/docs/apis/actions/internal-authentication#post-creation)
|
- [Post Creation](/apis/actions/internal-authentication#post-creation)
|
||||||
- [Post Authentication](/docs/apis/actions/internal-authentication#post-authentication)
|
- [Post Authentication](/apis/actions/internal-authentication#post-authentication)
|
||||||
- External Authentication
|
- External Authentication
|
||||||
- [Pre Creation](/docs/apis/actions/external-authentication#pre-creation)
|
- [Pre Creation](/apis/actions/external-authentication#pre-creation)
|
||||||
- [Post Creation](/docs/apis/actions/external-authentication#post-creation)
|
- [Post Creation](/apis/actions/external-authentication#post-creation)
|
||||||
- [Post Authentication](/docs/apis/actions/external-authentication#post-authentication)
|
- [Post Authentication](/apis/actions/external-authentication#post-authentication)
|
||||||
|
|
||||||
<details open="">
|
<details open="">
|
||||||
<summary>Code example</summary>
|
<summary>Code example</summary>
|
||||||
@@ -310,7 +310,7 @@ https://github.com/zitadel/actions/blob/main/examples/execute_action_on_specific
|
|||||||
|
|
||||||
</details>
|
</details>
|
||||||
|
|
||||||
This example uses [zitadel's log module](/docs/apis/actions/modules#log)
|
This example uses [zitadel's log module](/apis/actions/modules#log)
|
||||||
|
|
||||||
### Check authentication error
|
### Check authentication error
|
||||||
|
|
||||||
@@ -319,9 +319,9 @@ Your action can also check for errors during the login process.
|
|||||||
#### Triggers
|
#### Triggers
|
||||||
|
|
||||||
- Internal Authentication
|
- Internal Authentication
|
||||||
- [Post Authentication](/docs/apis/actions/internal-authentication#post-authentication)
|
- [Post Authentication](/apis/actions/internal-authentication#post-authentication)
|
||||||
- External Authentication
|
- External Authentication
|
||||||
- [Post Authentication](/docs/apis/actions/external-authentication#post-authentication)
|
- [Post Authentication](/apis/actions/external-authentication#post-authentication)
|
||||||
|
|
||||||
<details open="">
|
<details open="">
|
||||||
<summary>Code example</summary>
|
<summary>Code example</summary>
|
||||||
@@ -332,7 +332,7 @@ https://github.com/zitadel/actions/blob/main/examples/post_auth_log.js
|
|||||||
|
|
||||||
</details>
|
</details>
|
||||||
|
|
||||||
This example uses [zitadel's log module](/docs/apis/actions/modules#log)
|
This example uses [zitadel's log module](/apis/actions/modules#log)
|
||||||
|
|
||||||
### Throw an error
|
### Throw an error
|
||||||
|
|
||||||
+12
-12
@@ -14,7 +14,7 @@ The trigger is represented by the following Ids in the API: `4`
|
|||||||
|
|
||||||
### Parameters of Pre Userinfo creation
|
### Parameters of Pre Userinfo creation
|
||||||
|
|
||||||
- `ctx`
|
- `ctx`
|
||||||
The first parameter contains the following fields:
|
The first parameter contains the following fields:
|
||||||
- `v1`
|
- `v1`
|
||||||
- `claims` [*Claims*](./objects#claims)
|
- `claims` [*Claims*](./objects#claims)
|
||||||
@@ -24,20 +24,20 @@ The trigger is represented by the following Ids in the API: `4`
|
|||||||
- `grants` [*UserGrantList*](./objects#user-grant-list)
|
- `grants` [*UserGrantList*](./objects#user-grant-list)
|
||||||
- `org`
|
- `org`
|
||||||
- `getMetadata()` [*metadataResult*](./objects#metadata-result)
|
- `getMetadata()` [*metadataResult*](./objects#metadata-result)
|
||||||
- `api`
|
- `api`
|
||||||
The second parameter contains the following fields:
|
The second parameter contains the following fields:
|
||||||
- `v1`
|
- `v1`
|
||||||
- `userinfo`
|
- `userinfo`
|
||||||
This function is deprecated, please use `api.v1.claims`
|
This function is deprecated, please use `api.v1.claims`
|
||||||
- `setClaim(string, Any)`
|
- `setClaim(string, Any)`
|
||||||
Sets any value if the key is not already present. If it's already present there is a message added to `urn:zitadel:iam:action:${action.name}:log`
|
Sets any value if the key is not already present. If it's already present there is a message added to `urn:zitadel:iam:action:${action.name}:log`
|
||||||
Note that keys with prefix `urn:zitadel:iam` will be ignored.
|
Note that keys with prefix `urn:zitadel:iam` will be ignored.
|
||||||
- `claims`
|
- `claims`
|
||||||
- `setClaim(string, Any)`
|
- `setClaim(string, Any)`
|
||||||
Sets any value if the key is not already present. If it's already present there is a message added to `urn:zitadel:iam:action:${action.name}:log`
|
Sets any value if the key is not already present. If it's already present there is a message added to `urn:zitadel:iam:action:${action.name}:log`
|
||||||
Note that keys with prefix `urn:zitadel:iam` will be ignored.
|
Note that keys with prefix `urn:zitadel:iam` will be ignored.
|
||||||
- `user`
|
- `user`
|
||||||
- `setMetadata(string, Any)`
|
- `setMetadata(string, Any)`
|
||||||
Key of the metadata and any value
|
Key of the metadata and any value
|
||||||
|
|
||||||
## Pre access token creation
|
## Pre access token creation
|
||||||
@@ -48,7 +48,7 @@ The trigger is represented by the following Ids in the API: `5`
|
|||||||
|
|
||||||
### Parameters of Pre access token creation
|
### Parameters of Pre access token creation
|
||||||
|
|
||||||
- `ctx`
|
- `ctx`
|
||||||
The first parameter contains the following fields:
|
The first parameter contains the following fields:
|
||||||
- `v1`
|
- `v1`
|
||||||
- `claims` [*Claims*](./objects#claims)
|
- `claims` [*Claims*](./objects#claims)
|
||||||
@@ -58,15 +58,15 @@ The trigger is represented by the following Ids in the API: `5`
|
|||||||
- `grants` [*UserGrantList*](./objects#user-grant-list)
|
- `grants` [*UserGrantList*](./objects#user-grant-list)
|
||||||
- `org`
|
- `org`
|
||||||
- `getMetadata()` [*metadataResult*](./objects#metadata-result)
|
- `getMetadata()` [*metadataResult*](./objects#metadata-result)
|
||||||
- `api`
|
- `api`
|
||||||
The second parameter contains the following fields:
|
The second parameter contains the following fields:
|
||||||
- `v1`
|
- `v1`
|
||||||
- `claims`
|
- `claims`
|
||||||
- `setClaim(string, Any)`
|
- `setClaim(string, Any)`
|
||||||
Sets any value if the key is not already present. If it's already present there is a message added to `urn:zitadel:iam:action:${action.name}:log`
|
Sets any value if the key is not already present. If it's already present there is a message added to `urn:zitadel:iam:action:${action.name}:log`
|
||||||
Note that keys with prefix `urn:zitadel:iam` will be ignored.
|
Note that keys with prefix `urn:zitadel:iam` will be ignored.
|
||||||
- `appendLogIntoClaims(string)`
|
- `appendLogIntoClaims(string)`
|
||||||
Appends the entry into the claim `urn:zitadel:action:{action.name}:log` the value of the claim is an Array of *string*
|
Appends the entry into the claim `urn:zitadel:action:{action.name}:log` the value of the claim is an Array of *string*
|
||||||
- `user`
|
- `user`
|
||||||
- `setMetadata(string, Any)`
|
- `setMetadata(string, Any)`
|
||||||
Key of the metadata and any value
|
Key of the metadata and any value
|
||||||
+4
-4
@@ -14,7 +14,7 @@ The trigger is represented by the following Ids in the API: `6`.
|
|||||||
|
|
||||||
### Parameters of Pre SAMLResponse creation
|
### Parameters of Pre SAMLResponse creation
|
||||||
|
|
||||||
- `ctx`
|
- `ctx`
|
||||||
The first parameter contains the following fields:
|
The first parameter contains the following fields:
|
||||||
- `v1`
|
- `v1`
|
||||||
- `getUser()` [*User*](./objects#user)
|
- `getUser()` [*User*](./objects#user)
|
||||||
@@ -23,12 +23,12 @@ The trigger is represented by the following Ids in the API: `6`.
|
|||||||
- `grants` [*UserGrantList*](./objects#user-grant-list)
|
- `grants` [*UserGrantList*](./objects#user-grant-list)
|
||||||
- `org`
|
- `org`
|
||||||
- `getMetadata()` [*metadataResult*](./objects#metadata-result)
|
- `getMetadata()` [*metadataResult*](./objects#metadata-result)
|
||||||
- `api`
|
- `api`
|
||||||
The second parameter contains the following fields:
|
The second parameter contains the following fields:
|
||||||
- `v1`
|
- `v1`
|
||||||
- `attributes`
|
- `attributes`
|
||||||
- `setCustomAttribute(string, string, ...string)`
|
- `setCustomAttribute(string, string, ...string)`
|
||||||
Sets any value as attribute in addition to the default attributes, if the key is not already present. The parameters represent the key, nameFormat and the attributeValue(s).
|
Sets any value as attribute in addition to the default attributes, if the key is not already present. The parameters represent the key, nameFormat and the attributeValue(s).
|
||||||
- `user`
|
- `user`
|
||||||
- `setMetadata(string, Any)`
|
- `setMetadata(string, Any)`
|
||||||
Key of the metadata and any value
|
Key of the metadata and any value
|
||||||
+45
-45
@@ -14,56 +14,56 @@ The trigger is represented by the following Ids in the API: `TRIGGER_TYPE_POST_A
|
|||||||
|
|
||||||
### Parameters of Post Authentication Action
|
### Parameters of Post Authentication Action
|
||||||
|
|
||||||
- `ctx`
|
- `ctx`
|
||||||
The first parameter contains the following fields
|
The first parameter contains the following fields
|
||||||
- `accessToken` *string*
|
- `accessToken` *string*
|
||||||
The access token returned by the identity provider. This can be an opaque token or a JWT
|
The access token returned by the identity provider. This can be an opaque token or a JWT
|
||||||
- `refreshToken` *string*
|
- `refreshToken` *string*
|
||||||
The refresh token returned by the identity provider if there is one. This is most likely to be an opaque token.
|
The refresh token returned by the identity provider if there is one. This is most likely to be an opaque token.
|
||||||
- `claimsJSON()` [*idTokenClaims*](../openidoauth/claims)
|
- `claimsJSON()` [*idTokenClaims*](../openidoauth/claims)
|
||||||
Returns all claims of the id token
|
Returns all claims of the id token
|
||||||
- `getClaim(key)` *Any*
|
- `getClaim(key)` *Any*
|
||||||
Returns the requested [id token claim](../openidoauth/claims)
|
Returns the requested [id token claim](../openidoauth/claims)
|
||||||
- `idToken` *string*
|
- `idToken` *string*
|
||||||
The id token provided by the identity provider.
|
The id token provided by the identity provider.
|
||||||
- `v1`
|
- `v1`
|
||||||
- `externalUser` [*externalUser*](./objects#external-user)
|
- `externalUser` [*externalUser*](./objects#external-user)
|
||||||
- `authError` *string*
|
- `authError` *string*
|
||||||
This is a verification errors string representation. If the verification succeeds, this is "none"
|
This is a verification errors string representation. If the verification succeeds, this is "none"
|
||||||
- `authRequest` [*auth request*](/docs/apis/actions/objects#auth-request)
|
- `authRequest` [*auth request*](/apis/actions/objects#auth-request)
|
||||||
- `httpRequest` [*http request*](/docs/apis/actions/objects#http-request)
|
- `httpRequest` [*http request*](/apis/actions/objects#http-request)
|
||||||
- `providerInfo` *Any*
|
- `providerInfo` *Any*
|
||||||
Returns the response of the provider. In case the provider is a Generic OAuth Provider, the information is accessible through:
|
Returns the response of the provider. In case the provider is a Generic OAuth Provider, the information is accessible through:
|
||||||
- `rawInfo` *Any*
|
- `rawInfo` *Any*
|
||||||
- `org`
|
- `org`
|
||||||
- `getMetadata()` [*metadataResult*](./objects#metadata-result)
|
- `getMetadata()` [*metadataResult*](./objects#metadata-result)
|
||||||
- `api`
|
- `api`
|
||||||
The second parameter contains the following fields
|
The second parameter contains the following fields
|
||||||
- `v1`
|
- `v1`
|
||||||
- `user`
|
- `user`
|
||||||
- `appendMetadata(string, Any)`
|
- `appendMetadata(string, Any)`
|
||||||
The first parameter represents the key and the second a value which will be stored
|
The first parameter represents the key and the second a value which will be stored
|
||||||
- `setFirstName(string)`
|
- `setFirstName(string)`
|
||||||
Sets the first name
|
Sets the first name
|
||||||
- `setLastName(string)`
|
- `setLastName(string)`
|
||||||
Sets the last name
|
Sets the last name
|
||||||
- `setNickName(string)`
|
- `setNickName(string)`
|
||||||
Sets the nickname
|
Sets the nickname
|
||||||
- `setDisplayName(string)`
|
- `setDisplayName(string)`
|
||||||
Sets the display name
|
Sets the display name
|
||||||
- `setPreferredLanguage(string)`
|
- `setPreferredLanguage(string)`
|
||||||
Sets the preferred language. Please use the format defined in [RFC 5646](https://www.rfc-editor.org/rfc/rfc5646)
|
Sets the preferred language. Please use the format defined in [RFC 5646](https://www.rfc-editor.org/rfc/rfc5646)
|
||||||
- `setPreferredUsername(string)`
|
- `setPreferredUsername(string)`
|
||||||
Sets the preferred username
|
Sets the preferred username
|
||||||
- `setEmail(string)`
|
- `setEmail(string)`
|
||||||
Sets the email address of the user
|
Sets the email address of the user
|
||||||
- `setEmailVerified(boolean)`
|
- `setEmailVerified(boolean)`
|
||||||
Sets the email address verified or unverified
|
Sets the email address verified or unverified
|
||||||
- `setPhone(string)`
|
- `setPhone(string)`
|
||||||
Sets the phone number of the user
|
Sets the phone number of the user
|
||||||
- `setPhoneVerified(boolean)`
|
- `setPhoneVerified(boolean)`
|
||||||
Sets the phone number verified or unverified
|
Sets the phone number verified or unverified
|
||||||
- `metadata`
|
- `metadata`
|
||||||
Array of [*metadata*](./objects#metadata-with-value-as-bytes). This function is deprecated, please use `api.v1.user.appendMetadata`
|
Array of [*metadata*](./objects#metadata-with-value-as-bytes). This function is deprecated, please use `api.v1.user.appendMetadata`
|
||||||
|
|
||||||
## Pre Creation
|
## Pre Creation
|
||||||
@@ -74,44 +74,44 @@ The trigger is represented by the following Ids in the API: `TRIGGER_TYPE_PRE_CR
|
|||||||
|
|
||||||
### Parameters of Pre Creation
|
### Parameters of Pre Creation
|
||||||
|
|
||||||
- `ctx`
|
- `ctx`
|
||||||
The first parameter contains the following fields
|
The first parameter contains the following fields
|
||||||
- `v1`
|
- `v1`
|
||||||
- `user` [*human*](./objects#human-user)
|
- `user` [*human*](./objects#human-user)
|
||||||
- `authRequest` [*auth request*](/docs/apis/actions/objects#auth-request)
|
- `authRequest` [*auth request*](/apis/actions/objects#auth-request)
|
||||||
- `httpRequest` [*http request*](/docs/apis/actions/objects#http-request)
|
- `httpRequest` [*http request*](/apis/actions/objects#http-request)
|
||||||
- `org`
|
- `org`
|
||||||
- `getMetadata()` [*metadataResult*](./objects#metadata-result)
|
- `getMetadata()` [*metadataResult*](./objects#metadata-result)
|
||||||
- `api`
|
- `api`
|
||||||
The second parameter contains the following fields
|
The second parameter contains the following fields
|
||||||
- `metadata`
|
- `metadata`
|
||||||
Array of [*metadata*](./objects#metadata-with-value-as-bytes). This function is deprecated, please use `api.v1.user.appendMetadata`
|
Array of [*metadata*](./objects#metadata-with-value-as-bytes). This function is deprecated, please use `api.v1.user.appendMetadata`
|
||||||
- `setFirstName(string)`
|
- `setFirstName(string)`
|
||||||
Sets the first name
|
Sets the first name
|
||||||
- `setLastName(string)`
|
- `setLastName(string)`
|
||||||
Sets the last name
|
Sets the last name
|
||||||
- `setNickName(string)`
|
- `setNickName(string)`
|
||||||
Sets the nick name
|
Sets the nick name
|
||||||
- `setDisplayName(string)`
|
- `setDisplayName(string)`
|
||||||
Sets the display name
|
Sets the display name
|
||||||
- `setPreferredLanguage(string)`
|
- `setPreferredLanguage(string)`
|
||||||
Sets the preferred language, the string has to be a valid language tag as defined in [RFC 5646](https://www.rfc-editor.org/rfc/rfc5646)
|
Sets the preferred language, the string has to be a valid language tag as defined in [RFC 5646](https://www.rfc-editor.org/rfc/rfc5646)
|
||||||
- `setGender(int)`
|
- `setGender(int)`
|
||||||
Sets the gender.
|
Sets the gender.
|
||||||
<ul><li>0: unspecified</li><li>1: female</li><li>2: male</li><li>3: diverse</li></ul>
|
<ul><li>0: unspecified</li><li>1: female</li><li>2: male</li><li>3: diverse</li></ul>
|
||||||
- `setUsername(string)`
|
- `setUsername(string)`
|
||||||
Sets the username
|
Sets the username
|
||||||
- `setEmail(string)`
|
- `setEmail(string)`
|
||||||
Sets the email
|
Sets the email
|
||||||
- `setEmailVerified(bool)`
|
- `setEmailVerified(bool)`
|
||||||
If true the email set is verified without user interaction
|
If true the email set is verified without user interaction
|
||||||
- `setPhone(string)`
|
- `setPhone(string)`
|
||||||
Sets the phone number
|
Sets the phone number
|
||||||
- `setPhoneVerified(bool)`
|
- `setPhoneVerified(bool)`
|
||||||
If true the phone number set is verified without user interaction
|
If true the phone number set is verified without user interaction
|
||||||
- `v1`
|
- `v1`
|
||||||
- `user`
|
- `user`
|
||||||
- `appendMetadata(string, Any)`
|
- `appendMetadata(string, Any)`
|
||||||
The first parameter represents the key and the second a value which will be stored
|
The first parameter represents the key and the second a value which will be stored
|
||||||
|
|
||||||
## Post Creation
|
## Post Creation
|
||||||
@@ -122,15 +122,15 @@ The trigger is represented by the following Ids in the API: `TRIGGER_TYPE_POST_C
|
|||||||
|
|
||||||
### Parameters of Post Creation
|
### Parameters of Post Creation
|
||||||
|
|
||||||
- `ctx`
|
- `ctx`
|
||||||
The first parameter contains the following fields
|
The first parameter contains the following fields
|
||||||
- `v1`
|
- `v1`
|
||||||
- `getUser()` [*user*](./objects#user)
|
- `getUser()` [*user*](./objects#user)
|
||||||
- `authRequest` [*auth request*](/docs/apis/actions/objects#auth-request)
|
- `authRequest` [*auth request*](/apis/actions/objects#auth-request)
|
||||||
- `httpRequest` [*http request*](/docs/apis/actions/objects#http-request)
|
- `httpRequest` [*http request*](/apis/actions/objects#http-request)
|
||||||
- `org`
|
- `org`
|
||||||
- `getMetadata()` [*metadataResult*](./objects#metadata-result)
|
- `getMetadata()` [*metadataResult*](./objects#metadata-result)
|
||||||
- `api`
|
- `api`
|
||||||
The second parameter contains the following fields
|
The second parameter contains the following fields
|
||||||
- `userGrants` Array of [*userGrant*](./objects#user-grant)'s
|
- `userGrants` Array of [*userGrant*](./objects#user-grant)'s
|
||||||
- `v1`
|
- `v1`
|
||||||
+30
-30
@@ -16,22 +16,22 @@ The trigger is represented by the following Ids in the API: `TRIGGER_TYPE_POST_A
|
|||||||
|
|
||||||
### Parameters of Post Authentication Action
|
### Parameters of Post Authentication Action
|
||||||
|
|
||||||
- `ctx`
|
- `ctx`
|
||||||
The first parameter contains the following fields
|
The first parameter contains the following fields
|
||||||
- `v1`
|
- `v1`
|
||||||
- `authMethod` *string*
|
- `authMethod` *string*
|
||||||
This is one of "password", "OTP", "U2F" or "passwordless"
|
This is one of "password", "OTP", "U2F" or "passwordless"
|
||||||
- `authError` *string*
|
- `authError` *string*
|
||||||
This is a verification errors string representation. If the verification succeeds, this is "none"
|
This is a verification errors string representation. If the verification succeeds, this is "none"
|
||||||
- `authRequest` [*auth request*](/docs/apis/actions/objects#auth-request)
|
- `authRequest` [*auth request*](/apis/actions/objects#auth-request)
|
||||||
- `httpRequest` [*http request*](/docs/apis/actions/objects#http-request)
|
- `httpRequest` [*http request*](/apis/actions/objects#http-request)
|
||||||
- `api`
|
- `api`
|
||||||
The second parameter contains the following fields
|
The second parameter contains the following fields
|
||||||
- `metadata`
|
- `metadata`
|
||||||
Array of [*metadata*](./objects#metadata-with-value-as-bytes). This function is deprecated, please use `api.v1.user.appendMetadata`
|
Array of [*metadata*](./objects#metadata-with-value-as-bytes). This function is deprecated, please use `api.v1.user.appendMetadata`
|
||||||
- `v1`
|
- `v1`
|
||||||
- `user`
|
- `user`
|
||||||
- `appendMetadata(string, Any)`
|
- `appendMetadata(string, Any)`
|
||||||
The first parameter represents the key and the second a value which will be stored
|
The first parameter represents the key and the second a value which will be stored
|
||||||
|
|
||||||
## Pre Creation
|
## Pre Creation
|
||||||
@@ -43,60 +43,60 @@ The trigger is represented by the following Ids in the API: `TRIGGER_TYPE_PRE_CR
|
|||||||
|
|
||||||
### Parameters of Pre Creation
|
### Parameters of Pre Creation
|
||||||
|
|
||||||
- `ctx`
|
- `ctx`
|
||||||
The first parameter contains the following fields
|
The first parameter contains the following fields
|
||||||
- `v1`
|
- `v1`
|
||||||
- `user` [*human*](./objects#human-user)
|
- `user` [*human*](./objects#human-user)
|
||||||
- `authRequest` [*auth request*](/docs/apis/actions/objects#auth-request)
|
- `authRequest` [*auth request*](/apis/actions/objects#auth-request)
|
||||||
- `httpRequest` [*http request*](/docs/apis/actions/objects#http-request)
|
- `httpRequest` [*http request*](/apis/actions/objects#http-request)
|
||||||
- `api`
|
- `api`
|
||||||
The second parameter contains the following fields
|
The second parameter contains the following fields
|
||||||
- `metadata`
|
- `metadata`
|
||||||
Array of [*metadata*](./objects#metadata-with-value-as-bytes). This function is deprecated, please use `api.v1.user.appendMetadata`
|
Array of [*metadata*](./objects#metadata-with-value-as-bytes). This function is deprecated, please use `api.v1.user.appendMetadata`
|
||||||
- `setFirstName(string)`
|
- `setFirstName(string)`
|
||||||
Sets the first name
|
Sets the first name
|
||||||
- `setLastName(string)`
|
- `setLastName(string)`
|
||||||
Sets the last name
|
Sets the last name
|
||||||
- `setNickName(string)`
|
- `setNickName(string)`
|
||||||
Sets the nick name
|
Sets the nick name
|
||||||
- `setDisplayName(string)`
|
- `setDisplayName(string)`
|
||||||
Sets the display name
|
Sets the display name
|
||||||
- `setPreferredLanguage(string)`
|
- `setPreferredLanguage(string)`
|
||||||
Sets the preferred language, the string has to be a valid language tag as defined in [RFC 5646](https://www.rfc-editor.org/rfc/rfc5646)
|
Sets the preferred language, the string has to be a valid language tag as defined in [RFC 5646](https://www.rfc-editor.org/rfc/rfc5646)
|
||||||
- `setGender(int)`
|
- `setGender(int)`
|
||||||
Sets the gender.
|
Sets the gender.
|
||||||
<ul><li>0: unspecified</li><li>1: female</li><li>2: male</li><li>3: diverse</li></ul>
|
<ul><li>0: unspecified</li><li>1: female</li><li>2: male</li><li>3: diverse</li></ul>
|
||||||
- `setUsername(string)`
|
- `setUsername(string)`
|
||||||
Sets the username
|
Sets the username
|
||||||
- `setEmail(string)`
|
- `setEmail(string)`
|
||||||
Sets the email
|
Sets the email
|
||||||
- `setEmailVerified(bool)`
|
- `setEmailVerified(bool)`
|
||||||
If true the email set is verified without user interaction
|
If true the email set is verified without user interaction
|
||||||
- `setPhone(string)`
|
- `setPhone(string)`
|
||||||
Sets the phone number
|
Sets the phone number
|
||||||
- `setPhoneVerified(bool)`
|
- `setPhoneVerified(bool)`
|
||||||
If true the phone number set is verified without user interaction
|
If true the phone number set is verified without user interaction
|
||||||
- `v1`
|
- `v1`
|
||||||
- `user`
|
- `user`
|
||||||
- `appendMetadata(string, Any)`
|
- `appendMetadata(string, Any)`
|
||||||
The first parameter represents the key and the second a value which will be stored
|
The first parameter represents the key and the second a value which will be stored
|
||||||
|
|
||||||
## Post Creation
|
## Post Creation
|
||||||
|
|
||||||
A user registers directly at ZITADEL.
|
A user registers directly at ZITADEL.
|
||||||
ZITADEL successfully created the user.
|
ZITADEL successfully created the user.
|
||||||
|
|
||||||
The trigger is represented by the following Ids in the API: `TRIGGER_TYPE_POST_CREATION` or `3`.
|
The trigger is represented by the following Ids in the API: `TRIGGER_TYPE_POST_CREATION` or `3`.
|
||||||
|
|
||||||
### Parameters of Post Creation
|
### Parameters of Post Creation
|
||||||
|
|
||||||
- `ctx`
|
- `ctx`
|
||||||
The first parameter contains the following fields
|
The first parameter contains the following fields
|
||||||
- `v1`
|
- `v1`
|
||||||
- `getUser()` [*user*](./objects#user)
|
- `getUser()` [*user*](./objects#user)
|
||||||
- `authRequest` [*auth request*](/docs/apis/actions/objects#auth-request)
|
- `authRequest` [*auth request*](/apis/actions/objects#auth-request)
|
||||||
- `httpRequest` [*http request*](/docs/apis/actions/objects#http-request)
|
- `httpRequest` [*http request*](/apis/actions/objects#http-request)
|
||||||
- `api`
|
- `api`
|
||||||
The second parameter contains the following fields
|
The second parameter contains the following fields
|
||||||
- `userGrants` Array of [*userGrant*](./objects#user-grant)'s
|
- `userGrants` Array of [*userGrant*](./objects#user-grant)'s
|
||||||
- `v1`
|
- `v1`
|
||||||
@@ -21,20 +21,20 @@ This function allows to call HTTP servers. The function does NOT fulfil the [Fet
|
|||||||
#### Parameters
|
#### Parameters
|
||||||
|
|
||||||
- `url` *string*
|
- `url` *string*
|
||||||
- `options`
|
- `options`
|
||||||
**Optional**, containing custom settings that you want to apply to the request.
|
**Optional**, containing custom settings that you want to apply to the request.
|
||||||
- `headers`
|
- `headers`
|
||||||
Overwrites the default headers. One of the following types
|
Overwrites the default headers. One of the following types
|
||||||
- *map[string] string*
|
- *map[string] string*
|
||||||
The value is split into separate values after each comma `,`.
|
The value is split into separate values after each comma `,`.
|
||||||
- *map[string] Array of string*
|
- *map[string] Array of string*
|
||||||
The value is a string array
|
The value is a string array
|
||||||
- default:
|
- default:
|
||||||
- `Content-Type`: `application/json`
|
- `Content-Type`: `application/json`
|
||||||
- `Accept`: `application/json`
|
- `Accept`: `application/json`
|
||||||
- `method`
|
- `method`
|
||||||
The request method. Allowed values are `GET`, `POST`, `PUT`, `DELETE`
|
The request method. Allowed values are `GET`, `POST`, `PUT`, `DELETE`
|
||||||
- `body` *Object*
|
- `body` *Object*
|
||||||
JSON representation
|
JSON representation
|
||||||
|
|
||||||
#### Response
|
#### Response
|
||||||
@@ -43,13 +43,13 @@ If the request was invalid, an error will be thrown, otherwise a Response object
|
|||||||
|
|
||||||
The object has the following fields and methods:
|
The object has the following fields and methods:
|
||||||
|
|
||||||
- `status` *number*
|
- `status` *number*
|
||||||
Status code of response
|
Status code of response
|
||||||
- `body` *string*
|
- `body` *string*
|
||||||
Return value
|
Return value
|
||||||
- `json()` *Object*
|
- `json()` *Object*
|
||||||
Returns the body as JSON object, or throws an error if the body is not a json object.
|
Returns the body as JSON object, or throws an error if the body is not a json object.
|
||||||
- `text()` *string*
|
- `text()` *string*
|
||||||
Returns the body
|
Returns the body
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
@@ -89,7 +89,7 @@ logger.error("This is an error log.")
|
|||||||
|
|
||||||
#### Parameters
|
#### Parameters
|
||||||
|
|
||||||
- `msg` *string*
|
- `msg` *string*
|
||||||
The message you want to print out.
|
The message you want to print out.
|
||||||
|
|
||||||
## UUID
|
## UUID
|
||||||
@@ -106,33 +106,33 @@ This module provides functionality to generate a UUID
|
|||||||
|
|
||||||
This function generates a UUID using [google/uuid](https://github.com/google/uuid). `vX` allows to define the UUID version:
|
This function generates a UUID using [google/uuid](https://github.com/google/uuid). `vX` allows to define the UUID version:
|
||||||
|
|
||||||
- `uuid.v1()` *string*
|
- `uuid.v1()` *string*
|
||||||
Generates a UUID version 1, based on date-time and MAC address
|
Generates a UUID version 1, based on date-time and MAC address
|
||||||
- `uuid.v3(namespace, data)` *string*
|
- `uuid.v3(namespace, data)` *string*
|
||||||
Generates a UUID version 3, based on the provided namespace using MD5
|
Generates a UUID version 3, based on the provided namespace using MD5
|
||||||
- `uuid.v4()` *string*
|
- `uuid.v4()` *string*
|
||||||
Generates a UUID version 4, which is randomly generated
|
Generates a UUID version 4, which is randomly generated
|
||||||
- `uuid.v5(namespace, data)` *string*
|
- `uuid.v5(namespace, data)` *string*
|
||||||
Generates a UUID version 5, based on the provided namespace using SHA1
|
Generates a UUID version 5, based on the provided namespace using SHA1
|
||||||
|
|
||||||
#### Parameters
|
#### Parameters
|
||||||
|
|
||||||
- `namespace` *UUID*/*string*
|
- `namespace` *UUID*/*string*
|
||||||
Namespace to be used in the hashing function. Either provide one of defined [namespaces](#namespaces) or a string representing a UUID.
|
Namespace to be used in the hashing function. Either provide one of defined [namespaces](#namespaces) or a string representing a UUID.
|
||||||
- `data` *[]byte*/*string*
|
- `data` *[]byte*/*string*
|
||||||
data to be used in the hashing function. Possible types are []byte or string.
|
data to be used in the hashing function. Possible types are []byte or string.
|
||||||
|
|
||||||
### Namespaces
|
### Namespaces
|
||||||
|
|
||||||
The following predefined namespaces can be used for `uuid.v3` and `uuid.v5`:
|
The following predefined namespaces can be used for `uuid.v3` and `uuid.v5`:
|
||||||
|
|
||||||
- `uuid.namespaceDNS` *UUID*
|
- `uuid.namespaceDNS` *UUID*
|
||||||
6ba7b810-9dad-11d1-80b4-00c04fd430c8
|
6ba7b810-9dad-11d1-80b4-00c04fd430c8
|
||||||
- `uuid.namespaceURL` *UUID*
|
- `uuid.namespaceURL` *UUID*
|
||||||
6ba7b811-9dad-11d1-80b4-00c04fd430c8
|
6ba7b811-9dad-11d1-80b4-00c04fd430c8
|
||||||
- `uuid.namespaceOID` *UUID*
|
- `uuid.namespaceOID` *UUID*
|
||||||
6ba7b812-9dad-11d1-80b4-00c04fd430c8
|
6ba7b812-9dad-11d1-80b4-00c04fd430c8
|
||||||
- `uuid.namespaceX500` *UUID*
|
- `uuid.namespaceX500` *UUID*
|
||||||
6ba7b814-9dad-11d1-80b4-00c04fd430c8
|
6ba7b814-9dad-11d1-80b4-00c04fd430c8
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
@@ -4,16 +4,16 @@ title: Objects
|
|||||||
|
|
||||||
## External User
|
## External User
|
||||||
|
|
||||||
- `externalId` *string*
|
- `externalId` *string*
|
||||||
User id from the identity provider
|
User id from the identity provider
|
||||||
- `externalIdpId` *string*
|
- `externalIdpId` *string*
|
||||||
Id of the identity provider
|
Id of the identity provider
|
||||||
- `human`
|
- `human`
|
||||||
- `firstName` *string*
|
- `firstName` *string*
|
||||||
- `lastName` *string*
|
- `lastName` *string*
|
||||||
- `nickName` *string*
|
- `nickName` *string*
|
||||||
- `displayName` *string*
|
- `displayName` *string*
|
||||||
- `preferredLanguage` *string*
|
- `preferredLanguage` *string*
|
||||||
In [RFC 5646](https://www.rfc-editor.org/rfc/rfc5646) format
|
In [RFC 5646](https://www.rfc-editor.org/rfc/rfc5646) format
|
||||||
- `email` *string*
|
- `email` *string*
|
||||||
- `isEmailVerified` *boolean*
|
- `isEmailVerified` *boolean*
|
||||||
@@ -43,11 +43,11 @@ title: Objects
|
|||||||
|
|
||||||
## user grant
|
## user grant
|
||||||
|
|
||||||
- `projectID` *string*
|
- `projectID` *string*
|
||||||
Required. Id of the project to be granted
|
Required. Id of the project to be granted
|
||||||
- `projectGrantID` *string*
|
- `projectGrantID` *string*
|
||||||
Optional. If the grant is for a project grant, include projectGrantID
|
Optional. If the grant is for a project grant, include projectGrantID
|
||||||
- `roles` Array of *string*
|
- `roles` Array of *string*
|
||||||
Containing the roles
|
Containing the roles
|
||||||
|
|
||||||
## user
|
## user
|
||||||
@@ -56,29 +56,29 @@ title: Objects
|
|||||||
- `creationDate` *Date*
|
- `creationDate` *Date*
|
||||||
- `changeDate` *Date*
|
- `changeDate` *Date*
|
||||||
- `resourceOwner` *string*
|
- `resourceOwner` *string*
|
||||||
- `sequence` *number*
|
- `sequence` *number*
|
||||||
Unsigned 64 bit integer
|
Unsigned 64 bit integer
|
||||||
- `state` *number*
|
- `state` *number*
|
||||||
<ul><li>0: unspecified</li><li>1: active</li><li>2: inactive</li><li>3: deleted</li><li>4: locked</li><li>5: suspended</li><li>6: initial</li></ul>
|
<ul><li>0: unspecified</li><li>1: active</li><li>2: inactive</li><li>3: deleted</li><li>4: locked</li><li>5: suspended</li><li>6: initial</li></ul>
|
||||||
- `username` *string*
|
- `username` *string*
|
||||||
- `loginNames` Array of *string*
|
- `loginNames` Array of *string*
|
||||||
- `preferredLoginName` *string*
|
- `preferredLoginName` *string*
|
||||||
- `human`
|
- `human`
|
||||||
Set if the user is human
|
Set if the user is human
|
||||||
- `firstName` *string*
|
- `firstName` *string*
|
||||||
- `lastName` *string*
|
- `lastName` *string*
|
||||||
- `nickName` *string*
|
- `nickName` *string*
|
||||||
- `displayName` *string*
|
- `displayName` *string*
|
||||||
- `avatarKey` *string*
|
- `avatarKey` *string*
|
||||||
- `preferredLanguage` *string*
|
- `preferredLanguage` *string*
|
||||||
In [RFC 5646](https://www.rfc-editor.org/rfc/rfc5646) format
|
In [RFC 5646](https://www.rfc-editor.org/rfc/rfc5646) format
|
||||||
- `gender` *number*
|
- `gender` *number*
|
||||||
<ul><li>0: unspecified</li><li>1: female</li><li>2: male</li><li>3: diverse</li></ul>
|
<ul><li>0: unspecified</li><li>1: female</li><li>2: male</li><li>3: diverse</li></ul>
|
||||||
- `email` *string*
|
- `email` *string*
|
||||||
- `isEmailVerified` *boolean*
|
- `isEmailVerified` *boolean*
|
||||||
- `phone` *string*
|
- `phone` *string*
|
||||||
- `isPhoneVerified` *boolean*
|
- `isPhoneVerified` *boolean*
|
||||||
- `machine`
|
- `machine`
|
||||||
Set if the user is a machine
|
Set if the user is a machine
|
||||||
- `name` *string*
|
- `name` *string*
|
||||||
- `description` *string*
|
- `description` *string*
|
||||||
@@ -90,7 +90,7 @@ title: Objects
|
|||||||
- `changeDate` *Date*
|
- `changeDate` *Date*
|
||||||
- `resourceOwner` *string*
|
- `resourceOwner` *string*
|
||||||
- `sequence` *number*
|
- `sequence` *number*
|
||||||
- `state` *number*
|
- `state` *number*
|
||||||
<ul><li>0: unspecified</li><li>1: active</li><li>2: inactive</li><li>3: deleted</li><li>4: locked</li><li>5: suspended</li><li>6: initial</li></ul>
|
<ul><li>0: unspecified</li><li>1: active</li><li>2: inactive</li><li>3: deleted</li><li>4: locked</li><li>5: suspended</li><li>6: initial</li></ul>
|
||||||
- `username` *string*
|
- `username` *string*
|
||||||
- `loginNames` Array of *string*
|
- `loginNames` Array of *string*
|
||||||
@@ -100,7 +100,7 @@ title: Objects
|
|||||||
- `lastName` *string*
|
- `lastName` *string*
|
||||||
- `nickName` *string*
|
- `nickName` *string*
|
||||||
- `displayName` *string*
|
- `displayName` *string*
|
||||||
- `preferredLanguage` *string*
|
- `preferredLanguage` *string*
|
||||||
In [RFC 5646](https://www.rfc-editor.org/rfc/rfc5646) format
|
In [RFC 5646](https://www.rfc-editor.org/rfc/rfc5646) format
|
||||||
- `email`
|
- `email`
|
||||||
- `email` *string*
|
- `email` *string*
|
||||||
@@ -111,7 +111,7 @@ title: Objects
|
|||||||
|
|
||||||
## Auth Request
|
## Auth Request
|
||||||
|
|
||||||
This object contains context information about the request to the [authorization endpoint](/docs/apis/openidoauth/endpoints#authorization_endpoint).
|
This object contains context information about the request to the [authorization endpoint](/apis/openidoauth/endpoints#authorization-endpoint).
|
||||||
|
|
||||||
- `id` *string*
|
- `id` *string*
|
||||||
- `agentId` *string*
|
- `agentId` *string*
|
||||||
@@ -124,11 +124,11 @@ This object contains context information about the request to the [authorization
|
|||||||
- `applicationId` *string*
|
- `applicationId` *string*
|
||||||
- `callbackUri` *string*
|
- `callbackUri` *string*
|
||||||
- `transferState` *string*
|
- `transferState` *string*
|
||||||
- `prompt` Array of *Number*
|
- `prompt` Array of *Number*
|
||||||
<ul><li>0: not specified</li><li>1: none</li><li>2: login</li><li>3: consent</li><li>4: select_account</li><li>5: create</li></ul>
|
<ul><li>0: not specified</li><li>1: none</li><li>2: login</li><li>3: consent</li><li>4: select_account</li><li>5: create</li></ul>
|
||||||
- `uiLocales` Array of *string*
|
- `uiLocales` Array of *string*
|
||||||
- `loginHint` *string*
|
- `loginHint` *string*
|
||||||
- `maxAuthAge` *Number*
|
- `maxAuthAge` *Number*
|
||||||
Duration in nanoseconds
|
Duration in nanoseconds
|
||||||
- `instanceId` *string*
|
- `instanceId` *string*
|
||||||
- `request`
|
- `request`
|
||||||
@@ -149,7 +149,7 @@ This object contains context information about the request to the [authorization
|
|||||||
- `selectedIdpConfigId` *string*
|
- `selectedIdpConfigId` *string*
|
||||||
- `linkingUsers` Array of [*ExternalUser*](#external-user)
|
- `linkingUsers` Array of [*ExternalUser*](#external-user)
|
||||||
- `passwordVerified` *bool*
|
- `passwordVerified` *bool*
|
||||||
- `mfasVerified` Array of *Number*
|
- `mfasVerified` Array of *Number*
|
||||||
<ul><li>0: OTP</li><li>1: U2F</li><li>2: U2F User verification</li></ul>
|
<ul><li>0: OTP</li><li>1: U2F</li><li>2: U2F User verification</li></ul>
|
||||||
- `audience` Array of *string*
|
- `audience` Array of *string*
|
||||||
- `authTime` *Date*
|
- `authTime` *Date*
|
||||||
@@ -193,22 +193,22 @@ This object represents a list of user grant stored in ZITADEL.
|
|||||||
- `timestamp` *Date*
|
- `timestamp` *Date*
|
||||||
- `grants` Array of
|
- `grants` Array of
|
||||||
- `id` *string*
|
- `id` *string*
|
||||||
- `projectGrantId` *string*
|
- `projectGrantId` *string*
|
||||||
The id of the [project grant](/docs/guides/solution-scenarios/saas#project-grant)
|
The id of the [project grant](/guides/solution-scenarios/saas#project-grant)
|
||||||
- `state` *Number*
|
- `state` *Number*
|
||||||
<ul><li>0: unspecified</li><li>1: active</li><li>2: inactive</li><li>3: removed</li></ul>
|
<ul><li>0: unspecified</li><li>1: active</li><li>2: inactive</li><li>3: removed</li></ul>
|
||||||
- `creationDate` *Date*
|
- `creationDate` *Date*
|
||||||
- `changeDate` *Date*
|
- `changeDate` *Date*
|
||||||
- `sequence` *Number*
|
- `sequence` *Number*
|
||||||
- `userId` *string*
|
- `userId` *string*
|
||||||
- `roles` Array of *string*
|
- `roles` Array of *string*
|
||||||
- `userResourceOwner` *string*
|
- `userResourceOwner` *string*
|
||||||
The id of the organization of the user
|
The id of the organization of the user
|
||||||
- `userGrantResourceOwner` *string*
|
- `userGrantResourceOwner` *string*
|
||||||
The id of the organization, where the user was granted
|
The id of the organization, where the user was granted
|
||||||
- `userGrantResourceOwnerName` *string*
|
- `userGrantResourceOwnerName` *string*
|
||||||
The name of the organization, where the user was granted
|
The name of the organization, where the user was granted
|
||||||
- `projectId` *string*
|
- `projectId` *string*
|
||||||
- `projectName` *string*
|
- `projectName` *string*
|
||||||
- `getOrgMetadata()` [*metadataResult*](#metadata-result)
|
- `getOrgMetadata()` [*metadataResult*](#metadata-result)
|
||||||
Get the metadata of the organization where the user was granted
|
Get the metadata of the organization where the user was granted
|
||||||
@@ -3,10 +3,10 @@ title: Core Resources
|
|||||||
sidebar_label: Core Resources
|
sidebar_label: Core Resources
|
||||||
---
|
---
|
||||||
|
|
||||||
import DocCardList from '@theme/DocCardList';
|
import DocCardList from '@/components/docusaurus/doc-card-list';
|
||||||
|
|
||||||
ZITADEL provides multiple APIs to manage the system, instances and resources such as users, projects and more.
|
ZITADEL provides multiple APIs to manage the system, instances and resources such as users, projects and more.
|
||||||
|
|
||||||
There are different versions and multiple services available:
|
There are different versions and multiple services available:
|
||||||
|
|
||||||
<DocCardList />
|
<DocCardList />
|
||||||
@@ -4,49 +4,35 @@ title: zitadel/assets
|
|||||||
|
|
||||||
## AssetsService
|
## AssetsService
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### UploadDefaultLabelPolicyFont()
|
### UploadDefaultLabelPolicyFont()
|
||||||
|
|
||||||
> UploadDefaultLabelPolicyFont()
|
> UploadDefaultLabelPolicyFont()
|
||||||
|
|
||||||
POST: /instance/policy/label/font
|
POST: /instance/policy/label/font
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### GetDefaultLabelPolicyFont()
|
### GetDefaultLabelPolicyFont()
|
||||||
|
|
||||||
> GetDefaultLabelPolicyFont()
|
> GetDefaultLabelPolicyFont()
|
||||||
|
|
||||||
GET: /instance/policy/label/font
|
GET: /instance/policy/label/font
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### GetPreviewDefaultLabelPolicyFont()
|
### GetPreviewDefaultLabelPolicyFont()
|
||||||
|
|
||||||
> GetPreviewDefaultLabelPolicyFont()
|
> GetPreviewDefaultLabelPolicyFont()
|
||||||
|
|
||||||
GET: /instance/policy/label/font/_preview
|
GET: /instance/policy/label/font/_preview
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### UploadDefaultLabelPolicyIcon()
|
### UploadDefaultLabelPolicyIcon()
|
||||||
|
|
||||||
> UploadDefaultLabelPolicyIcon()
|
> UploadDefaultLabelPolicyIcon()
|
||||||
|
|
||||||
POST: /instance/policy/label/icon
|
POST: /instance/policy/label/icon
|
||||||
|
|
||||||
### UploadDefaultLabelPolicyIcon()
|
### UploadDefaultLabelPolicyIconDark()
|
||||||
|
|
||||||
> UploadDefaultLabelPolicyIconDark()
|
> UploadDefaultLabelPolicyIconDark()
|
||||||
|
|
||||||
POST: /instance/policy/label/icon/dark
|
POST: /instance/policy/label/icon/dark
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### GetDefaultLabelPolicyIcon()
|
### GetDefaultLabelPolicyIcon()
|
||||||
|
|
||||||
@@ -54,13 +40,11 @@ POST: /instance/policy/label/icon/dark
|
|||||||
|
|
||||||
GET: /instance/policy/label/icon
|
GET: /instance/policy/label/icon
|
||||||
|
|
||||||
### GetDefaultLabelPolicyIcon()
|
### GetDefaultLabelPolicyIconDark()
|
||||||
|
|
||||||
> GetDefaultLabelPolicyIconDark()
|
> GetDefaultLabelPolicyIconDark()
|
||||||
|
|
||||||
GET: /instance/policy/label/icon/dark
|
GET: /instance/policy/label/icon/dark
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### GetPreviewDefaultLabelPolicyIcon()
|
### GetPreviewDefaultLabelPolicyIcon()
|
||||||
|
|
||||||
@@ -68,15 +52,11 @@ GET: /instance/policy/label/icon/dark
|
|||||||
|
|
||||||
GET: /instance/policy/label/icon/_preview
|
GET: /instance/policy/label/icon/_preview
|
||||||
|
|
||||||
### GetPreviewDefaultLabelPolicyIcon()
|
### GetPreviewDefaultLabelPolicyIconDark()
|
||||||
|
|
||||||
> GetPreviewDefaultLabelPolicyIconDark()
|
> GetPreviewDefaultLabelPolicyIconDark()
|
||||||
|
|
||||||
GET: /instance/policy/label/icon/dark/_preview
|
GET: /instance/policy/label/icon/dark/_preview
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### UploadDefaultLabelPolicyLogo()
|
### UploadDefaultLabelPolicyLogo()
|
||||||
|
|
||||||
@@ -84,13 +64,11 @@ GET: /instance/policy/label/icon/dark/_preview
|
|||||||
|
|
||||||
POST: /instance/policy/label/logo
|
POST: /instance/policy/label/logo
|
||||||
|
|
||||||
### UploadDefaultLabelPolicyLogo()
|
### UploadDefaultLabelPolicyLogoDark()
|
||||||
|
|
||||||
> UploadDefaultLabelPolicyLogoDark()
|
> UploadDefaultLabelPolicyLogoDark()
|
||||||
|
|
||||||
POST: /instance/policy/label/logo/dark
|
POST: /instance/policy/label/logo/dark
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### GetDefaultLabelPolicyLogo()
|
### GetDefaultLabelPolicyLogo()
|
||||||
|
|
||||||
@@ -98,13 +76,11 @@ POST: /instance/policy/label/logo/dark
|
|||||||
|
|
||||||
GET: /instance/policy/label/logo
|
GET: /instance/policy/label/logo
|
||||||
|
|
||||||
### GetDefaultLabelPolicyLogo()
|
### GetDefaultLabelPolicyLogoDark()
|
||||||
|
|
||||||
> GetDefaultLabelPolicyLogoDark()
|
> GetDefaultLabelPolicyLogoDark()
|
||||||
|
|
||||||
GET: /instance/policy/label/logo/dark
|
GET: /instance/policy/label/logo/dark
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### GetPreviewDefaultLabelPolicyLogo()
|
### GetPreviewDefaultLabelPolicyLogo()
|
||||||
|
|
||||||
@@ -112,17 +88,11 @@ GET: /instance/policy/label/logo/dark
|
|||||||
|
|
||||||
GET: /instance/policy/label/logo/_preview
|
GET: /instance/policy/label/logo/_preview
|
||||||
|
|
||||||
### GetPreviewDefaultLabelPolicyLogo()
|
### GetPreviewDefaultLabelPolicyLogoDark()
|
||||||
|
|
||||||
> GetPreviewDefaultLabelPolicyLogoDark()
|
> GetPreviewDefaultLabelPolicyLogoDark()
|
||||||
|
|
||||||
GET: /instance/policy/label/logo/dark/_preview
|
GET: /instance/policy/label/logo/dark/_preview
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### UploadOrgLabelPolicyFont()
|
### UploadOrgLabelPolicyFont()
|
||||||
|
|
||||||
@@ -130,39 +100,29 @@ GET: /instance/policy/label/logo/dark/_preview
|
|||||||
|
|
||||||
POST: /org/policy/label/font
|
POST: /org/policy/label/font
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### GetOrgLabelPolicyFont()
|
### GetOrgLabelPolicyFont()
|
||||||
|
|
||||||
> GetOrgLabelPolicyFont()
|
> GetOrgLabelPolicyFont()
|
||||||
|
|
||||||
GET: /org/policy/label/font
|
GET: /org/policy/label/font
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### GetPreviewOrgLabelPolicyFont()
|
### GetPreviewOrgLabelPolicyFont()
|
||||||
|
|
||||||
> GetPreviewOrgLabelPolicyFont()
|
> GetPreviewOrgLabelPolicyFont()
|
||||||
|
|
||||||
GET: /org/policy/label/font/_preview
|
GET: /org/policy/label/font/_preview
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### UploadOrgLabelPolicyIcon()
|
### UploadOrgLabelPolicyIcon()
|
||||||
|
|
||||||
> UploadOrgLabelPolicyIcon()
|
> UploadOrgLabelPolicyIcon()
|
||||||
|
|
||||||
POST: /org/policy/label/icon
|
POST: /org/policy/label/icon
|
||||||
|
|
||||||
### UploadOrgLabelPolicyIcon()
|
### UploadOrgLabelPolicyIconDark()
|
||||||
|
|
||||||
> UploadOrgLabelPolicyIconDark()
|
> UploadOrgLabelPolicyIconDark()
|
||||||
|
|
||||||
POST: /org/policy/label/icon/dark
|
POST: /org/policy/label/icon/dark
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### GetOrgLabelPolicyIcon()
|
### GetOrgLabelPolicyIcon()
|
||||||
|
|
||||||
@@ -170,13 +130,11 @@ POST: /org/policy/label/icon/dark
|
|||||||
|
|
||||||
GET: /org/policy/label/icon
|
GET: /org/policy/label/icon
|
||||||
|
|
||||||
### GetOrgLabelPolicyIcon()
|
### GetOrgLabelPolicyIconDark()
|
||||||
|
|
||||||
> GetOrgLabelPolicyIconDark()
|
> GetOrgLabelPolicyIconDark()
|
||||||
|
|
||||||
GET: /org/policy/label/icon/dark
|
GET: /org/policy/label/icon/dark
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### GetPreviewOrgLabelPolicyIcon()
|
### GetPreviewOrgLabelPolicyIcon()
|
||||||
|
|
||||||
@@ -184,15 +142,11 @@ GET: /org/policy/label/icon/dark
|
|||||||
|
|
||||||
GET: /org/policy/label/icon/_preview
|
GET: /org/policy/label/icon/_preview
|
||||||
|
|
||||||
### GetPreviewOrgLabelPolicyIcon()
|
### GetPreviewOrgLabelPolicyIconDark()
|
||||||
|
|
||||||
> GetPreviewOrgLabelPolicyIconDark()
|
> GetPreviewOrgLabelPolicyIconDark()
|
||||||
|
|
||||||
GET: /org/policy/label/icon/dark/_preview
|
GET: /org/policy/label/icon/dark/_preview
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### UploadOrgLabelPolicyLogo()
|
### UploadOrgLabelPolicyLogo()
|
||||||
|
|
||||||
@@ -200,13 +154,11 @@ GET: /org/policy/label/icon/dark/_preview
|
|||||||
|
|
||||||
POST: /org/policy/label/logo
|
POST: /org/policy/label/logo
|
||||||
|
|
||||||
### UploadOrgLabelPolicyLogo()
|
### UploadOrgLabelPolicyLogoDark()
|
||||||
|
|
||||||
> UploadOrgLabelPolicyLogoDark()
|
> UploadOrgLabelPolicyLogoDark()
|
||||||
|
|
||||||
POST: /org/policy/label/logo/dark
|
POST: /org/policy/label/logo/dark
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### GetOrgLabelPolicyLogo()
|
### GetOrgLabelPolicyLogo()
|
||||||
|
|
||||||
@@ -214,13 +166,11 @@ POST: /org/policy/label/logo/dark
|
|||||||
|
|
||||||
GET: /org/policy/label/logo
|
GET: /org/policy/label/logo
|
||||||
|
|
||||||
### GetOrgLabelPolicyLogo()
|
### GetOrgLabelPolicyLogoDark()
|
||||||
|
|
||||||
> GetOrgLabelPolicyLogoDark()
|
> GetOrgLabelPolicyLogoDark()
|
||||||
|
|
||||||
GET: /org/policy/label/logo/dark
|
GET: /org/policy/label/logo/dark
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### GetPreviewOrgLabelPolicyLogo()
|
### GetPreviewOrgLabelPolicyLogo()
|
||||||
|
|
||||||
@@ -228,17 +178,11 @@ GET: /org/policy/label/logo/dark
|
|||||||
|
|
||||||
GET: /org/policy/label/logo/_preview
|
GET: /org/policy/label/logo/_preview
|
||||||
|
|
||||||
### GetPreviewOrgLabelPolicyLogo()
|
### GetPreviewOrgLabelPolicyLogoDark()
|
||||||
|
|
||||||
> GetPreviewOrgLabelPolicyLogoDark()
|
> GetPreviewOrgLabelPolicyLogoDark()
|
||||||
|
|
||||||
GET: /org/policy/label/logo/dark/_preview
|
GET: /org/policy/label/logo/dark/_preview
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### UploadMyUserAvatar()
|
### UploadMyUserAvatar()
|
||||||
|
|
||||||
@@ -246,14 +190,8 @@ GET: /org/policy/label/logo/dark/_preview
|
|||||||
|
|
||||||
POST: /users/me/avatar
|
POST: /users/me/avatar
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### GetMyUserAvatar()
|
### GetMyUserAvatar()
|
||||||
|
|
||||||
> GetMyUserAvatar()
|
> GetMyUserAvatar()
|
||||||
|
|
||||||
GET: /users/me/avatar
|
GET: /users/me/avatar
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
+3
-37
@@ -1,32 +1,5 @@
|
|||||||
<!--
|
import OutputSource from "./output.json";
|
||||||
query data from output.csv:
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
Note: you might need to adjust the WHERE clause to only filter the required trends and the current placeholders
|
|
||||||
Warning: it's currently only possible to show data of one endpoint
|
|
||||||
|
|
||||||
```
|
|
||||||
copy (SELECT
|
|
||||||
metric_name
|
|
||||||
, to_timestamp(timestamp::DOUBLE) as timestamp
|
|
||||||
, approx_quantile(metric_value, 0.50) AS p50
|
|
||||||
, approx_quantile(metric_value, 0.95) AS p95
|
|
||||||
, approx_quantile(metric_value, 0.99) AS p99
|
|
||||||
FROM
|
|
||||||
read_csv('result.csv', auto_detect=false, null_padding=true, delim=',', quote='"', escape='"', new_line='\n', skip=0, comment='', header=true, columns={'metric_name': 'VARCHAR', 'timestamp': 'BIGINT', 'metric_value': 'DOUBLE', 'check': 'VARCHAR', 'error': 'VARCHAR', 'error_code': 'VARCHAR', 'expected_response': 'BOOLEAN', 'group': 'VARCHAR', 'method': 'VARCHAR', 'name': 'VARCHAR', 'proto': 'VARCHAR', 'scenario': 'VARCHAR', 'service': 'VARCHAR', 'status': 'BIGINT', 'subproto': 'VARCHAR', 'tls_version': 'VARCHAR', 'url': 'VARCHAR', 'extra_tags': 'VARCHAR', 'metadata': 'VARCHAR'})
|
|
||||||
WHERE
|
|
||||||
metric_name <> 'http_req_duration'
|
|
||||||
AND metric_name <> 'iteration_duration'
|
|
||||||
AND metric_name LIKE '%_duration'
|
|
||||||
GROUP BY
|
|
||||||
metric_name
|
|
||||||
, timestamp
|
|
||||||
ORDER BY
|
|
||||||
metric_name
|
|
||||||
, timestamp
|
|
||||||
) to 'output.json' (ARRAY);
|
|
||||||
```
|
|
||||||
|
|
||||||
-->
|
|
||||||
|
|
||||||
TODO: describe the outcome of the test?
|
TODO: describe the outcome of the test?
|
||||||
|
|
||||||
@@ -60,18 +33,11 @@ TODO: describe the outcome of the test?
|
|||||||
| k6 output | |
|
| k6 output | |
|
||||||
| flowchart outcome | |
|
| flowchart outcome | |
|
||||||
|
|
||||||
|
|
||||||
## Endpoint latencies
|
## Endpoint latencies
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
TODO: add summary of k6
|
TODO: add summary of k6
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -3,7 +3,7 @@ title: Benchmarks
|
|||||||
sidebar_label: Benchmarks
|
sidebar_label: Benchmarks
|
||||||
---
|
---
|
||||||
|
|
||||||
import DocCardList from '@theme/DocCardList';
|
import DocCardList from '@/components/docusaurus/doc-card-list';
|
||||||
|
|
||||||
Benchmarks are crucial to understand if ZITADEL fulfills your expected workload and what resources it needs to do so.
|
Benchmarks are crucial to understand if ZITADEL fulfills your expected workload and what resources it needs to do so.
|
||||||
|
|
||||||
@@ -15,26 +15,25 @@ The results can be found on sub pages.
|
|||||||
|
|
||||||
The primary goal is to assess if ZITADEL can scale to required proportion. The goals might change over time and maturity of ZITADEL. At the moment the goal is to assess how the application’s performance scales. There are some concrete goals we have to meet:
|
The primary goal is to assess if ZITADEL can scale to required proportion. The goals might change over time and maturity of ZITADEL. At the moment the goal is to assess how the application’s performance scales. There are some concrete goals we have to meet:
|
||||||
|
|
||||||
1. [https://github.com/zitadel/zitadel/issues/8352](https://github.com/zitadel/zitadel/issues/8352) defines 1000 JWT profile auth/sec
|
1. [https://github.com/zitadel/zitadel/issues/8352](https://github.com/zitadel/zitadel/issues/8352) defines 1000 JWT profile auth/sec
|
||||||
2. [https://github.com/zitadel/zitadel/issues/4424](https://github.com/zitadel/zitadel/issues/4424) defines 1200 logins / sec.
|
2. [https://github.com/zitadel/zitadel/issues/4424](https://github.com/zitadel/zitadel/issues/4424) defines 1200 logins / sec.
|
||||||
|
|
||||||
## Procedure
|
## Procedure
|
||||||
|
|
||||||
First we determine the “target” of our load-test. The target is expressed as a make recipe in the load-test [Makefile](https://github.com/zitadel/zitadel/blob/main/load-test/Makefile). See also the load-test [readme](https://github.com/zitadel/zitadel/blob/main/load-test/README.md) on how to configure and run load-tests.
|
First we determine the “target” of our load-test. The target is expressed as a make recipe in the load-test [Makefile](https://github.com/zitadel/zitadel/blob/main/load-test/Makefile). See also the load-test [readme](https://github.com/zitadel/zitadel/blob/main/load-test/README.md) on how to configure and run load-tests.
|
||||||
A target should be tested for longer periods of time, as it might take time for certain metrics to show up. For example, cloud SQL samples query insights. A runtime of at least **30 minutes** is advised at the moment.
|
A target should be tested for longer periods of time, as it might take time for certain metrics to show up. For example, cloud SQL samples query insights. A runtime of at least **30 minutes** is advised at the moment.
|
||||||
|
|
||||||
After each iteration of load-test, we should consult the [After test procedure](#after-test-procedure) to conclude an outcome:
|
After each iteration of load-test, we should consult the [After test procedure](#after-test-procedure) to conclude an outcome:
|
||||||
|
|
||||||
1. Scale
|
1. Scale
|
||||||
2. Log potential issuer and scale
|
2. Log potential issuer and scale
|
||||||
3. Terminate testing and resolve issues
|
3. Terminate testing and resolve issues
|
||||||
|
|
||||||
|
|
||||||
## Methodology
|
## Methodology
|
||||||
|
|
||||||
### Benchmark definition
|
### Benchmark definition
|
||||||
|
|
||||||
Tests are implemented in the ecosystem of [k6](https://k6.io). The tests are publicly available in the [zitadel repository](https://github.com/zitadel/zitadel/tree/main/load-test). Custom extensions of k6 are implemented in the [xk6-modules repository](https://github.com/zitadel/xk6-modules).
|
Tests are implemented in the ecosystem of [k6](https://k6.io). The tests are publicly available in the [zitadel repository](https://github.com/zitadel/zitadel/tree/main/load-test). Custom extensions of k6 are implemented in the [xk6-modules repository](https://github.com/zitadel/xk6-modules).
|
||||||
The tests must at least measure the request duration for each API call. This gives an indication on how zitadel behaves over the duration of the load test.
|
The tests must at least measure the request duration for each API call. This gives an indication on how zitadel behaves over the duration of the load test.
|
||||||
|
|
||||||
### Metrics
|
### Metrics
|
||||||
@@ -78,27 +77,24 @@ Details about the tests implemented can be found in [this readme](https://github
|
|||||||
|
|
||||||
After each iteration of load-test, we should consult the [Flowchart](#after-test-procedure) to conclude an outcome:
|
After each iteration of load-test, we should consult the [Flowchart](#after-test-procedure) to conclude an outcome:
|
||||||
|
|
||||||
1. [Scale](#scale)
|
1. [Scale](#scale)
|
||||||
2. [Log potential issue and scale](#potential-issues)
|
2. [Log potential issue and scale](#potential-issues)
|
||||||
3. [Terminate testing](#termination) and resolve issues
|
3. [Terminate testing](#termination) and resolve issues
|
||||||
|
|
||||||
#### Scale {#scale}
|
#### Scale
|
||||||
|
|
||||||
An outcome of scale means that the service hit some kind of resource limit, like CPU or RAM which can be increased. In such cases we increase the suggested parameter and rerun the load-test for the same target. On the next test we should analyze if the increase in scale resulted in a performance improvement proportional to the scale parameter. For example if we scale from 1 to 2 containers, it might be reasonable to expect a doubling of iterations / sec. If such an increase is not noticed, there might be another bottleneck or underlying issue, such as locking.
|
An outcome of scale means that the service hit some kind of resource limit, like CPU or RAM which can be increased. In such cases we increase the suggested parameter and rerun the load-test for the same target. On the next test we should analyze if the increase in scale resulted in a performance improvement proportional to the scale parameter. For example if we scale from 1 to 2 containers, it might be reasonable to expect a doubling of iterations / sec. If such an increase is not noticed, there might be another bottleneck or underlying issue, such as locking.
|
||||||
|
|
||||||
#### Potential issues {#potential-issues}
|
#### Potential issues
|
||||||
|
|
||||||
A potential issue has an impact on performance, but does not prevent us to scale. Such issues must be logged in GH issues and load-testing can continue. The issue can be resolved at a later time and the load-tests repeated when it is. This is primarily for issues which require big changes to ZITADEL.
|
A potential issue has an impact on performance, but does not prevent us to scale. Such issues must be logged in GH issues and load-testing can continue. The issue can be resolved at a later time and the load-tests repeated when it is. This is primarily for issues which require big changes to ZITADEL.
|
||||||
|
|
||||||
#### Termination {#termination}
|
#### Termination
|
||||||
|
|
||||||
Scaling no longer improves iterations / second, or some kind of critical error or bug is experienced. The root cause of the issue must be resolved before we can continue with increasing scale.
|
Scaling no longer improves iterations / second, or some kind of critical error or bug is experienced. The root cause of the issue must be resolved before we can continue with increasing scale.
|
||||||
|
|
||||||
### After test procedure
|
### After test procedure
|
||||||
|
|
||||||
This flowchart shows the procedure after running a test.
|
This flowchart shows the procedure after running a test.
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
## Baseline
|
## Baseline
|
||||||
|
|
||||||
+30
-33
@@ -3,6 +3,9 @@ title: machine jwt profile grant benchmark of zitadel v2.65.0
|
|||||||
sidebar_label: machine jwt profile grant
|
sidebar_label: machine jwt profile grant
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
Tests are halted after this test run because of too many [client read events](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/wait-event.clientread.html) on the database.
|
Tests are halted after this test run because of too many [client read events](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/wait-event.clientread.html) on the database.
|
||||||
|
|
||||||
## Performance test results
|
## Performance test results
|
||||||
@@ -32,42 +35,36 @@ Tests are halted after this test run because of too many [client read events](ht
|
|||||||
|
|
||||||
## /token endpoint latencies
|
## /token endpoint latencies
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
checks...............................: 100.00% ✓ 695739 ✗ 0
|
checks...............................: 100.00% ✓ 695739 ✗ 0
|
||||||
data_received........................: 479 MB 265 kB/s
|
data_received........................: 479 MB 265 kB/s
|
||||||
data_sent............................: 276 MB 153 kB/s
|
data_sent............................: 276 MB 153 kB/s
|
||||||
http_req_blocked.....................: min=178ns avg=5µs max=119.8ms p(50)=460ns p(95)=702ns p(99)=921ns
|
http_req_blocked.....................: min=178ns avg=5µs max=119.8ms p(50)=460ns p(95)=702ns p(99)=921ns
|
||||||
http_req_connecting..................: min=0s avg=1.24µs max=43.45ms p(50)=0s p(95)=0s p(99)=0s
|
http_req_connecting..................: min=0s avg=1.24µs max=43.45ms p(50)=0s p(95)=0s p(99)=0s
|
||||||
http_req_duration....................: min=18ms avg=255.3ms max=1.22s p(50)=241.56ms p(95)=479.19ms p(99)=600.92ms
|
http_req_duration....................: min=18ms avg=255.3ms max=1.22s p(50)=241.56ms p(95)=479.19ms p(99)=600.92ms
|
||||||
{ expected_response:true }.........: min=18ms avg=255.3ms max=1.22s p(50)=241.56ms p(95)=479.19ms p(99)=600.92ms
|
{ expected_response:true }.........: min=18ms avg=255.3ms max=1.22s p(50)=241.56ms p(95)=479.19ms p(99)=600.92ms
|
||||||
http_req_failed......................: 0.00% ✓ 0 ✗ 347998
|
http_req_failed......................: 0.00% ✓ 0 ✗ 347998
|
||||||
http_req_receiving...................: min=25.92µs avg=536.96µs max=401.94ms p(50)=89.44µs p(95)=2.39ms p(99)=11.12ms
|
http_req_receiving...................: min=25.92µs avg=536.96µs max=401.94ms p(50)=89.44µs p(95)=2.39ms p(99)=11.12ms
|
||||||
http_req_sending.....................: min=24.01µs avg=63.86µs max=4.48ms p(50)=60.97µs p(95)=88.69µs p(99)=141.74µs
|
http_req_sending.....................: min=24.01µs avg=63.86µs max=4.48ms p(50)=60.97µs p(95)=88.69µs p(99)=141.74µs
|
||||||
http_req_tls_handshaking.............: min=0s avg=2.8µs max=51.05ms p(50)=0s p(95)=0s p(99)=0s
|
http_req_tls_handshaking.............: min=0s avg=2.8µs max=51.05ms p(50)=0s p(95)=0s p(99)=0s
|
||||||
http_req_waiting.....................: min=17.65ms avg=254.7ms max=1.22s p(50)=240.88ms p(95)=478.6ms p(99)=600.6ms
|
http_req_waiting.....................: min=17.65ms avg=254.7ms max=1.22s p(50)=240.88ms p(95)=478.6ms p(99)=600.6ms
|
||||||
http_reqs............................: 347998 192.80552/s
|
http_reqs............................: 347998 192.80552/s
|
||||||
iteration_duration...................: min=33.86ms avg=258.77ms max=1.22s p(50)=245ms p(95)=482.61ms p(99)=604.32ms
|
iteration_duration...................: min=33.86ms avg=258.77ms max=1.22s p(50)=245ms p(95)=482.61ms p(99)=604.32ms
|
||||||
iterations...........................: 347788 192.689171/s
|
iterations...........................: 347788 192.689171/s
|
||||||
login_ui_enter_login_name_duration...: min=218.61ms avg=218.61ms max=218.61ms p(50)=218.61ms p(95)=218.61ms p(99)=218.61ms
|
login_ui_enter_login_name_duration...: min=218.61ms avg=218.61ms max=218.61ms p(50)=218.61ms p(95)=218.61ms p(99)=218.61ms
|
||||||
login_ui_enter_password_duration.....: min=18ms avg=18ms max=18ms p(50)=18ms p(95)=18ms p(99)=18ms
|
login_ui_enter_password_duration.....: min=18ms avg=18ms max=18ms p(50)=18ms p(95)=18ms p(99)=18ms
|
||||||
login_ui_init_login_duration.........: min=90.96ms avg=90.96ms max=90.96ms p(50)=90.96ms p(95)=90.96ms p(99)=90.96ms
|
login_ui_init_login_duration.........: min=90.96ms avg=90.96ms max=90.96ms p(50)=90.96ms p(95)=90.96ms p(99)=90.96ms
|
||||||
login_ui_token_duration..............: min=140.02ms avg=140.02ms max=140.02ms p(50)=140.02ms p(95)=140.02ms p(99)=140.02ms
|
login_ui_token_duration..............: min=140.02ms avg=140.02ms max=140.02ms p(50)=140.02ms p(95)=140.02ms p(99)=140.02ms
|
||||||
oidc_token_duration..................: min=29.85ms avg=255.38ms max=1.22s p(50)=241.61ms p(95)=479.23ms p(99)=600.95ms
|
oidc_token_duration..................: min=29.85ms avg=255.38ms max=1.22s p(50)=241.61ms p(95)=479.23ms p(99)=600.95ms
|
||||||
org_create_org_duration..............: min=64.51ms avg=64.51ms max=64.51ms p(50)=64.51ms p(95)=64.51ms p(99)=64.51ms
|
org_create_org_duration..............: min=64.51ms avg=64.51ms max=64.51ms p(50)=64.51ms p(95)=64.51ms p(99)=64.51ms
|
||||||
user_add_machine_key_duration........: min=44.93ms avg=87.89ms max=159.52ms p(50)=84.43ms p(95)=144.59ms p(99)=155.54ms
|
user_add_machine_key_duration........: min=44.93ms avg=87.89ms max=159.52ms p(50)=84.43ms p(95)=144.59ms p(99)=155.54ms
|
||||||
user_create_machine_duration.........: min=65.75ms avg=266.53ms max=421.58ms p(50)=276.59ms p(95)=380.84ms p(99)=414.43ms
|
user_create_machine_duration.........: min=65.75ms avg=266.53ms max=421.58ms p(50)=276.59ms p(95)=380.84ms p(99)=414.43ms
|
||||||
vus..................................: 0 min=0 max=50
|
vus..................................: 0 min=0 max=50
|
||||||
vus_max..............................: 50 min=50 max=50
|
vus_max..............................: 50 min=50 max=50
|
||||||
|
|
||||||
running (30m04.9s), 00/50 VUs, 347788 complete and 0 interrupted iterations
|
running (30m04.9s), 00/50 VUs, 347788 complete and 0 interrupted iterations
|
||||||
default ✓ [======================================] 50 VUs 30m0s
|
default ✓ [======================================] 50 VUs 30m0s
|
||||||
```
|
```
|
||||||
|
|
||||||
+21
-25
@@ -3,6 +3,9 @@ title: machine jwt profile grant benchmark of zitadel v2.66.0
|
|||||||
sidebar_label: machine jwt profile grant
|
sidebar_label: machine jwt profile grant
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
The tests showed heavy database load by time by the first two database queries. These queries need to be analyzed further.
|
The tests showed heavy database load by time by the first two database queries. These queries need to be analyzed further.
|
||||||
|
|
||||||
## Performance test results
|
## Performance test results
|
||||||
@@ -33,14 +36,9 @@ The tests showed heavy database load by time by the first two database queries.
|
|||||||
|
|
||||||
## Endpoint latencies
|
## Endpoint latencies
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
✓ openid configuration
|
✓ openid configuration
|
||||||
✗ token status ok
|
✗ token status ok
|
||||||
@@ -69,34 +67,32 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
|
|
||||||
✓ org removed
|
✓ org removed
|
||||||
|
|
||||||
checks...............................: 99.99% ✓ 1581773 ✗ 10
|
checks...............................: 99.99% ✓ 1581773 ✗ 10
|
||||||
data_received........................: 1.1 GB 623 kB/s
|
data_received........................: 1.1 GB 623 kB/s
|
||||||
data_sent............................: 628 MB 347 kB/s
|
data_sent............................: 628 MB 347 kB/s
|
||||||
http_req_blocked.....................: min=167ns avg=20.68µs max=493.59ms p(50)=468ns p(95)=717ns p(99)=928ns
|
http_req_blocked.....................: min=167ns avg=20.68µs max=493.59ms p(50)=468ns p(95)=717ns p(99)=928ns
|
||||||
http_req_connecting..................: min=0s avg=10.06µs max=388.27ms p(50)=0s p(95)=0s p(99)=0s
|
http_req_connecting..................: min=0s avg=10.06µs max=388.27ms p(50)=0s p(95)=0s p(99)=0s
|
||||||
http_req_duration....................: min=17.71ms avg=337.34ms max=16.27s p(50)=249.03ms p(95)=888.75ms p(99)=1.4s
|
http_req_duration....................: min=17.71ms avg=337.34ms max=16.27s p(50)=249.03ms p(95)=888.75ms p(99)=1.4s
|
||||||
{ expected_response:true }.........: min=17.71ms avg=337.29ms max=3.56s p(50)=249.03ms p(95)=888.7ms p(99)=1.4s
|
{ expected_response:true }.........: min=17.71ms avg=337.29ms max=3.56s p(50)=249.03ms p(95)=888.7ms p(99)=1.4s
|
||||||
http_req_failed......................: 0.00% ✓ 5 ✗ 791265
|
http_req_failed......................: 0.00% ✓ 5 ✗ 791265
|
||||||
http_req_receiving...................: min=25.49µs avg=1.58ms max=539.43ms p(50)=89.69µs p(95)=7.55ms p(99)=23.46ms
|
http_req_receiving...................: min=25.49µs avg=1.58ms max=539.43ms p(50)=89.69µs p(95)=7.55ms p(99)=23.46ms
|
||||||
http_req_sending.....................: min=22.7µs avg=69.14µs max=480.23ms p(50)=59.16µs p(95)=85.15µs p(99)=129.88µs
|
http_req_sending.....................: min=22.7µs avg=69.14µs max=480.23ms p(50)=59.16µs p(95)=85.15µs p(99)=129.88µs
|
||||||
http_req_tls_handshaking.............: min=0s avg=9.38µs max=98.15ms p(50)=0s p(95)=0s p(99)=0s
|
http_req_tls_handshaking.............: min=0s avg=9.38µs max=98.15ms p(50)=0s p(95)=0s p(99)=0s
|
||||||
http_req_waiting.....................: min=15.11ms avg=335.69ms max=16.26s p(50)=246.91ms p(95)=888.27ms p(99)=1.4s
|
http_req_waiting.....................: min=15.11ms avg=335.69ms max=16.26s p(50)=246.91ms p(95)=888.27ms p(99)=1.4s
|
||||||
http_reqs............................: 791270 437.256468/s
|
http_reqs............................: 791270 437.256468/s
|
||||||
iteration_duration...................: min=32.28ms avg=341.46ms max=16.27s p(50)=253ms p(95)=892.49ms p(99)=1.41s
|
iteration_duration...................: min=32.28ms avg=341.46ms max=16.27s p(50)=253ms p(95)=892.49ms p(99)=1.41s
|
||||||
iterations...........................: 790660 436.919382/s
|
iterations...........................: 790660 436.919382/s
|
||||||
login_ui_enter_login_name_duration...: min=179.27ms avg=179.27ms max=179.27ms p(50)=179.27ms p(95)=179.27ms p(99)=179.27ms
|
login_ui_enter_login_name_duration...: min=179.27ms avg=179.27ms max=179.27ms p(50)=179.27ms p(95)=179.27ms p(99)=179.27ms
|
||||||
login_ui_enter_password_duration.....: min=17.71ms avg=17.71ms max=17.71ms p(50)=17.71ms p(95)=17.71ms p(99)=17.71ms
|
login_ui_enter_password_duration.....: min=17.71ms avg=17.71ms max=17.71ms p(50)=17.71ms p(95)=17.71ms p(99)=17.71ms
|
||||||
login_ui_init_login_duration.........: min=77.66ms avg=77.66ms max=77.66ms p(50)=77.66ms p(95)=77.66ms p(99)=77.66ms
|
login_ui_init_login_duration.........: min=77.66ms avg=77.66ms max=77.66ms p(50)=77.66ms p(95)=77.66ms p(99)=77.66ms
|
||||||
login_ui_token_duration..............: min=86.79ms avg=86.79ms max=86.79ms p(50)=86.79ms p(95)=86.79ms p(99)=86.79ms
|
login_ui_token_duration..............: min=86.79ms avg=86.79ms max=86.79ms p(50)=86.79ms p(95)=86.79ms p(99)=86.79ms
|
||||||
oidc_token_duration..................: min=28.38ms avg=337.54ms max=16.27s p(50)=249.17ms p(95)=889.01ms p(99)=1.4s
|
oidc_token_duration..................: min=28.38ms avg=337.54ms max=16.27s p(50)=249.17ms p(95)=889.01ms p(99)=1.4s
|
||||||
org_create_org_duration..............: min=44.94ms avg=44.94ms max=44.94ms p(50)=44.94ms p(95)=44.94ms p(99)=44.94ms
|
org_create_org_duration..............: min=44.94ms avg=44.94ms max=44.94ms p(50)=44.94ms p(95)=44.94ms p(99)=44.94ms
|
||||||
user_add_machine_key_duration........: min=38.11ms avg=66.64ms max=160.59ms p(50)=60.28ms p(95)=104.99ms p(99)=112.5ms
|
user_add_machine_key_duration........: min=38.11ms avg=66.64ms max=160.59ms p(50)=60.28ms p(95)=104.99ms p(99)=112.5ms
|
||||||
user_create_machine_duration.........: min=37.12ms avg=122.76ms max=1.03s p(50)=78.25ms p(95)=266.95ms p(99)=306.94ms
|
user_create_machine_duration.........: min=37.12ms avg=122.76ms max=1.03s p(50)=78.25ms p(95)=266.95ms p(99)=306.94ms
|
||||||
vus..................................: 150 min=0 max=150
|
vus..................................: 150 min=0 max=150
|
||||||
vus_max..............................: 150 min=150 max=150
|
vus_max..............................: 150 min=150 max=150
|
||||||
|
|
||||||
|
|
||||||
running (30m09.6s), 000/150 VUs, 790660 complete and 0 interrupted iterations
|
running (30m09.6s), 000/150 VUs, 790660 complete and 0 interrupted iterations
|
||||||
default ✓ [======================================] 150 VUs 30m0s
|
default ✓ [======================================] 150 VUs 30m0s
|
||||||
```
|
```
|
||||||
|
|
||||||
+17
-21
@@ -3,6 +3,9 @@ title: machine jwt profile grant benchmark of zitadel v2.70.0
|
|||||||
sidebar_label: machine jwt profile grant
|
sidebar_label: machine jwt profile grant
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
The performance goals of [this issue](https://github.com/zitadel/zitadel/issues/8352) are reached. Next we will test linear scalability.
|
The performance goals of [this issue](https://github.com/zitadel/zitadel/issues/8352) are reached. Next we will test linear scalability.
|
||||||
|
|
||||||
## Performance test results
|
## Performance test results
|
||||||
@@ -33,14 +36,9 @@ The performance goals of [this issue](https://github.com/zitadel/zitadel/issues/
|
|||||||
|
|
||||||
## Endpoint latencies
|
## Endpoint latencies
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
✓ openid configuration
|
✓ openid configuration
|
||||||
✗ token status ok
|
✗ token status ok
|
||||||
@@ -72,31 +70,29 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
checks...............................: 99.99% 6580931 out of 6580941
|
checks...............................: 99.99% 6580931 out of 6580941
|
||||||
data_received........................: 4.8 GB 2.6 MB/s
|
data_received........................: 4.8 GB 2.6 MB/s
|
||||||
data_sent............................: 2.8 GB 1.5 MB/s
|
data_sent............................: 2.8 GB 1.5 MB/s
|
||||||
http_req_blocked.....................: min=110ns avg=53.66µs max=937.62ms p(50)=420ns p(95)=660ns p(99)=989ns
|
http_req_blocked.....................: min=110ns avg=53.66µs max=937.62ms p(50)=420ns p(95)=660ns p(99)=989ns
|
||||||
http_req_connecting..................: min=0s avg=22.26µs max=532.7ms p(50)=0s p(95)=0s p(99)=0s
|
http_req_connecting..................: min=0s avg=22.26µs max=532.7ms p(50)=0s p(95)=0s p(99)=0s
|
||||||
http_req_duration....................: min=16.42ms avg=323.71ms max=3.4s p(50)=209.85ms p(95)=903.86ms p(99)=1.01s
|
http_req_duration....................: min=16.42ms avg=323.71ms max=3.4s p(50)=209.85ms p(95)=903.86ms p(99)=1.01s
|
||||||
{ expected_response:true }.........: min=16.42ms avg=323.71ms max=3.4s p(50)=209.85ms p(95)=903.85ms p(99)=1.01s
|
{ expected_response:true }.........: min=16.42ms avg=323.71ms max=3.4s p(50)=209.85ms p(95)=903.85ms p(99)=1.01s
|
||||||
http_req_failed......................: 0.00% 5 out of 3291974
|
http_req_failed......................: 0.00% 5 out of 3291974
|
||||||
http_req_receiving...................: min=18.23µs avg=1.73ms max=913.21ms p(50)=73.15µs p(95)=8.73ms p(99)=29.35ms
|
http_req_receiving...................: min=18.23µs avg=1.73ms max=913.21ms p(50)=73.15µs p(95)=8.73ms p(99)=29.35ms
|
||||||
http_req_sending.....................: min=17.54µs avg=53.13µs max=501.66ms p(50)=46.07µs p(95)=75.92µs p(99)=120.24µs
|
http_req_sending.....................: min=17.54µs avg=53.13µs max=501.66ms p(50)=46.07µs p(95)=75.92µs p(99)=120.24µs
|
||||||
http_req_tls_handshaking.............: min=0s avg=29.45µs max=657.29ms p(50)=0s p(95)=0s p(99)=0s
|
http_req_tls_handshaking.............: min=0s avg=29.45µs max=657.29ms p(50)=0s p(95)=0s p(99)=0s
|
||||||
http_req_waiting.....................: min=3.84ms avg=321.92ms max=3.4s p(50)=206.45ms p(95)=901.97ms p(99)=1.01s
|
http_req_waiting.....................: min=3.84ms avg=321.92ms max=3.4s p(50)=206.45ms p(95)=901.97ms p(99)=1.01s
|
||||||
http_reqs............................: 3291974 1807.469453/s
|
http_reqs............................: 3291974 1807.469453/s
|
||||||
iteration_duration...................: min=18.62ms avg=328.21ms max=3.41s p(50)=215.77ms p(95)=907.48ms p(99)=1.01s
|
iteration_duration...................: min=18.62ms avg=328.21ms max=3.41s p(50)=215.77ms p(95)=907.48ms p(99)=1.01s
|
||||||
iterations...........................: 3289564 1806.146234/s
|
iterations...........................: 3289564 1806.146234/s
|
||||||
login_ui_enter_login_name_duration...: min=131.65ms avg=131.65ms max=131.65ms p(50)=131.65ms p(95)=131.65ms p(99)=131.65ms
|
login_ui_enter_login_name_duration...: min=131.65ms avg=131.65ms max=131.65ms p(50)=131.65ms p(95)=131.65ms p(99)=131.65ms
|
||||||
login_ui_enter_password_duration.....: min=18.55ms avg=18.55ms max=18.55ms p(50)=18.55ms p(95)=18.55ms p(99)=18.55ms
|
login_ui_enter_password_duration.....: min=18.55ms avg=18.55ms max=18.55ms p(50)=18.55ms p(95)=18.55ms p(99)=18.55ms
|
||||||
login_ui_init_login_duration.........: min=68.72ms avg=68.72ms max=68.72ms p(50)=68.72ms p(95)=68.72ms p(99)=68.72ms
|
login_ui_init_login_duration.........: min=68.72ms avg=68.72ms max=68.72ms p(50)=68.72ms p(95)=68.72ms p(99)=68.72ms
|
||||||
login_ui_token_duration..............: min=77.56ms avg=77.56ms max=77.56ms p(50)=77.56ms p(95)=77.56ms p(99)=77.56ms
|
login_ui_token_duration..............: min=77.56ms avg=77.56ms max=77.56ms p(50)=77.56ms p(95)=77.56ms p(99)=77.56ms
|
||||||
oidc_token_duration..................: min=16.42ms avg=323.79ms max=3.4s p(50)=209.87ms p(95)=903.91ms p(99)=1.01s
|
oidc_token_duration..................: min=16.42ms avg=323.79ms max=3.4s p(50)=209.87ms p(95)=903.91ms p(99)=1.01s
|
||||||
org_create_org_duration..............: min=38.42ms avg=38.42ms max=38.42ms p(50)=38.42ms p(95)=38.42ms p(99)=38.42ms
|
org_create_org_duration..............: min=38.42ms avg=38.42ms max=38.42ms p(50)=38.42ms p(95)=38.42ms p(99)=38.42ms
|
||||||
user_add_machine_key_duration........: min=23.47ms avg=280.32ms max=851.94ms p(50)=304.18ms p(95)=437.53ms p(99)=443.37ms
|
user_add_machine_key_duration........: min=23.47ms avg=280.32ms max=851.94ms p(50)=304.18ms p(95)=437.53ms p(99)=443.37ms
|
||||||
user_create_machine_duration.........: min=63.91ms avg=406.02ms max=663.96ms p(50)=437.61ms p(95)=518.85ms p(99)=521.88ms
|
user_create_machine_duration.........: min=63.91ms avg=406.02ms max=663.96ms p(50)=437.61ms p(95)=518.85ms p(99)=521.88ms
|
||||||
vus..................................: 425 min=0 max=600
|
vus..................................: 425 min=0 max=600
|
||||||
vus_max..............................: 600 min=600 max=600
|
vus_max..............................: 600 min=600 max=600
|
||||||
|
|
||||||
|
|
||||||
running (30m21.3s), 000/600 VUs, 3289564 complete and 0 interrupted iterations
|
running (30m21.3s), 000/600 VUs, 3289564 complete and 0 interrupted iterations
|
||||||
default ✓ [======================================] 600 VUs 30m0s
|
default ✓ [======================================] 600 VUs 30m0s
|
||||||
```
|
```
|
||||||
|
|
||||||
+21
-24
@@ -3,6 +3,9 @@ title: oidc session benchmark of Zitadel v2.70.0
|
|||||||
sidebar_label: oidc session
|
sidebar_label: oidc session
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
The test implements [Support for (OIDC) Standard in a Custom Login UI flow](https://zitadel.com/docs/guides/integrate/login-ui/oidc-standard).
|
The test implements [Support for (OIDC) Standard in a Custom Login UI flow](https://zitadel.com/docs/guides/integrate/login-ui/oidc-standard).
|
||||||
|
|
||||||
The tests showed that querying the user takes too much time because Zitadel ensures the projection is up to date. This performance bottleneck must be resolved.
|
The tests showed that querying the user takes too much time because Zitadel ensures the projection is up to date. This performance bottleneck must be resolved.
|
||||||
@@ -35,14 +38,9 @@ The tests showed that querying the user takes too much time because Zitadel ensu
|
|||||||
|
|
||||||
## Endpoint latencies
|
## Endpoint latencies
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
✓ authorize status ok
|
✓ authorize status ok
|
||||||
✓ auth request id returned
|
✓ auth request id returned
|
||||||
@@ -76,34 +74,33 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
checks...............................: 100.00% 1097103 out of 1097103
|
checks...............................: 100.00% 1097103 out of 1097103
|
||||||
data_received........................: 482 MB 267 kB/s
|
data_received........................: 482 MB 267 kB/s
|
||||||
data_sent............................: 206 MB 114 kB/s
|
data_sent............................: 206 MB 114 kB/s
|
||||||
http_req_blocked.....................: min=150ns avg=185.63µs max=639.06ms p(50)=360ns p(95)=790ns p(99)=1.11µs
|
http_req_blocked.....................: min=150ns avg=185.63µs max=639.06ms p(50)=360ns p(95)=790ns p(99)=1.11µs
|
||||||
http_req_connecting..................: min=0s avg=76.84µs max=394.03ms p(50)=0s p(95)=0s p(99)=0s
|
http_req_connecting..................: min=0s avg=76.84µs max=394.03ms p(50)=0s p(95)=0s p(99)=0s
|
||||||
http_req_duration....................: min=2.27ms avg=1.31s max=6.57s p(50)=326.44ms p(95)=3.94s p(99)=4.28s
|
http_req_duration....................: min=2.27ms avg=1.31s max=6.57s p(50)=326.44ms p(95)=3.94s p(99)=4.28s
|
||||||
{ expected_response:true }.........: min=2.27ms avg=1.31s max=6.57s p(50)=326.44ms p(95)=3.94s p(99)=4.28s
|
{ expected_response:true }.........: min=2.27ms avg=1.31s max=6.57s p(50)=326.44ms p(95)=3.94s p(99)=4.28s
|
||||||
http_req_failed......................: 0.00% 0 out of 823429
|
http_req_failed......................: 0.00% 0 out of 823429
|
||||||
http_req_receiving...................: min=22.92µs avg=143.73µs max=245.98ms p(50)=105.17µs p(95)=188.26µs p(99)=260.56µs
|
http_req_receiving...................: min=22.92µs avg=143.73µs max=245.98ms p(50)=105.17µs p(95)=188.26µs p(99)=260.56µs
|
||||||
http_req_sending.....................: min=22.37µs avg=67.8µs max=41.57ms p(50)=63.65µs p(95)=104.8µs p(99)=138.46µs
|
http_req_sending.....................: min=22.37µs avg=67.8µs max=41.57ms p(50)=63.65µs p(95)=104.8µs p(99)=138.46µs
|
||||||
http_req_tls_handshaking.............: min=0s avg=106.12µs max=580.5ms p(50)=0s p(95)=0s p(99)=0s
|
http_req_tls_handshaking.............: min=0s avg=106.12µs max=580.5ms p(50)=0s p(95)=0s p(99)=0s
|
||||||
http_req_waiting.....................: min=2.11ms avg=1.31s max=6.57s p(50)=326.17ms p(95)=3.94s p(99)=4.28s
|
http_req_waiting.....................: min=2.11ms avg=1.31s max=6.57s p(50)=326.17ms p(95)=3.94s p(99)=4.28s
|
||||||
http_reqs............................: 823429 456.440453/s
|
http_reqs............................: 823429 456.440453/s
|
||||||
iteration_duration...................: min=713.37ms avg=3.94s max=8.94s p(50)=3.92s p(95)=4.98s p(99)=5.44s
|
iteration_duration...................: min=713.37ms avg=3.94s max=8.94s p(50)=3.92s p(95)=4.98s p(99)=5.44s
|
||||||
iterations...........................: 274271 152.032998/s
|
iterations...........................: 274271 152.032998/s
|
||||||
login_ui_enter_login_name_duration...: min=113.75ms avg=113.75ms max=113.75ms p(50)=113.75ms p(95)=113.75ms p(99)=113.75ms
|
login_ui_enter_login_name_duration...: min=113.75ms avg=113.75ms max=113.75ms p(50)=113.75ms p(95)=113.75ms p(99)=113.75ms
|
||||||
login_ui_enter_password_duration.....: min=2.27ms avg=2.27ms max=2.27ms p(50)=2.27ms p(95)=2.27ms p(99)=2.27ms
|
login_ui_enter_password_duration.....: min=2.27ms avg=2.27ms max=2.27ms p(50)=2.27ms p(95)=2.27ms p(99)=2.27ms
|
||||||
login_ui_init_login_duration.........: min=20.48ms avg=156.67ms max=6.57s p(50)=126.64ms p(95)=280.16ms p(99)=675.36ms
|
login_ui_init_login_duration.........: min=20.48ms avg=156.67ms max=6.57s p(50)=126.64ms p(95)=280.16ms p(99)=675.36ms
|
||||||
login_ui_token_duration..............: min=68.53ms avg=68.53ms max=68.53ms p(50)=68.53ms p(95)=68.53ms p(99)=68.53ms
|
login_ui_token_duration..............: min=68.53ms avg=68.53ms max=68.53ms p(50)=68.53ms p(95)=68.53ms p(99)=68.53ms
|
||||||
membership_iam_member................: min=34.16ms avg=34.16ms max=34.16ms p(50)=34.16ms p(95)=34.16ms p(99)=34.16ms
|
membership_iam_member................: min=34.16ms avg=34.16ms max=34.16ms p(50)=34.16ms p(95)=34.16ms p(99)=34.16ms
|
||||||
oidc_auth_requst_by_id_duration......: min=20.59ms avg=370.56ms max=2.87s p(50)=294.12ms p(95)=911.42ms p(99)=1.08s
|
oidc_auth_requst_by_id_duration......: min=20.59ms avg=370.56ms max=2.87s p(50)=294.12ms p(95)=911.42ms p(99)=1.08s
|
||||||
oidc_session_duration................: min=713ms avg=3.94s max=8.94s p(50)=3.92s p(95)=4.98s p(99)=5.44s
|
oidc_session_duration................: min=713ms avg=3.94s max=8.94s p(50)=3.92s p(95)=4.98s p(99)=5.44s
|
||||||
oidc_token_duration..................: min=40.67ms avg=40.67ms max=40.67ms p(50)=40.67ms p(95)=40.67ms p(99)=40.67ms
|
oidc_token_duration..................: min=40.67ms avg=40.67ms max=40.67ms p(50)=40.67ms p(95)=40.67ms p(99)=40.67ms
|
||||||
org_create_org_duration..............: min=48.92ms avg=48.92ms max=48.92ms p(50)=48.92ms p(95)=48.92ms p(99)=48.92ms
|
org_create_org_duration..............: min=48.92ms avg=48.92ms max=48.92ms p(50)=48.92ms p(95)=48.92ms p(99)=48.92ms
|
||||||
session_add_session_duration.........: min=92.04ms avg=3.4s max=6.16s p(50)=3.46s p(95)=4.18s p(99)=4.48s
|
session_add_session_duration.........: min=92.04ms avg=3.4s max=6.16s p(50)=3.46s p(95)=4.18s p(99)=4.48s
|
||||||
user_add_machine_key_duration........: min=32.08ms avg=32.08ms max=32.08ms p(50)=32.08ms p(95)=32.08ms p(99)=32.08ms
|
user_add_machine_key_duration........: min=32.08ms avg=32.08ms max=32.08ms p(50)=32.08ms p(95)=32.08ms p(99)=32.08ms
|
||||||
user_create_machine_duration.........: min=91.73ms avg=91.73ms max=91.73ms p(50)=91.73ms p(95)=91.73ms p(99)=91.73ms
|
user_create_machine_duration.........: min=91.73ms avg=91.73ms max=91.73ms p(50)=91.73ms p(95)=91.73ms p(99)=91.73ms
|
||||||
vus..................................: 82 min=0 max=600
|
vus..................................: 82 min=0 max=600
|
||||||
vus_max..............................: 600 min=600 max=600
|
vus_max..............................: 600 min=600 max=600
|
||||||
|
|
||||||
|
|
||||||
running (30m04.0s), 000/600 VUs, 274271 complete and 0 interrupted iterations
|
running (30m04.0s), 000/600 VUs, 274271 complete and 0 interrupted iterations
|
||||||
default ✓ [======================================] 600 VUs 30m0s
|
default ✓ [======================================] 600 VUs 30m0s
|
||||||
```
|
```
|
||||||
+14
-17
@@ -3,6 +3,9 @@ title: create session benchmark of zitadel v4
|
|||||||
sidebar_label: create session
|
sidebar_label: create session
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
Benchmark results of v4 release of Zitadel.
|
Benchmark results of v4 release of Zitadel.
|
||||||
|
|
||||||
## Performance test results
|
## Performance test results
|
||||||
@@ -35,16 +38,11 @@ Benchmark results of v4 release of Zitadel.
|
|||||||
|
|
||||||
Until :37 were containers starting because it was a cold start test.
|
Until :37 were containers starting because it was a cold start test.
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
█ TOTAL RESULTS
|
█ TOTAL RESULTS
|
||||||
|
|
||||||
checks_total.......................: 2244565 1213.769815/s
|
checks_total.......................: 2244565 1213.769815/s
|
||||||
checks_succeeded...................: 99.99% 2244563 out of 2244565
|
checks_succeeded...................: 99.99% 2244563 out of 2244565
|
||||||
@@ -69,23 +67,23 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
✓ org removed
|
✓ org removed
|
||||||
|
|
||||||
CUSTOM
|
CUSTOM
|
||||||
add_session_duration....................................................: min=236ms avg=962.51ms max=3.66s p(50)=951ms p(95)=1.33s p(99)=1.55s
|
add_session_duration....................................................: min=236ms avg=962.51ms max=3.66s p(50)=951ms p(95)=1.33s p(99)=1.55s
|
||||||
login_ui_enter_login_name_duration......................................: min=184.04ms avg=184.04ms max=184.04ms p(50)=184.04ms p(95)=184.04ms p(99)=184.04ms
|
login_ui_enter_login_name_duration......................................: min=184.04ms avg=184.04ms max=184.04ms p(50)=184.04ms p(95)=184.04ms p(99)=184.04ms
|
||||||
login_ui_enter_password_duration........................................: min=15.68ms avg=15.68ms max=15.68ms p(50)=15.68ms p(95)=15.68ms p(99)=15.68ms
|
login_ui_enter_password_duration........................................: min=15.68ms avg=15.68ms max=15.68ms p(50)=15.68ms p(95)=15.68ms p(99)=15.68ms
|
||||||
login_ui_init_login_duration............................................: min=128.36ms avg=128.36ms max=128.36ms p(50)=128.36ms p(95)=128.36ms p(99)=128.36ms
|
login_ui_init_login_duration............................................: min=128.36ms avg=128.36ms max=128.36ms p(50)=128.36ms p(95)=128.36ms p(99)=128.36ms
|
||||||
login_ui_token_duration.................................................: min=87.2ms avg=87.2ms max=87.2ms p(50)=87.2ms p(95)=87.2ms p(99)=87.2ms
|
login_ui_token_duration.................................................: min=87.2ms avg=87.2ms max=87.2ms p(50)=87.2ms p(95)=87.2ms p(99)=87.2ms
|
||||||
org_create_org_duration.................................................: min=76.73ms avg=76.73ms max=76.73ms p(50)=76.73ms p(95)=76.73ms p(99)=76.73ms
|
org_create_org_duration.................................................: min=76.73ms avg=76.73ms max=76.73ms p(50)=76.73ms p(95)=76.73ms p(99)=76.73ms
|
||||||
session_add_session_duration............................................: min=0s avg=961.43ms max=3.66s p(50)=950.06ms p(95)=1.33s p(99)=1.55s
|
session_add_session_duration............................................: min=0s avg=961.43ms max=3.66s p(50)=950.06ms p(95)=1.33s p(99)=1.55s
|
||||||
user_create_human_duration..............................................: min=548.74ms avg=10.69s max=16.39s p(50)=13.39s p(95)=15.97s p(99)=16.28s
|
user_create_human_duration..............................................: min=548.74ms avg=10.69s max=16.39s p(50)=13.39s p(95)=15.97s p(99)=16.28s
|
||||||
|
|
||||||
HTTP
|
HTTP
|
||||||
http_req_duration.......................................................: min=0s avg=966.15ms max=18.87s p(50)=950.04ms p(95)=1.33s p(99)=1.55s
|
http_req_duration.......................................................: min=0s avg=966.15ms max=18.87s p(50)=950.04ms p(95)=1.33s p(99)=1.55s
|
||||||
{ expected_response:true }............................................: min=15.68ms avg=966.15ms max=18.87s p(50)=950.04ms p(95)=1.33s p(99)=1.55s
|
{ expected_response:true }............................................: min=15.68ms avg=966.15ms max=18.87s p(50)=950.04ms p(95)=1.33s p(99)=1.55s
|
||||||
http_req_failed.........................................................: 0.00% 2 out of 1123187
|
http_req_failed.........................................................: 0.00% 2 out of 1123187
|
||||||
http_reqs...............................................................: 1123187 607.374025/s
|
http_reqs...............................................................: 1123187 607.374025/s
|
||||||
|
|
||||||
EXECUTION
|
EXECUTION
|
||||||
iteration_duration......................................................: min=1.63ms avg=962.61ms max=3.66s p(50)=951.17ms p(95)=1.33s p(99)=1.55s
|
iteration_duration......................................................: min=1.63ms avg=962.61ms max=3.66s p(50)=951.17ms p(95)=1.33s p(99)=1.55s
|
||||||
iterations..............................................................: 1121977 606.719706/s
|
iterations..............................................................: 1121977 606.719706/s
|
||||||
vus.....................................................................: 0 min=0 max=600
|
vus.....................................................................: 0 min=0 max=600
|
||||||
vus_max.................................................................: 600 min=600 max=600
|
vus_max.................................................................: 600 min=600 max=600
|
||||||
@@ -97,4 +95,3 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
running (30m49.3s), 000/600 VUs, 1121977 complete and 0 interrupted iterations
|
running (30m49.3s), 000/600 VUs, 1121977 complete and 0 interrupted iterations
|
||||||
default ✓ [======================================] 600 VUs 30m0s
|
default ✓ [======================================] 600 VUs 30m0s
|
||||||
```
|
```
|
||||||
|
|
||||||
+15
-18
@@ -3,6 +3,9 @@ title: human password login benchmark of zitadel v4
|
|||||||
sidebar_label: human password login
|
sidebar_label: human password login
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
Benchmark results of v4 release of Zitadel.
|
Benchmark results of v4 release of Zitadel.
|
||||||
|
|
||||||
This benchmark tests the flow of a user signing in to Zitadel using username and password which is a highly CPU intensive task for checking the password.
|
This benchmark tests the flow of a user signing in to Zitadel using username and password which is a highly CPU intensive task for checking the password.
|
||||||
@@ -37,16 +40,11 @@ This benchmark tests the flow of a user signing in to Zitadel using username and
|
|||||||
|
|
||||||
Until :45 were containers starting because it was a cold start test.
|
Until :45 were containers starting because it was a cold start test.
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
█ TOTAL RESULTS
|
█ TOTAL RESULTS
|
||||||
|
|
||||||
checks_total.......................: 867495 464.541713/s
|
checks_total.......................: 867495 464.541713/s
|
||||||
checks_succeeded...................: 99.88% 866490 out of 867495
|
checks_succeeded...................: 99.88% 866490 out of 867495
|
||||||
@@ -77,23 +75,23 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
✓ org removed
|
✓ org removed
|
||||||
|
|
||||||
CUSTOM
|
CUSTOM
|
||||||
human_password_login_duration...........................................: min=984ms avg=14.73s max=58.88s p(50)=12.41s p(95)=36.8s p(99)=40.55s
|
human_password_login_duration...........................................: min=984ms avg=14.73s max=58.88s p(50)=12.41s p(95)=36.8s p(99)=40.55s
|
||||||
login_ui_enter_login_name_duration......................................: min=98.28ms avg=10.57s max=38.72s p(50)=5.99s p(95)=32.4s p(99)=36.16s
|
login_ui_enter_login_name_duration......................................: min=98.28ms avg=10.57s max=38.72s p(50)=5.99s p(95)=32.4s p(99)=36.16s
|
||||||
login_ui_enter_password_duration........................................: min=1.12ms avg=119.12ms max=1m0s p(50)=2.15ms p(95)=3.96ms p(99)=3.8s
|
login_ui_enter_password_duration........................................: min=1.12ms avg=119.12ms max=1m0s p(50)=2.15ms p(95)=3.96ms p(99)=3.8s
|
||||||
login_ui_init_login_duration............................................: min=41.73ms avg=600.61ms max=22.51s p(50)=292.69ms p(95)=1.84s p(99)=2.82s
|
login_ui_init_login_duration............................................: min=41.73ms avg=600.61ms max=22.51s p(50)=292.69ms p(95)=1.84s p(99)=2.82s
|
||||||
login_ui_token_duration.................................................: min=53.03ms avg=712.39ms max=21.76s p(50)=339.01ms p(95)=2.11s p(99)=3.32s
|
login_ui_token_duration.................................................: min=53.03ms avg=712.39ms max=21.76s p(50)=339.01ms p(95)=2.11s p(99)=3.32s
|
||||||
oidc_user_info_duration.................................................: min=14.54ms avg=187.13ms max=21.51s p(50)=74.47ms p(95)=398.78ms p(99)=619.27ms
|
oidc_user_info_duration.................................................: min=14.54ms avg=187.13ms max=21.51s p(50)=74.47ms p(95)=398.78ms p(99)=619.27ms
|
||||||
org_create_org_duration.................................................: min=50.09ms avg=50.09ms max=50.09ms p(50)=50.09ms p(95)=50.09ms p(99)=50.09ms
|
org_create_org_duration.................................................: min=50.09ms avg=50.09ms max=50.09ms p(50)=50.09ms p(95)=50.09ms p(99)=50.09ms
|
||||||
user_create_human_duration..............................................: min=425.26ms avg=11.83s max=16.89s p(50)=13.67s p(95)=16.07s p(99)=16.78s
|
user_create_human_duration..............................................: min=425.26ms avg=11.83s max=16.89s p(50)=13.67s p(95)=16.07s p(99)=16.78s
|
||||||
|
|
||||||
HTTP
|
HTTP
|
||||||
http_req_duration.......................................................: min=1.12ms avg=1.87s max=1m0s p(50)=257.41ms p(95)=12.28s p(99)=31.18s
|
http_req_duration.......................................................: min=1.12ms avg=1.87s max=1m0s p(50)=257.41ms p(95)=12.28s p(99)=31.18s
|
||||||
{ expected_response:true }............................................: min=1.12ms avg=1.84s max=38.72s p(50)=256.14ms p(95)=11.83s p(99)=31.19s
|
{ expected_response:true }............................................: min=1.12ms avg=1.84s max=38.72s p(50)=256.14ms p(95)=11.83s p(99)=31.19s
|
||||||
http_req_failed.........................................................: 0.19% 1117 out of 581385
|
http_req_failed.........................................................: 0.19% 1117 out of 581385
|
||||||
http_reqs...............................................................: 581385 311.330421/s
|
http_reqs...............................................................: 581385 311.330421/s
|
||||||
|
|
||||||
EXECUTION
|
EXECUTION
|
||||||
iteration_duration......................................................: min=983.33ms avg=14.88s max=1m11s p(50)=12.64s p(95)=36.85s p(99)=40.62s
|
iteration_duration......................................................: min=983.33ms avg=14.88s max=1m11s p(50)=12.64s p(95)=36.85s p(99)=40.62s
|
||||||
iterations..............................................................: 72904 39.039936/s
|
iterations..............................................................: 72904 39.039936/s
|
||||||
vus.....................................................................: 18 min=0 max=600
|
vus.....................................................................: 18 min=0 max=600
|
||||||
vus_max.................................................................: 600 min=600 max=600
|
vus_max.................................................................: 600 min=600 max=600
|
||||||
@@ -104,4 +102,3 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
|
|
||||||
running (31m07.4s), 000/600 VUs, 72904 complete and 0 interrupted iterations
|
running (31m07.4s), 000/600 VUs, 72904 complete and 0 interrupted iterations
|
||||||
```
|
```
|
||||||
|
|
||||||
+16
-19
@@ -3,6 +3,9 @@ title: introspection benchmark of zitadel v4
|
|||||||
sidebar_label: introspection
|
sidebar_label: introspection
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
Benchmark results of v4 release of Zitadel.
|
Benchmark results of v4 release of Zitadel.
|
||||||
|
|
||||||
## Performance test results
|
## Performance test results
|
||||||
@@ -33,16 +36,11 @@ Benchmark results of v4 release of Zitadel.
|
|||||||
|
|
||||||
## Endpoint latencies
|
## Endpoint latencies
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
█ TOTAL RESULTS
|
█ TOTAL RESULTS
|
||||||
|
|
||||||
checks_total.......................: 36207 19.664102/s
|
checks_total.......................: 36207 19.664102/s
|
||||||
checks_succeeded...................: 99.99% 36205 out of 36207
|
checks_succeeded...................: 99.99% 36205 out of 36207
|
||||||
@@ -69,24 +67,24 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
✓ org removed
|
✓ org removed
|
||||||
|
|
||||||
CUSTOM
|
CUSTOM
|
||||||
app_add_app_duration....................................................: min=32.73ms avg=779.27ms max=1.11s p(50)=771.76ms p(95)=1.08s p(99)=1.1s
|
app_add_app_duration....................................................: min=32.73ms avg=779.27ms max=1.11s p(50)=771.76ms p(95)=1.08s p(99)=1.1s
|
||||||
app_add_app_key_duration................................................: min=340.78ms avg=12.14s max=17.19s p(50)=13.51s p(95)=16.78s p(99)=16.93s
|
app_add_app_key_duration................................................: min=340.78ms avg=12.14s max=17.19s p(50)=13.51s p(95)=16.78s p(99)=16.93s
|
||||||
login_ui_enter_login_name_duration......................................: min=212.91ms avg=212.91ms max=212.91ms p(50)=212.91ms p(95)=212.91ms p(99)=212.91ms
|
login_ui_enter_login_name_duration......................................: min=212.91ms avg=212.91ms max=212.91ms p(50)=212.91ms p(95)=212.91ms p(99)=212.91ms
|
||||||
login_ui_enter_password_duration........................................: min=29.53ms avg=29.53ms max=29.53ms p(50)=29.53ms p(95)=29.53ms p(99)=29.53ms
|
login_ui_enter_password_duration........................................: min=29.53ms avg=29.53ms max=29.53ms p(50)=29.53ms p(95)=29.53ms p(99)=29.53ms
|
||||||
login_ui_init_login_duration............................................: min=65.24ms avg=65.24ms max=65.24ms p(50)=65.24ms p(95)=65.24ms p(99)=65.24ms
|
login_ui_init_login_duration............................................: min=65.24ms avg=65.24ms max=65.24ms p(50)=65.24ms p(95)=65.24ms p(99)=65.24ms
|
||||||
login_ui_token_duration.................................................: min=98.54ms avg=98.54ms max=98.54ms p(50)=98.54ms p(95)=98.54ms p(99)=98.54ms
|
login_ui_token_duration.................................................: min=98.54ms avg=98.54ms max=98.54ms p(50)=98.54ms p(95)=98.54ms p(99)=98.54ms
|
||||||
oidc_introspect_duration................................................: min=731.31µs avg=32.04s max=50.94s p(50)=28.25s p(95)=47.83s p(99)=49.39s
|
oidc_introspect_duration................................................: min=731.31µs avg=32.04s max=50.94s p(50)=28.25s p(95)=47.83s p(99)=49.39s
|
||||||
org_create_org_duration.................................................: min=51.76ms avg=51.76ms max=51.76ms p(50)=51.76ms p(95)=51.76ms p(99)=51.76ms
|
org_create_org_duration.................................................: min=51.76ms avg=51.76ms max=51.76ms p(50)=51.76ms p(95)=51.76ms p(99)=51.76ms
|
||||||
project_add_project_duration............................................: min=52.11ms avg=754.58ms max=1.2s p(50)=778.66ms p(95)=1.14s p(99)=1.19s
|
project_add_project_duration............................................: min=52.11ms avg=754.58ms max=1.2s p(50)=778.66ms p(95)=1.14s p(99)=1.19s
|
||||||
|
|
||||||
HTTP
|
HTTP
|
||||||
http_req_duration.......................................................: min=731.31µs avg=30.22s max=50.94s p(50)=26.12s p(95)=47.74s p(99)=49.35s
|
http_req_duration.......................................................: min=731.31µs avg=30.22s max=50.94s p(50)=26.12s p(95)=47.74s p(99)=49.35s
|
||||||
{ expected_response:true }............................................: min=13.11ms avg=30.22s max=50.94s p(50)=26.12s p(95)=47.74s p(99)=49.35s
|
{ expected_response:true }............................................: min=13.11ms avg=30.22s max=50.94s p(50)=26.12s p(95)=47.74s p(99)=49.35s
|
||||||
http_req_failed.........................................................: 0.00% 2 out of 36204
|
http_req_failed.........................................................: 0.00% 2 out of 36204
|
||||||
http_reqs...............................................................: 36204 19.662473/s
|
http_reqs...............................................................: 36204 19.662473/s
|
||||||
|
|
||||||
EXECUTION
|
EXECUTION
|
||||||
iteration_duration......................................................: min=1.53ms avg=32.14s max=50.94s p(50)=28.25s p(95)=47.83s p(99)=49.39s
|
iteration_duration......................................................: min=1.53ms avg=32.14s max=50.94s p(50)=28.25s p(95)=47.83s p(99)=49.39s
|
||||||
iterations..............................................................: 33794 18.353597/s
|
iterations..............................................................: 33794 18.353597/s
|
||||||
vus.....................................................................: 0 min=0 max=600
|
vus.....................................................................: 0 min=0 max=600
|
||||||
vus_max.................................................................: 600 min=600 max=600
|
vus_max.................................................................: 600 min=600 max=600
|
||||||
@@ -98,4 +96,3 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
running (30m41.3s), 000/600 VUs, 33794 complete and 0 interrupted iterations
|
running (30m41.3s), 000/600 VUs, 33794 complete and 0 interrupted iterations
|
||||||
default ✓ [======================================] 600 VUs 30m0s
|
default ✓ [======================================] 600 VUs 30m0s
|
||||||
```
|
```
|
||||||
|
|
||||||
+14
-17
@@ -3,6 +3,9 @@ title: machine client credentials login benchmark of zitadel v4
|
|||||||
sidebar_label: machine client credentials login
|
sidebar_label: machine client credentials login
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
Benchmark results of v4 release of Zitadel.
|
Benchmark results of v4 release of Zitadel.
|
||||||
|
|
||||||
## Performance test results
|
## Performance test results
|
||||||
@@ -35,17 +38,12 @@ Benchmark results of v4 release of Zitadel.
|
|||||||
|
|
||||||
Until :37 were containers starting because it was a cold start test.
|
Until :37 were containers starting because it was a cold start test.
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
|
||||||
█ TOTAL RESULTS
|
█ TOTAL RESULTS
|
||||||
|
|
||||||
checks_total.......................: 2336254 1274.250394/s
|
checks_total.......................: 2336254 1274.250394/s
|
||||||
checks_succeeded...................: 99.99% 2336250 out of 2336254
|
checks_succeeded...................: 99.99% 2336250 out of 2336254
|
||||||
@@ -75,23 +73,23 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
|
|
||||||
CUSTOM
|
CUSTOM
|
||||||
login_ui_enter_login_name_duration......................................: min=191.97ms avg=191.97ms max=191.97ms p(50)=191.97ms p(95)=191.97ms p(99)=191.97ms
|
login_ui_enter_login_name_duration......................................: min=191.97ms avg=191.97ms max=191.97ms p(50)=191.97ms p(95)=191.97ms p(99)=191.97ms
|
||||||
login_ui_enter_password_duration........................................: min=14.65ms avg=14.65ms max=14.65ms p(50)=14.65ms p(95)=14.65ms p(99)=14.65ms
|
login_ui_enter_password_duration........................................: min=14.65ms avg=14.65ms max=14.65ms p(50)=14.65ms p(95)=14.65ms p(99)=14.65ms
|
||||||
login_ui_init_login_duration............................................: min=91.36ms avg=91.36ms max=91.36ms p(50)=91.36ms p(95)=91.36ms p(99)=91.36ms
|
login_ui_init_login_duration............................................: min=91.36ms avg=91.36ms max=91.36ms p(50)=91.36ms p(95)=91.36ms p(99)=91.36ms
|
||||||
login_ui_token_duration.................................................: min=93.72ms avg=93.72ms max=93.72ms p(50)=93.72ms p(95)=93.72ms p(99)=93.72ms
|
login_ui_token_duration.................................................: min=93.72ms avg=93.72ms max=93.72ms p(50)=93.72ms p(95)=93.72ms p(99)=93.72ms
|
||||||
oidc_client_credentials_duration........................................: min=244.96µs avg=794.35ms max=2.22s p(50)=783.9ms p(95)=1.1s p(99)=1.23s
|
oidc_client_credentials_duration........................................: min=244.96µs avg=794.35ms max=2.22s p(50)=783.9ms p(95)=1.1s p(99)=1.23s
|
||||||
oidc_user_info_duration.................................................: min=578.67µs avg=592.86ms max=1.98s p(50)=583.33ms p(95)=840.94ms p(99)=939.62ms
|
oidc_user_info_duration.................................................: min=578.67µs avg=592.86ms max=1.98s p(50)=583.33ms p(95)=840.94ms p(99)=939.62ms
|
||||||
org_create_org_duration.................................................: min=60.95ms avg=60.95ms max=60.95ms p(50)=60.95ms p(95)=60.95ms p(99)=60.95ms
|
org_create_org_duration.................................................: min=60.95ms avg=60.95ms max=60.95ms p(50)=60.95ms p(95)=60.95ms p(99)=60.95ms
|
||||||
user_add_machine_secret_duration........................................: min=54.63ms avg=2.62s max=4.92s p(50)=2.67s p(95)=4.69s p(99)=4.87s
|
user_add_machine_secret_duration........................................: min=54.63ms avg=2.62s max=4.92s p(50)=2.67s p(95)=4.69s p(99)=4.87s
|
||||||
user_create_machine_duration............................................: min=159.68ms avg=681.87ms max=868.85ms p(50)=746.38ms p(95)=840.65ms p(99)=859.33ms
|
user_create_machine_duration............................................: min=159.68ms avg=681.87ms max=868.85ms p(50)=746.38ms p(95)=840.65ms p(99)=859.33ms
|
||||||
|
|
||||||
HTTP
|
HTTP
|
||||||
http_req_duration.......................................................: min=244.96µs avg=693.86ms max=4.92s p(50)=671.37ms p(95)=1.05s p(99)=1.18s
|
http_req_duration.......................................................: min=244.96µs avg=693.86ms max=4.92s p(50)=671.37ms p(95)=1.05s p(99)=1.18s
|
||||||
{ expected_response:true }............................................: min=14.27ms avg=693.86ms max=4.92s p(50)=671.37ms p(95)=1.05s p(99)=1.18s
|
{ expected_response:true }............................................: min=14.27ms avg=693.86ms max=4.92s p(50)=671.37ms p(95)=1.05s p(99)=1.18s
|
||||||
http_req_failed.........................................................: 0.00% 4 out of 1558705
|
http_req_failed.........................................................: 0.00% 4 out of 1558705
|
||||||
http_reqs...............................................................: 1558705 850.156045/s
|
http_reqs...............................................................: 1558705 850.156045/s
|
||||||
|
|
||||||
EXECUTION
|
EXECUTION
|
||||||
iteration_duration......................................................: min=656.54µs avg=1.38s max=3.43s p(50)=1.38s p(95)=1.8s p(99)=2.01s
|
iteration_duration......................................................: min=656.54µs avg=1.38s max=3.43s p(50)=1.38s p(95)=1.8s p(99)=2.01s
|
||||||
iterations..............................................................: 778149 424.421604/s
|
iterations..............................................................: 778149 424.421604/s
|
||||||
vus.....................................................................: 292 min=0 max=600
|
vus.....................................................................: 292 min=0 max=600
|
||||||
vus_max.................................................................: 600 min=600 max=600
|
vus_max.................................................................: 600 min=600 max=600
|
||||||
@@ -103,4 +101,3 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
running (30m33.4s), 000/600 VUs, 778149 complete and 0 interrupted iterations
|
running (30m33.4s), 000/600 VUs, 778149 complete and 0 interrupted iterations
|
||||||
default ✓ [======================================] 600 VUs 30m0s
|
default ✓ [======================================] 600 VUs 30m0s
|
||||||
```
|
```
|
||||||
|
|
||||||
+13
-16
@@ -3,6 +3,9 @@ title: machine jwt profile grant benchmark of zitadel v4
|
|||||||
sidebar_label: machine jwt profile grant
|
sidebar_label: machine jwt profile grant
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
Benchmark results of v4 release of Zitadel.
|
Benchmark results of v4 release of Zitadel.
|
||||||
|
|
||||||
## Performance test results
|
## Performance test results
|
||||||
@@ -33,16 +36,11 @@ Benchmark results of v4 release of Zitadel.
|
|||||||
|
|
||||||
## Endpoint latencies
|
## Endpoint latencies
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
█ TOTAL RESULTS
|
█ TOTAL RESULTS
|
||||||
|
|
||||||
checks_total.......................: 3128039 1702.561961/s
|
checks_total.......................: 3128039 1702.561961/s
|
||||||
checks_succeeded...................: 100.00% 3128039 out of 3128039
|
checks_succeeded...................: 100.00% 3128039 out of 3128039
|
||||||
@@ -68,22 +66,22 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
|
|
||||||
CUSTOM
|
CUSTOM
|
||||||
login_ui_enter_login_name_duration......................................: min=185.23ms avg=185.23ms max=185.23ms p(50)=185.23ms p(95)=185.23ms p(99)=185.23ms
|
login_ui_enter_login_name_duration......................................: min=185.23ms avg=185.23ms max=185.23ms p(50)=185.23ms p(95)=185.23ms p(99)=185.23ms
|
||||||
login_ui_enter_password_duration........................................: min=19.29ms avg=19.29ms max=19.29ms p(50)=19.29ms p(95)=19.29ms p(99)=19.29ms
|
login_ui_enter_password_duration........................................: min=19.29ms avg=19.29ms max=19.29ms p(50)=19.29ms p(95)=19.29ms p(99)=19.29ms
|
||||||
login_ui_init_login_duration............................................: min=103.07ms avg=103.07ms max=103.07ms p(50)=103.07ms p(95)=103.07ms p(99)=103.07ms
|
login_ui_init_login_duration............................................: min=103.07ms avg=103.07ms max=103.07ms p(50)=103.07ms p(95)=103.07ms p(99)=103.07ms
|
||||||
login_ui_token_duration.................................................: min=147.4ms avg=147.4ms max=147.4ms p(50)=147.4ms p(95)=147.4ms p(99)=147.4ms
|
login_ui_token_duration.................................................: min=147.4ms avg=147.4ms max=147.4ms p(50)=147.4ms p(95)=147.4ms p(99)=147.4ms
|
||||||
oidc_token_duration.....................................................: min=58.6ms avg=688.05ms max=3.95s p(50)=470.3ms p(95)=1.16s p(99)=1.24s
|
oidc_token_duration.....................................................: min=58.6ms avg=688.05ms max=3.95s p(50)=470.3ms p(95)=1.16s p(99)=1.24s
|
||||||
org_create_org_duration.................................................: min=88.83ms avg=88.83ms max=88.83ms p(50)=88.83ms p(95)=88.83ms p(99)=88.83ms
|
org_create_org_duration.................................................: min=88.83ms avg=88.83ms max=88.83ms p(50)=88.83ms p(95)=88.83ms p(99)=88.83ms
|
||||||
user_add_machine_key_duration...........................................: min=29.55ms avg=481.01ms max=742.31ms p(50)=487.76ms p(95)=728.51ms p(99)=739.94ms
|
user_add_machine_key_duration...........................................: min=29.55ms avg=481.01ms max=742.31ms p(50)=487.76ms p(95)=728.51ms p(99)=739.94ms
|
||||||
user_create_machine_duration............................................: min=88.42ms avg=748.16ms max=4.46s p(50)=732.58ms p(95)=1.01s p(99)=1.03s
|
user_create_machine_duration............................................: min=88.42ms avg=748.16ms max=4.46s p(50)=732.58ms p(95)=1.01s p(99)=1.03s
|
||||||
|
|
||||||
HTTP
|
HTTP
|
||||||
http_req_duration.......................................................: min=19.29ms avg=687.53ms max=4.46s p(50)=470.17ms p(95)=1.16s p(99)=1.24s
|
http_req_duration.......................................................: min=19.29ms avg=687.53ms max=4.46s p(50)=470.17ms p(95)=1.16s p(99)=1.24s
|
||||||
{ expected_response:true }............................................: min=19.29ms avg=687.53ms max=4.46s p(50)=470.17ms p(95)=1.16s p(99)=1.24s
|
{ expected_response:true }............................................: min=19.29ms avg=687.53ms max=4.46s p(50)=470.17ms p(95)=1.16s p(99)=1.24s
|
||||||
http_req_failed.........................................................: 0.00% 0 out of 1565523
|
http_req_failed.........................................................: 0.00% 0 out of 1565523
|
||||||
http_reqs...............................................................: 1565523 852.099321/s
|
http_reqs...............................................................: 1565523 852.099321/s
|
||||||
|
|
||||||
EXECUTION
|
EXECUTION
|
||||||
iteration_duration......................................................: min=61.7ms avg=690.96ms max=3.96s p(50)=473.07ms p(95)=1.16s p(99)=1.25s
|
iteration_duration......................................................: min=61.7ms avg=690.96ms max=3.96s p(50)=473.07ms p(95)=1.16s p(99)=1.25s
|
||||||
iterations..............................................................: 1563113 850.787581/s
|
iterations..............................................................: 1563113 850.787581/s
|
||||||
vus.....................................................................: 1 min=0 max=600
|
vus.....................................................................: 1 min=0 max=600
|
||||||
vus_max.................................................................: 600 min=600 max=600
|
vus_max.................................................................: 600 min=600 max=600
|
||||||
@@ -95,4 +93,3 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
running (30m37.3s), 000/600 VUs, 1563113 complete and 0 interrupted iterations
|
running (30m37.3s), 000/600 VUs, 1563113 complete and 0 interrupted iterations
|
||||||
default ✓ [======================================] 600 VUs 30m0s
|
default ✓ [======================================] 600 VUs 30m0s
|
||||||
```
|
```
|
||||||
|
|
||||||
+15
-18
@@ -3,6 +3,9 @@ title: machine pat login benchmark of zitadel v4
|
|||||||
sidebar_label: machine pat login
|
sidebar_label: machine pat login
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
Benchmark results of v4 release of Zitadel.
|
Benchmark results of v4 release of Zitadel.
|
||||||
|
|
||||||
## Performance test results
|
## Performance test results
|
||||||
@@ -35,16 +38,11 @@ Benchmark results of v4 release of Zitadel.
|
|||||||
|
|
||||||
Until :37 were containers starting because it was a cold start test.
|
Until :37 were containers starting because it was a cold start test.
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
█ TOTAL RESULTS
|
█ TOTAL RESULTS
|
||||||
|
|
||||||
checks_total.......................: 867495 464.541713/s
|
checks_total.......................: 867495 464.541713/s
|
||||||
checks_succeeded...................: 99.88% 866490 out of 867495
|
checks_succeeded...................: 99.88% 866490 out of 867495
|
||||||
@@ -75,23 +73,23 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
✓ org removed
|
✓ org removed
|
||||||
|
|
||||||
CUSTOM
|
CUSTOM
|
||||||
human_password_login_duration...........................................: min=984ms avg=14.73s max=58.88s p(50)=12.41s p(95)=36.8s p(99)=40.55s
|
human_password_login_duration...........................................: min=984ms avg=14.73s max=58.88s p(50)=12.41s p(95)=36.8s p(99)=40.55s
|
||||||
login_ui_enter_login_name_duration......................................: min=98.28ms avg=10.57s max=38.72s p(50)=5.99s p(95)=32.4s p(99)=36.16s
|
login_ui_enter_login_name_duration......................................: min=98.28ms avg=10.57s max=38.72s p(50)=5.99s p(95)=32.4s p(99)=36.16s
|
||||||
login_ui_enter_password_duration........................................: min=1.12ms avg=119.12ms max=1m0s p(50)=2.15ms p(95)=3.96ms p(99)=3.8s
|
login_ui_enter_password_duration........................................: min=1.12ms avg=119.12ms max=1m0s p(50)=2.15ms p(95)=3.96ms p(99)=3.8s
|
||||||
login_ui_init_login_duration............................................: min=41.73ms avg=600.61ms max=22.51s p(50)=292.69ms p(95)=1.84s p(99)=2.82s
|
login_ui_init_login_duration............................................: min=41.73ms avg=600.61ms max=22.51s p(50)=292.69ms p(95)=1.84s p(99)=2.82s
|
||||||
login_ui_token_duration.................................................: min=53.03ms avg=712.39ms max=21.76s p(50)=339.01ms p(95)=2.11s p(99)=3.32s
|
login_ui_token_duration.................................................: min=53.03ms avg=712.39ms max=21.76s p(50)=339.01ms p(95)=2.11s p(99)=3.32s
|
||||||
oidc_user_info_duration.................................................: min=14.54ms avg=187.13ms max=21.51s p(50)=74.47ms p(95)=398.78ms p(99)=619.27ms
|
oidc_user_info_duration.................................................: min=14.54ms avg=187.13ms max=21.51s p(50)=74.47ms p(95)=398.78ms p(99)=619.27ms
|
||||||
org_create_org_duration.................................................: min=50.09ms avg=50.09ms max=50.09ms p(50)=50.09ms p(95)=50.09ms p(99)=50.09ms
|
org_create_org_duration.................................................: min=50.09ms avg=50.09ms max=50.09ms p(50)=50.09ms p(95)=50.09ms p(99)=50.09ms
|
||||||
user_create_human_duration..............................................: min=425.26ms avg=11.83s max=16.89s p(50)=13.67s p(95)=16.07s p(99)=16.78s
|
user_create_human_duration..............................................: min=425.26ms avg=11.83s max=16.89s p(50)=13.67s p(95)=16.07s p(99)=16.78s
|
||||||
|
|
||||||
HTTP
|
HTTP
|
||||||
http_req_duration.......................................................: min=1.12ms avg=1.87s max=1m0s p(50)=257.41ms p(95)=12.28s p(99)=31.18s
|
http_req_duration.......................................................: min=1.12ms avg=1.87s max=1m0s p(50)=257.41ms p(95)=12.28s p(99)=31.18s
|
||||||
{ expected_response:true }............................................: min=1.12ms avg=1.84s max=38.72s p(50)=256.14ms p(95)=11.83s p(99)=31.19s
|
{ expected_response:true }............................................: min=1.12ms avg=1.84s max=38.72s p(50)=256.14ms p(95)=11.83s p(99)=31.19s
|
||||||
http_req_failed.........................................................: 0.19% 1117 out of 581385
|
http_req_failed.........................................................: 0.19% 1117 out of 581385
|
||||||
http_reqs...............................................................: 581385 311.330421/s
|
http_reqs...............................................................: 581385 311.330421/s
|
||||||
|
|
||||||
EXECUTION
|
EXECUTION
|
||||||
iteration_duration......................................................: min=983.33ms avg=14.88s max=1m11s p(50)=12.64s p(95)=36.85s p(99)=40.62s
|
iteration_duration......................................................: min=983.33ms avg=14.88s max=1m11s p(50)=12.64s p(95)=36.85s p(99)=40.62s
|
||||||
iterations..............................................................: 72904 39.039936/s
|
iterations..............................................................: 72904 39.039936/s
|
||||||
vus.....................................................................: 18 min=0 max=600
|
vus.....................................................................: 18 min=0 max=600
|
||||||
vus_max.................................................................: 600 min=600 max=600
|
vus_max.................................................................: 600 min=600 max=600
|
||||||
@@ -102,4 +100,3 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
|
|
||||||
running (31m07.4s), 000/600 VUs, 72904 complete and 0 interrupted iterations
|
running (31m07.4s), 000/600 VUs, 72904 complete and 0 interrupted iterations
|
||||||
```
|
```
|
||||||
|
|
||||||
+15
-18
@@ -3,6 +3,9 @@ title: manipulate user benchmark of zitadel v4
|
|||||||
sidebar_label: manipulate user
|
sidebar_label: manipulate user
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
Benchmark results of v4 release of Zitadel.
|
Benchmark results of v4 release of Zitadel.
|
||||||
|
|
||||||
## Performance test results
|
## Performance test results
|
||||||
@@ -35,16 +38,11 @@ Benchmark results of v4 release of Zitadel.
|
|||||||
|
|
||||||
Each iteration creates, updates and deletes a user.
|
Each iteration creates, updates and deletes a user.
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
█ TOTAL RESULTS
|
█ TOTAL RESULTS
|
||||||
|
|
||||||
checks_total.......................: 199261 108.759178/s
|
checks_total.......................: 199261 108.759178/s
|
||||||
checks_succeeded...................: 57.15% 113882 out of 199261
|
checks_succeeded...................: 57.15% 113882 out of 199261
|
||||||
@@ -73,24 +71,24 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
✓ org removed
|
✓ org removed
|
||||||
|
|
||||||
CUSTOM
|
CUSTOM
|
||||||
delete_user_duration....................................................: min=109.24ms avg=3.48s max=1m0s p(50)=2s p(95)=7.65s p(99)=9.78s
|
delete_user_duration....................................................: min=109.24ms avg=3.48s max=1m0s p(50)=2s p(95)=7.65s p(99)=9.78s
|
||||||
lock_user_duration......................................................: min=77.95ms avg=2.7s max=1m0s p(50)=1.1s p(95)=6.36s p(99)=7.86s
|
lock_user_duration......................................................: min=77.95ms avg=2.7s max=1m0s p(50)=1.1s p(95)=6.36s p(99)=7.86s
|
||||||
login_ui_enter_login_name_duration......................................: min=175.39ms avg=175.39ms max=175.39ms p(50)=175.39ms p(95)=175.39ms p(99)=175.39ms
|
login_ui_enter_login_name_duration......................................: min=175.39ms avg=175.39ms max=175.39ms p(50)=175.39ms p(95)=175.39ms p(99)=175.39ms
|
||||||
login_ui_enter_password_duration........................................: min=34.12ms avg=34.12ms max=34.12ms p(50)=34.12ms p(95)=34.12ms p(99)=34.12ms
|
login_ui_enter_password_duration........................................: min=34.12ms avg=34.12ms max=34.12ms p(50)=34.12ms p(95)=34.12ms p(99)=34.12ms
|
||||||
login_ui_init_login_duration............................................: min=100.5ms avg=100.5ms max=100.5ms p(50)=100.5ms p(95)=100.5ms p(99)=100.5ms
|
login_ui_init_login_duration............................................: min=100.5ms avg=100.5ms max=100.5ms p(50)=100.5ms p(95)=100.5ms p(99)=100.5ms
|
||||||
login_ui_token_duration.................................................: min=154.05ms avg=154.05ms max=154.05ms p(50)=154.05ms p(95)=154.05ms p(99)=154.05ms
|
login_ui_token_duration.................................................: min=154.05ms avg=154.05ms max=154.05ms p(50)=154.05ms p(95)=154.05ms p(99)=154.05ms
|
||||||
org_create_org_duration.................................................: min=71.03ms avg=71.03ms max=71.03ms p(50)=71.03ms p(95)=71.03ms p(99)=71.03ms
|
org_create_org_duration.................................................: min=71.03ms avg=71.03ms max=71.03ms p(50)=71.03ms p(95)=71.03ms p(99)=71.03ms
|
||||||
update_human_duration...................................................: min=70.77ms avg=2.43s max=1m0s p(50)=807.73ms p(95)=5.99s p(99)=7.36s
|
update_human_duration...................................................: min=70.77ms avg=2.43s max=1m0s p(50)=807.73ms p(95)=5.99s p(99)=7.36s
|
||||||
user_create_human_duration..............................................: min=503.01ms avg=3.69s max=1m0s p(50)=2.07s p(95)=7.66s p(99)=13.98s
|
user_create_human_duration..............................................: min=503.01ms avg=3.69s max=1m0s p(50)=2.07s p(95)=7.66s p(99)=13.98s
|
||||||
|
|
||||||
HTTP
|
HTTP
|
||||||
http_req_duration.......................................................: min=34.12ms avg=7.64s max=1m0s p(50)=4.07s p(95)=32.29s p(99)=41.1s
|
http_req_duration.......................................................: min=34.12ms avg=7.64s max=1m0s p(50)=4.07s p(95)=32.29s p(99)=41.1s
|
||||||
{ expected_response:true }............................................: min=34.12ms avg=7.63s max=54.32s p(50)=4.07s p(95)=32.26s p(99)=41.03s
|
{ expected_response:true }............................................: min=34.12ms avg=7.63s max=54.32s p(50)=4.07s p(95)=32.26s p(99)=41.03s
|
||||||
http_req_failed.........................................................: 0.02% 31 out of 142384
|
http_req_failed.........................................................: 0.02% 31 out of 142384
|
||||||
http_reqs...............................................................: 142384 77.714991/s
|
http_reqs...............................................................: 142384 77.714991/s
|
||||||
|
|
||||||
EXECUTION
|
EXECUTION
|
||||||
iteration_duration......................................................: min=17.1s avg=38.22s max=1m30s p(50)=36.76s p(95)=58.22s p(99)=1m7s
|
iteration_duration......................................................: min=17.1s avg=38.22s max=1m30s p(50)=36.76s p(95)=58.22s p(99)=1m7s
|
||||||
iterations..............................................................: 28434 15.519637/s
|
iterations..............................................................: 28434 15.519637/s
|
||||||
vus.....................................................................: 0 min=0 max=600
|
vus.....................................................................: 0 min=0 max=600
|
||||||
vus_max.................................................................: 600 min=600 max=600
|
vus_max.................................................................: 600 min=600 max=600
|
||||||
@@ -102,4 +100,3 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
running (30m32.1s), 000/600 VUs, 28434 complete and 98 interrupted iterations
|
running (30m32.1s), 000/600 VUs, 28434 complete and 98 interrupted iterations
|
||||||
default ✓ [======================================] 600 VUs 30m0s
|
default ✓ [======================================] 600 VUs 30m0s
|
||||||
```
|
```
|
||||||
|
|
||||||
+18
-21
@@ -3,6 +3,9 @@ title: oidc session benchmark of zitadel v4
|
|||||||
sidebar_label: oidc session
|
sidebar_label: oidc session
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
Benchmark results of v4 release of Zitadel.
|
Benchmark results of v4 release of Zitadel.
|
||||||
|
|
||||||
## Performance test results
|
## Performance test results
|
||||||
@@ -33,16 +36,11 @@ Benchmark results of v4 release of Zitadel.
|
|||||||
|
|
||||||
## Endpoint latencies
|
## Endpoint latencies
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
█ TOTAL RESULTS
|
█ TOTAL RESULTS
|
||||||
|
|
||||||
checks_total.......................: 1061560 420.116279/s
|
checks_total.......................: 1061560 420.116279/s
|
||||||
checks_succeeded...................: 99.99% 1061559 out of 1061560
|
checks_succeeded...................: 99.99% 1061559 out of 1061560
|
||||||
@@ -73,26 +71,26 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
|
|
||||||
CUSTOM
|
CUSTOM
|
||||||
login_ui_enter_login_name_duration......................................: min=100.93ms avg=100.93ms max=100.93ms p(50)=100.93ms p(95)=100.93ms p(99)=100.93ms
|
login_ui_enter_login_name_duration......................................: min=100.93ms avg=100.93ms max=100.93ms p(50)=100.93ms p(95)=100.93ms p(99)=100.93ms
|
||||||
login_ui_enter_password_duration........................................: min=4.86ms avg=4.86ms max=4.86ms p(50)=4.86ms p(95)=4.86ms p(99)=4.86ms
|
login_ui_enter_password_duration........................................: min=4.86ms avg=4.86ms max=4.86ms p(50)=4.86ms p(95)=4.86ms p(99)=4.86ms
|
||||||
login_ui_init_login_duration............................................: min=71.62ms avg=497.81ms max=19m45s p(50)=442.5ms p(95)=557.71ms p(99)=642.49ms
|
login_ui_init_login_duration............................................: min=71.62ms avg=497.81ms max=19m45s p(50)=442.5ms p(95)=557.71ms p(99)=642.49ms
|
||||||
login_ui_token_duration.................................................: min=80.88ms avg=80.88ms max=80.88ms p(50)=80.88ms p(95)=80.88ms p(99)=80.88ms
|
login_ui_token_duration.................................................: min=80.88ms avg=80.88ms max=80.88ms p(50)=80.88ms p(95)=80.88ms p(99)=80.88ms
|
||||||
membership_iam_member...................................................: min=65.45ms avg=65.45ms max=65.45ms p(50)=65.45ms p(95)=65.45ms p(99)=65.45ms
|
membership_iam_member...................................................: min=65.45ms avg=65.45ms max=65.45ms p(50)=65.45ms p(95)=65.45ms p(99)=65.45ms
|
||||||
oidc_auth_request_finalize..............................................: min=89.04ms avg=1.32s max=2m8s p(50)=1.26s p(95)=1.62s p(99)=1.78s
|
oidc_auth_request_finalize..............................................: min=89.04ms avg=1.32s max=2m8s p(50)=1.26s p(95)=1.62s p(99)=1.78s
|
||||||
oidc_session_duration...................................................: min=1.73s avg=2.88s max=21m54s p(50)=2.73s p(95)=3.26s p(99)=3.54s
|
oidc_session_duration...................................................: min=1.73s avg=2.88s max=21m54s p(50)=2.73s p(95)=3.26s p(99)=3.54s
|
||||||
oidc_token_duration.....................................................: min=34.16ms avg=34.16ms max=34.16ms p(50)=34.16ms p(95)=34.16ms p(99)=34.16ms
|
oidc_token_duration.....................................................: min=34.16ms avg=34.16ms max=34.16ms p(50)=34.16ms p(95)=34.16ms p(99)=34.16ms
|
||||||
org_create_org_duration.................................................: min=41.58ms avg=41.58ms max=41.58ms p(50)=41.58ms p(95)=41.58ms p(99)=41.58ms
|
org_create_org_duration.................................................: min=41.58ms avg=41.58ms max=41.58ms p(50)=41.58ms p(95)=41.58ms p(99)=41.58ms
|
||||||
session_add_session_duration............................................: min=105.71ms avg=1.06s max=15m9s p(50)=1s p(95)=1.34s p(99)=1.5s
|
session_add_session_duration............................................: min=105.71ms avg=1.06s max=15m9s p(50)=1s p(95)=1.34s p(99)=1.5s
|
||||||
user_add_machine_key_duration...........................................: min=50.3ms avg=50.3ms max=50.3ms p(50)=50.3ms p(95)=50.3ms p(99)=50.3ms
|
user_add_machine_key_duration...........................................: min=50.3ms avg=50.3ms max=50.3ms p(50)=50.3ms p(95)=50.3ms p(99)=50.3ms
|
||||||
user_create_machine_duration............................................: min=32.72ms avg=32.72ms max=32.72ms p(50)=32.72ms p(95)=32.72ms p(99)=32.72ms
|
user_create_machine_duration............................................: min=32.72ms avg=32.72ms max=32.72ms p(50)=32.72ms p(95)=32.72ms p(99)=32.72ms
|
||||||
|
|
||||||
HTTP
|
HTTP
|
||||||
http_req_duration.......................................................: min=4.86ms avg=1.04s max=19m45s p(50)=966.65ms p(95)=1.5s p(99)=1.68s
|
http_req_duration.......................................................: min=4.86ms avg=1.04s max=19m45s p(50)=966.65ms p(95)=1.5s p(99)=1.68s
|
||||||
{ expected_response:true }............................................: min=4.86ms avg=987.51ms max=19m45s p(50)=966.55ms p(95)=1.5s p(99)=1.68s
|
{ expected_response:true }............................................: min=4.86ms avg=987.51ms max=19m45s p(50)=966.55ms p(95)=1.5s p(99)=1.68s
|
||||||
http_req_failed.........................................................: 0.01% 144 out of 796955
|
http_req_failed.........................................................: 0.01% 144 out of 796955
|
||||||
http_reqs...............................................................: 796955 315.397876/s
|
http_reqs...............................................................: 796955 315.397876/s
|
||||||
|
|
||||||
EXECUTION
|
EXECUTION
|
||||||
iteration_duration......................................................: min=1.73s avg=2.88s max=21m55s p(50)=2.73s p(95)=3.26s p(99)=3.54s
|
iteration_duration......................................................: min=1.73s avg=2.88s max=21m55s p(50)=2.73s p(95)=3.26s p(99)=3.54s
|
||||||
iterations..............................................................: 265117 104.921029/s
|
iterations..............................................................: 265117 104.921029/s
|
||||||
vus.....................................................................: 0 min=0 max=600
|
vus.....................................................................: 0 min=0 max=600
|
||||||
vus_max.................................................................: 600 min=600 max=600
|
vus_max.................................................................: 600 min=600 max=600
|
||||||
@@ -104,4 +102,3 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
running (42m06.8s), 000/600 VUs, 265104 complete and 600 interrupted iterations
|
running (42m06.8s), 000/600 VUs, 265104 complete and 600 interrupted iterations
|
||||||
default ✓ [======================================] 600 VUs 30m0s
|
default ✓ [======================================] 600 VUs 30m0s
|
||||||
```
|
```
|
||||||
|
|
||||||
+16
-19
@@ -3,6 +3,9 @@ title: otp session benchmark of zitadel v4
|
|||||||
sidebar_label: otp session
|
sidebar_label: otp session
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
Benchmark results of v4 release of Zitadel.
|
Benchmark results of v4 release of Zitadel.
|
||||||
|
|
||||||
## Performance test results
|
## Performance test results
|
||||||
@@ -33,16 +36,11 @@ Benchmark results of v4 release of Zitadel.
|
|||||||
|
|
||||||
## Endpoint latencies
|
## Endpoint latencies
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
█ TOTAL RESULTS
|
█ TOTAL RESULTS
|
||||||
|
|
||||||
checks_total.......................: 338059 181.945817/s
|
checks_total.......................: 338059 181.945817/s
|
||||||
checks_succeeded...................: 99.99% 338058 out of 338059
|
checks_succeeded...................: 99.99% 338058 out of 338059
|
||||||
@@ -68,25 +66,25 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
✓ org removed
|
✓ org removed
|
||||||
|
|
||||||
CUSTOM
|
CUSTOM
|
||||||
login_ui_enter_login_name_duration......................................: min=179.7ms avg=179.7ms max=179.7ms p(50)=179.7ms p(95)=179.7ms p(99)=179.7ms
|
login_ui_enter_login_name_duration......................................: min=179.7ms avg=179.7ms max=179.7ms p(50)=179.7ms p(95)=179.7ms p(99)=179.7ms
|
||||||
login_ui_enter_password_duration........................................: min=14.73ms avg=14.73ms max=14.73ms p(50)=14.73ms p(95)=14.73ms p(99)=14.73ms
|
login_ui_enter_password_duration........................................: min=14.73ms avg=14.73ms max=14.73ms p(50)=14.73ms p(95)=14.73ms p(99)=14.73ms
|
||||||
login_ui_init_login_duration............................................: min=76.13ms avg=76.13ms max=76.13ms p(50)=76.13ms p(95)=76.13ms p(99)=76.13ms
|
login_ui_init_login_duration............................................: min=76.13ms avg=76.13ms max=76.13ms p(50)=76.13ms p(95)=76.13ms p(99)=76.13ms
|
||||||
login_ui_token_duration.................................................: min=152.52ms avg=152.52ms max=152.52ms p(50)=152.52ms p(95)=152.52ms p(99)=152.52ms
|
login_ui_token_duration.................................................: min=152.52ms avg=152.52ms max=152.52ms p(50)=152.52ms p(95)=152.52ms p(99)=152.52ms
|
||||||
org_create_org_duration.................................................: min=59.87ms avg=59.87ms max=59.87ms p(50)=59.87ms p(95)=59.87ms p(99)=59.87ms
|
org_create_org_duration.................................................: min=59.87ms avg=59.87ms max=59.87ms p(50)=59.87ms p(95)=59.87ms p(99)=59.87ms
|
||||||
otp_session_duration....................................................: min=2.2s avg=9.63s max=15.61s p(50)=9.59s p(95)=12.09s p(99)=13.33s
|
otp_session_duration....................................................: min=2.2s avg=9.63s max=15.61s p(50)=9.59s p(95)=12.09s p(99)=13.33s
|
||||||
session_add_session_duration............................................: min=154ms avg=8.31s max=12.63s p(50)=8.42s p(95)=10.1s p(99)=10.52s
|
session_add_session_duration............................................: min=154ms avg=8.31s max=12.63s p(50)=8.42s p(95)=10.1s p(99)=10.52s
|
||||||
session_set_session_duration............................................: min=0s avg=659.94ms max=4.45s p(50)=513.63ms p(95)=1.62s p(99)=1.9s
|
session_set_session_duration............................................: min=0s avg=659.94ms max=4.45s p(50)=513.63ms p(95)=1.62s p(99)=1.9s
|
||||||
set_human_email_otp_duration............................................: min=29.12ms avg=494.09ms max=806.37ms p(50)=581.1ms p(95)=646.91ms p(99)=680.35ms
|
set_human_email_otp_duration............................................: min=29.12ms avg=494.09ms max=806.37ms p(50)=581.1ms p(95)=646.91ms p(99)=680.35ms
|
||||||
user_create_human_duration..............................................: min=698.95ms avg=9.83s max=17.55s p(50)=11.1s p(95)=17s p(99)=17.46s
|
user_create_human_duration..............................................: min=698.95ms avg=9.83s max=17.55s p(50)=11.1s p(95)=17s p(99)=17.46s
|
||||||
|
|
||||||
HTTP
|
HTTP
|
||||||
http_req_duration.......................................................: min=0s avg=3.21s max=20.01s p(50)=1.21s p(95)=9.59s p(99)=10.3s
|
http_req_duration.......................................................: min=0s avg=3.21s max=20.01s p(50)=1.21s p(95)=9.59s p(99)=10.3s
|
||||||
{ expected_response:true }............................................: min=14.73ms avg=3.21s max=20.01s p(50)=1.21s p(95)=9.59s p(99)=10.3s
|
{ expected_response:true }............................................: min=14.73ms avg=3.21s max=20.01s p(50)=1.21s p(95)=9.59s p(99)=10.3s
|
||||||
http_req_failed.........................................................: 0.00% 1 out of 338656
|
http_req_failed.........................................................: 0.00% 1 out of 338656
|
||||||
http_reqs...............................................................: 338656 182.267126/s
|
http_reqs...............................................................: 338656 182.267126/s
|
||||||
|
|
||||||
EXECUTION
|
EXECUTION
|
||||||
iteration_duration......................................................: min=2.2s avg=9.63s max=15.61s p(50)=9.59s p(95)=12.09s p(99)=13.33s
|
iteration_duration......................................................: min=2.2s avg=9.63s max=15.61s p(50)=9.59s p(95)=12.09s p(99)=13.33s
|
||||||
iterations..............................................................: 112282 60.43099/s
|
iterations..............................................................: 112282 60.43099/s
|
||||||
vus.....................................................................: 0 min=0 max=600
|
vus.....................................................................: 0 min=0 max=600
|
||||||
vus_max.................................................................: 600 min=600 max=600
|
vus_max.................................................................: 600 min=600 max=600
|
||||||
@@ -98,4 +96,3 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
running (30m58.0s), 000/600 VUs, 112282 complete and 0 interrupted iterations
|
running (30m58.0s), 000/600 VUs, 112282 complete and 0 interrupted iterations
|
||||||
default ✓ [======================================] 600 VUs 30m0s
|
default ✓ [======================================] 600 VUs 30m0s
|
||||||
```
|
```
|
||||||
|
|
||||||
+16
-19
@@ -3,6 +3,9 @@ title: session with password benchmark of zitadel v4
|
|||||||
sidebar_label: password session
|
sidebar_label: password session
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
Benchmark results of v4 release of Zitadel.
|
Benchmark results of v4 release of Zitadel.
|
||||||
|
|
||||||
## Performance test results
|
## Performance test results
|
||||||
@@ -33,16 +36,11 @@ Benchmark results of v4 release of Zitadel.
|
|||||||
|
|
||||||
## Endpoint latencies
|
## Endpoint latencies
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
█ TOTAL RESULTS
|
█ TOTAL RESULTS
|
||||||
|
|
||||||
checks_total.......................: 188813 101.308159/s
|
checks_total.......................: 188813 101.308159/s
|
||||||
checks_succeeded...................: 99.35% 187589 out of 188813
|
checks_succeeded...................: 99.35% 187589 out of 188813
|
||||||
@@ -69,25 +67,25 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
✓ org removed
|
✓ org removed
|
||||||
|
|
||||||
CUSTOM
|
CUSTOM
|
||||||
login_ui_enter_login_name_duration......................................: min=240.4ms avg=240.4ms max=240.4ms p(50)=240.4ms p(95)=240.4ms p(99)=240.4ms
|
login_ui_enter_login_name_duration......................................: min=240.4ms avg=240.4ms max=240.4ms p(50)=240.4ms p(95)=240.4ms p(99)=240.4ms
|
||||||
login_ui_enter_password_duration........................................: min=14.32ms avg=14.32ms max=14.32ms p(50)=14.32ms p(95)=14.32ms p(99)=14.32ms
|
login_ui_enter_password_duration........................................: min=14.32ms avg=14.32ms max=14.32ms p(50)=14.32ms p(95)=14.32ms p(99)=14.32ms
|
||||||
login_ui_init_login_duration............................................: min=84.45ms avg=84.45ms max=84.45ms p(50)=84.45ms p(95)=84.45ms p(99)=84.45ms
|
login_ui_init_login_duration............................................: min=84.45ms avg=84.45ms max=84.45ms p(50)=84.45ms p(95)=84.45ms p(99)=84.45ms
|
||||||
login_ui_token_duration.................................................: min=148.53ms avg=148.53ms max=148.53ms p(50)=148.53ms p(95)=148.53ms p(99)=148.53ms
|
login_ui_token_duration.................................................: min=148.53ms avg=148.53ms max=148.53ms p(50)=148.53ms p(95)=148.53ms p(99)=148.53ms
|
||||||
org_create_org_duration.................................................: min=59.73ms avg=59.73ms max=59.73ms p(50)=59.73ms p(95)=59.73ms p(99)=59.73ms
|
org_create_org_duration.................................................: min=59.73ms avg=59.73ms max=59.73ms p(50)=59.73ms p(95)=59.73ms p(99)=59.73ms
|
||||||
password_session_duration...............................................: min=371ms avg=10.97s max=1m4s p(50)=9.52s p(95)=23.81s p(99)=27.57s
|
password_session_duration...............................................: min=371ms avg=10.97s max=1m4s p(50)=9.52s p(95)=23.81s p(99)=27.57s
|
||||||
session_add_session_duration............................................: min=36.81ms avg=10.62s max=1m0s p(50)=9.13s p(95)=23.23s p(99)=29.47s
|
session_add_session_duration............................................: min=36.81ms avg=10.62s max=1m0s p(50)=9.13s p(95)=23.23s p(99)=29.47s
|
||||||
session_set_session_duration............................................: min=94.6ms avg=881.65ms max=1m0s p(50)=365.48ms p(95)=1.88s p(99)=4.75s
|
session_set_session_duration............................................: min=94.6ms avg=881.65ms max=1m0s p(50)=365.48ms p(95)=1.88s p(99)=4.75s
|
||||||
set_human_email_otp_duration............................................: min=39.12ms avg=570.13ms max=868.83ms p(50)=549.06ms p(95)=844.01ms p(99)=864.28ms
|
set_human_email_otp_duration............................................: min=39.12ms avg=570.13ms max=868.83ms p(50)=549.06ms p(95)=844.01ms p(99)=864.28ms
|
||||||
user_create_human_duration..............................................: min=502.43ms avg=10.82s max=16.72s p(50)=13.42s p(95)=16.28s p(99)=16.56s
|
user_create_human_duration..............................................: min=502.43ms avg=10.82s max=16.72s p(50)=13.42s p(95)=16.28s p(99)=16.56s
|
||||||
|
|
||||||
HTTP
|
HTTP
|
||||||
http_req_duration.......................................................: min=14.32ms avg=5.75s max=1m0s p(50)=583.63ms p(95)=22.01s p(99)=26.51s
|
http_req_duration.......................................................: min=14.32ms avg=5.75s max=1m0s p(50)=583.63ms p(95)=22.01s p(99)=26.51s
|
||||||
{ expected_response:true }............................................: min=14.32ms avg=5.47s max=59.87s p(50)=566.75ms p(95)=21.8s p(99)=24.55s
|
{ expected_response:true }............................................: min=14.32ms avg=5.47s max=59.87s p(50)=566.75ms p(95)=21.8s p(99)=24.55s
|
||||||
http_req_failed.........................................................: 0.64% 1224 out of 189410
|
http_req_failed.........................................................: 0.64% 1224 out of 189410
|
||||||
http_reqs...............................................................: 189410 101.628481/s
|
http_reqs...............................................................: 189410 101.628481/s
|
||||||
|
|
||||||
EXECUTION
|
EXECUTION
|
||||||
iteration_duration......................................................: min=38.37ms avg=11.5s max=1m21s p(50)=9.68s p(95)=24.21s p(99)=54.53s
|
iteration_duration......................................................: min=38.37ms avg=11.5s max=1m21s p(50)=9.68s p(95)=24.21s p(99)=54.53s
|
||||||
iterations..............................................................: 94143 50.512698/s
|
iterations..............................................................: 94143 50.512698/s
|
||||||
vus.....................................................................: 0 min=0 max=600
|
vus.....................................................................: 0 min=0 max=600
|
||||||
vus_max.................................................................: 600 min=600 max=600
|
vus_max.................................................................: 600 min=600 max=600
|
||||||
@@ -99,4 +97,3 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
running (31m03.7s), 000/600 VUs, 94143 complete and 0 interrupted iterations
|
running (31m03.7s), 000/600 VUs, 94143 complete and 0 interrupted iterations
|
||||||
default ✓ [======================================] 600 VUs 30m0s
|
default ✓ [======================================] 600 VUs 30m0s
|
||||||
```
|
```
|
||||||
|
|
||||||
+8
-11
@@ -3,6 +3,9 @@ title: user info benchmark of zitadel v4
|
|||||||
sidebar_label: user info
|
sidebar_label: user info
|
||||||
---
|
---
|
||||||
|
|
||||||
|
import OutputSource from "./output.json";
|
||||||
|
import { BenchmarkChart } from '@/components/benchmark_chart';
|
||||||
|
|
||||||
Benchmark results of v4 release of Zitadel.
|
Benchmark results of v4 release of Zitadel.
|
||||||
|
|
||||||
## Performance test results
|
## Performance test results
|
||||||
@@ -33,16 +36,11 @@ Benchmark results of v4 release of Zitadel.
|
|||||||
|
|
||||||
## Endpoint latencies
|
## Endpoint latencies
|
||||||
|
|
||||||
import OutputSource from "./output.json";
|
|
||||||
|
|
||||||
import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|
||||||
|
|
||||||
<BenchmarkChart testResults={OutputSource} />
|
<BenchmarkChart testResults={OutputSource} />
|
||||||
|
|
||||||
## k6 output {#k6-output}
|
## k6 output
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
█ TOTAL RESULTS
|
█ TOTAL RESULTS
|
||||||
|
|
||||||
checks_total.......................: 4784344 2653.094897/s
|
checks_total.......................: 4784344 2653.094897/s
|
||||||
checks_succeeded...................: 99.97% 4783333 out of 4784344
|
checks_succeeded...................: 99.97% 4783333 out of 4784344
|
||||||
@@ -71,10 +69,10 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
CUSTOM
|
CUSTOM
|
||||||
login_ui_enter_login_name_duration......................................: min=149.1ms avg=176.4ms max=203.69ms p(50)=176.4ms p(95)=200.96ms p(99)=203.15ms
|
login_ui_enter_login_name_duration......................................: min=149.1ms avg=176.4ms max=203.69ms p(50)=176.4ms p(95)=200.96ms p(99)=203.15ms
|
||||||
login_ui_enter_password_duration........................................: min=34.7ms avg=248.44ms max=462.19ms p(50)=248.44ms p(95)=440.82ms p(99)=457.92ms
|
login_ui_enter_password_duration........................................: min=34.7ms avg=248.44ms max=462.19ms p(50)=248.44ms p(95)=440.82ms p(99)=457.92ms
|
||||||
login_ui_init_login_duration............................................: min=83.7ms avg=85.38ms max=87.05ms p(50)=85.38ms p(95)=86.88ms p(99)=87.01ms
|
login_ui_init_login_duration............................................: min=83.7ms avg=85.38ms max=87.05ms p(50)=85.38ms p(95)=86.88ms p(99)=87.01ms
|
||||||
login_ui_token_duration.................................................: min=92.78ms avg=118.84ms max=144.89ms p(50)=118.84ms p(95)=142.29ms p(99)=144.37ms
|
login_ui_token_duration.................................................: min=92.78ms avg=118.84ms max=144.89ms p(50)=118.84ms p(95)=142.29ms p(99)=144.37ms
|
||||||
oidc_user_info_duration.................................................: min=453.34µs avg=224.58ms max=1m0s p(50)=83.13ms p(95)=792.51ms p(99)=926.8ms
|
oidc_user_info_duration.................................................: min=453.34µs avg=224.58ms max=1m0s p(50)=83.13ms p(95)=792.51ms p(99)=926.8ms
|
||||||
org_create_org_duration.................................................: min=53.42ms avg=53.42ms max=53.42ms p(50)=53.42ms p(95)=53.42ms p(99)=53.42ms
|
org_create_org_duration.................................................: min=53.42ms avg=53.42ms max=53.42ms p(50)=53.42ms p(95)=53.42ms p(99)=53.42ms
|
||||||
user_create_human_duration..............................................: min=373.72ms avg=373.72ms max=373.72ms p(50)=373.72ms p(95)=373.72ms p(99)=373.72ms
|
user_create_human_duration..............................................: min=373.72ms avg=373.72ms max=373.72ms p(50)=373.72ms p(95)=373.72ms p(99)=373.72ms
|
||||||
|
|
||||||
HTTP
|
HTTP
|
||||||
@@ -96,4 +94,3 @@ import { BenchmarkChart } from '/src/components/benchmark_chart';
|
|||||||
running (30m03.3s), 000/600 VUs, 4783719 complete and 0 interrupted iterations
|
running (30m03.3s), 000/600 VUs, 4783719 complete and 0 interrupted iterations
|
||||||
default ✓ [======================================] 600 VUs 30m0s
|
default ✓ [======================================] 600 VUs 30m0s
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -3,75 +3,75 @@ title: ZITADEL API Reference Overview
|
|||||||
sidebar_label: Overview
|
sidebar_label: Overview
|
||||||
---
|
---
|
||||||
|
|
||||||
import { ApiCard } from "../../src/components/apicard";
|
import { ApiCard } from "@/components/apicard";
|
||||||
import Column from "../../src/components/column";
|
import Column from "@/components/column";
|
||||||
|
|
||||||
ZITADEL exposes all features via different gRPC and REST APIs and provides SDKs for popular languages and frameworks.
|
ZITADEL exposes all features via different gRPC and REST APIs and provides SDKs for popular languages and frameworks.
|
||||||
|
|
||||||
The [OpenID Connect & OAuth endpoints](/docs/apis/openidoauth/endpoints) and [SAML 2.0 endpoints](/docs/apis/saml/endpoints) are implemented and exposed according to the specific standards. Managing resources such as users, organizations, instances, or settings must be done with the different [ZITADEL APIs](#zitadel-apis-resource-based).
|
The [OpenID Connect & OAuth endpoints](/apis/openidoauth/endpoints) and [SAML 2.0 endpoints](/apis/saml/endpoints) are implemented and exposed according to the specific standards. Managing resources such as users, organizations, instances, or settings must be done with the different [ZITADEL APIs](#zitadel-apis-resource-based).
|
||||||
|
|
||||||
[Actions](/docs/guides/manage/console/actions-overview) allow to extend ZITADEL with custom code to change default behaviors or calling external systems.
|
[Actions](/guides/manage/console/actions-overview) allow to extend ZITADEL with custom code to change default behaviors or calling external systems.
|
||||||
|
|
||||||
## Authentication & authorization
|
## Authentication & authorization
|
||||||
|
|
||||||
### Authentication for human users (interactive)
|
### Authentication for human users (interactive)
|
||||||
|
|
||||||
ZITADEL implements industry standards such as OpenID Connect, OAuth 2.0, or SAML for authentication.
|
ZITADEL implements industry standards such as OpenID Connect, OAuth 2.0, or SAML for authentication.
|
||||||
Please refer to our guides how to [authenticate users](/docs/guides/integrate/login/login-users) through an interactive authentication process.
|
Please refer to our guides how to [authenticate users](/guides/integrate/login/login-users) through an interactive authentication process.
|
||||||
|
|
||||||
For user authentication on devices with limited accessibility (eg, SmartTV, Smart Watch etc.) use the [device authorization grant](/docs/guides/integrate/login/oidc/device-authorization).
|
For user authentication on devices with limited accessibility (eg, SmartTV, Smart Watch etc.) use the [device authorization grant](/guides/integrate/login/oidc/device-authorization).
|
||||||
|
|
||||||
Additionally, you can use the [session API](../apis/resources/session_service_v2/) to authenticate users, for example by building a [custom login UI](/docs/guides/integrate/login-ui/).
|
Additionally, you can use the [session API](/reference/api/session) to authenticate users, for example by building a [custom login UI](/guides/integrate/login-ui).
|
||||||
|
|
||||||
### Authenticate service users and machines
|
### Authenticate service users and machines
|
||||||
|
|
||||||
Service users allow for machine-to-machine (M2M) communication.
|
Service users allow for machine-to-machine (M2M) communication.
|
||||||
Follow the guides to learn how to [authenticate service users](/docs/guides/integrate/service-users/authenticate-service-users).
|
Follow the guides to learn how to [authenticate service users](/guides/integrate/service-users/authenticate-service-users).
|
||||||
|
|
||||||
Accessing the ZITADEL APIs through a service user might require additional steps, please follow the guide on how to [access ZITADEL APIs](../guides/integrate/zitadel-apis/access-zitadel-apis) to include the correct audience scope in your requests.
|
Accessing the ZITADEL APIs through a service user might require additional steps, please follow the guide on how to [access ZITADEL APIs](../guides/integrate/zitadel-apis/access-zitadel-apis) to include the correct audience scope in your requests.
|
||||||
|
|
||||||
### OpenID Connect & OAuth
|
### OpenID Connect & OAuth
|
||||||
|
|
||||||
- [OpenID Connect endpoints](/docs/apis/openidoauth/endpoints) definition
|
- [OpenID Connect endpoints](/apis/openidoauth/endpoints) definition
|
||||||
- Standard and reserved [scopes reference](/docs/apis/openidoauth/scopes)
|
- Standard and reserved [scopes reference](/apis/openidoauth/scopes)
|
||||||
- Standard, custom, and reserved [claims reference](/docs/apis/openidoauth/claims)
|
- Standard, custom, and reserved [claims reference](/apis/openidoauth/claims)
|
||||||
|
|
||||||
The [OIDC Playground](https://zitadel.com/playgrounds/oidc) is for testing OpenID authentication requests and their parameters.
|
The [OIDC Playground](https://zitadel.com/playgrounds/oidc) is for testing OpenID authentication requests and their parameters.
|
||||||
|
|
||||||
### SAML 2.0
|
### SAML 2.0
|
||||||
|
|
||||||
- [SAML 2.0 endpoints](/docs/apis/saml/endpoints) definition
|
- [SAML 2.0 endpoints](/apis/saml/endpoints) definition
|
||||||
- [Custom attributes](https://github.com/zitadel/actions/blob/main/examples/set_custom_attribute.js) can be added with an action
|
- [Custom attributes](https://github.com/zitadel/actions/blob/main/examples/set_custom_attribute.js) can be added with an action
|
||||||
|
|
||||||
### Custom
|
### Custom
|
||||||
|
|
||||||
ZITADEL allows to authenticate users by creating a session with the [Session API](/docs/apis/resources/session_service_v2), get OIDC authentication request details with the [OIDC service API](/docs/apis/resources/oidc_service_v2) or get SAML request details with the [SAML service API](/docs/apis/resources/saml_service_v2).
|
ZITADEL allows to authenticate users by creating a session with the [Session API](/reference/api/session), get OIDC authentication request details with the [OIDC service API](/reference/api/oidc) or get SAML request details with the [SAML service API](/reference/api/saml).
|
||||||
User authorizations can be [retrieved as roles from our APIs](/docs/guides/integrate/retrieve-user-roles).
|
User authorizations can be [retrieved as roles from our APIs](/guides/integrate/retrieve-user-roles).
|
||||||
|
|
||||||
Refer to our guide to learn how to [build your own login UI](/docs/guides/integrate/login-ui)
|
Refer to our guide to learn how to [build your own login UI](/guides/integrate/login-ui)
|
||||||
|
|
||||||
## ZITADEL APIs (resource-based)
|
## ZITADEL APIs (resource-based)
|
||||||
|
|
||||||
ZITADEL provides APIs for each [core resource](/docs/apis/v2):
|
ZITADEL provides APIs for each [core resource](/apis/v2):
|
||||||
|
|
||||||
- [User](/docs/apis/resources/user_service_v2)
|
- [User](/reference/api/user)
|
||||||
- [Session](/docs/apis/resources/session_service_v2)
|
- [Session](/reference/api/session)
|
||||||
- [Settings](/docs/apis/resources/settings_service_v2)
|
- [Settings](/reference/api/settings)
|
||||||
|
|
||||||
:::info
|
<Callout>
|
||||||
We are migrating to a resource-based API approach.
|
We are migrating to a resource-based API approach.
|
||||||
You might need to use the existing [service-based](#zitadel-apis-service-based) APIs for now to manage Organizations, Instances, Assets etc.
|
You might need to use the existing [service-based](#zitadel-apis-service-based) APIs for now to manage Organizations, Instances, Assets etc.
|
||||||
:::
|
</Callout>
|
||||||
|
|
||||||
## ZITADEL APIs (service-based)
|
## ZITADEL APIs (service-based)
|
||||||
|
|
||||||
:::info Prefer resource-based API
|
<Callout title="Prefer resource-based API">
|
||||||
ZITADEL APIs were organized by UseCase/Context, such as Auth API for authenticated users and Management API for organization managers.
|
ZITADEL APIs were organized by UseCase/Context, such as Auth API for authenticated users and Management API for organization managers.
|
||||||
This led to confusion about which API to use, particularly for requests that could be useful across multiple APIs but with different filters.
|
This led to confusion about which API to use, particularly for requests that could be useful across multiple APIs but with different filters.
|
||||||
For instance, SearchUsers on an Instance Level or on an Organization Level.
|
For instance, SearchUsers on an Instance Level or on an Organization Level.
|
||||||
|
|
||||||
To address this issue, ZITADEL is migrating to a [resource-based API](#zitadel-apis-resource-based).
|
To address this issue, ZITADEL is migrating to a [resource-based API](#zitadel-apis-resource-based).
|
||||||
:::
|
</Callout>
|
||||||
|
|
||||||
<ApiCard title="Authentication" type="AUTH">
|
<ApiCard title="Authentication" type="AUTH">
|
||||||
<Column>
|
<Column>
|
||||||
@@ -84,7 +84,7 @@ The authentication API (aka Auth API) is used for all operations on the currentl
|
|||||||
</div>
|
</div>
|
||||||
<div className="apicard-right">
|
<div className="apicard-right">
|
||||||
|
|
||||||
#### GRPC
|
#### Auth GRPC
|
||||||
|
|
||||||
Endpoint:
|
Endpoint:
|
||||||
`${CUSTOM_DOMAIN}/zitadel.auth.v1.AuthService/`
|
`${CUSTOM_DOMAIN}/zitadel.auth.v1.AuthService/`
|
||||||
@@ -92,13 +92,13 @@ Endpoint:
|
|||||||
Definition:
|
Definition:
|
||||||
[Auth Proto](https://github.com/zitadel/zitadel/blob/main/proto/zitadel/auth.proto)
|
[Auth Proto](https://github.com/zitadel/zitadel/blob/main/proto/zitadel/auth.proto)
|
||||||
|
|
||||||
#### REST
|
#### Auth REST
|
||||||
|
|
||||||
Endpoint:
|
Endpoint:
|
||||||
`${CUSTOM_DOMAIN}/auth/v1/`
|
`${CUSTOM_DOMAIN}/auth/v1/`
|
||||||
|
|
||||||
API Reference:
|
API Reference:
|
||||||
[OpenAPI Docs](/apis/resources/auth)
|
[OpenAPI Docs](/reference/api/auth)
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</Column>
|
</Column>
|
||||||
@@ -117,7 +117,7 @@ To identify the current organization you can send a header `x-zitadel-orgid` or
|
|||||||
</div>
|
</div>
|
||||||
<div className="apicard-right">
|
<div className="apicard-right">
|
||||||
|
|
||||||
#### GRPC
|
#### Mgmt GRPC
|
||||||
|
|
||||||
Endpoint:
|
Endpoint:
|
||||||
`${CUSTOM_DOMAIN}/zitadel.management.v1.ManagementService/`
|
`${CUSTOM_DOMAIN}/zitadel.management.v1.ManagementService/`
|
||||||
@@ -125,13 +125,13 @@ Endpoint:
|
|||||||
Definition:
|
Definition:
|
||||||
[Management Proto](https://github.com/zitadel/zitadel/blob/main/proto/zitadel/management.proto)
|
[Management Proto](https://github.com/zitadel/zitadel/blob/main/proto/zitadel/management.proto)
|
||||||
|
|
||||||
#### REST
|
#### Mgmt REST
|
||||||
|
|
||||||
Endpoint:
|
Endpoint:
|
||||||
`${CUSTOM_DOMAIN}/management/v1/`
|
`${CUSTOM_DOMAIN}/management/v1/`
|
||||||
|
|
||||||
API Reference:
|
API Reference:
|
||||||
[OpenAPI Docs](/apis/resources/mgmt)
|
[OpenAPI Docs](/reference/api/management)
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</Column>
|
</Column>
|
||||||
@@ -148,7 +148,7 @@ This API is intended to configure and manage one ZITADEL instance itself.
|
|||||||
</div>
|
</div>
|
||||||
<div className="apicard-right">
|
<div className="apicard-right">
|
||||||
|
|
||||||
#### GRPC
|
#### Admin GRPC
|
||||||
|
|
||||||
Endpoint:
|
Endpoint:
|
||||||
`${CUSTOM_DOMAIN}/zitadel.admin.v1.AdminService/`
|
`${CUSTOM_DOMAIN}/zitadel.admin.v1.AdminService/`
|
||||||
@@ -156,13 +156,13 @@ Endpoint:
|
|||||||
Definition:
|
Definition:
|
||||||
[Admin Proto](https://github.com/zitadel/zitadel/blob/main/proto/zitadel/admin.proto)
|
[Admin Proto](https://github.com/zitadel/zitadel/blob/main/proto/zitadel/admin.proto)
|
||||||
|
|
||||||
#### REST
|
#### Admin REST
|
||||||
|
|
||||||
Endpoint:
|
Endpoint:
|
||||||
`${CUSTOM_DOMAIN}/admin/v1/`
|
`${CUSTOM_DOMAIN}/admin/v1/`
|
||||||
|
|
||||||
API Reference:
|
API Reference:
|
||||||
[OpenAPI Docs](/apis/resources/admin)
|
[OpenAPI Docs](/reference/api/admin)
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</Column>
|
</Column>
|
||||||
@@ -176,12 +176,12 @@ API Reference:
|
|||||||
|
|
||||||
This API is intended to manage the different ZITADEL instances within the system.
|
This API is intended to manage the different ZITADEL instances within the system.
|
||||||
|
|
||||||
Checkout the guide how to [access the ZITADEL System API](/docs/guides/integrate/zitadel-apis/access-zitadel-system-api).
|
Checkout the guide how to [access the ZITADEL System API](/guides/integrate/zitadel-apis/access-zitadel-system-api).
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div className="apicard-right">
|
<div className="apicard-right">
|
||||||
|
|
||||||
#### GRPC
|
#### System GRPC
|
||||||
|
|
||||||
Endpoint:
|
Endpoint:
|
||||||
`${CUSTOM_DOMAIN}/zitadel.system.v1.SystemService/`
|
`${CUSTOM_DOMAIN}/zitadel.system.v1.SystemService/`
|
||||||
@@ -189,13 +189,13 @@ Endpoint:
|
|||||||
Definition:
|
Definition:
|
||||||
[System Proto](https://github.com/zitadel/zitadel/blob/main/proto/zitadel/system.proto)
|
[System Proto](https://github.com/zitadel/zitadel/blob/main/proto/zitadel/system.proto)
|
||||||
|
|
||||||
#### REST
|
#### System REST
|
||||||
|
|
||||||
Endpoint:
|
Endpoint:
|
||||||
`${CUSTOM_DOMAIN}/system/v1/`
|
`${CUSTOM_DOMAIN}/system/v1/`
|
||||||
|
|
||||||
API Reference:
|
API Reference:
|
||||||
[OpenAPI Docs](/apis/resources/system)
|
[OpenAPI Docs](/reference/api/system)
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</Column>
|
</Column>
|
||||||
@@ -212,13 +212,13 @@ The Assets API allows you to up- and download all kinds of assets. This can be f
|
|||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
|
|
||||||
#### REST
|
#### Assets REST
|
||||||
|
|
||||||
Endpoint:
|
Endpoint:
|
||||||
`${CUSTOM_DOMAIN}/assets/v1/`
|
`${CUSTOM_DOMAIN}/assets/v1/`
|
||||||
|
|
||||||
Definition:
|
Definition:
|
||||||
[Assets](./assets/assets.md)
|
[Assets](./assets/assets)
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</Column>
|
</Column>
|
||||||
@@ -233,7 +233,7 @@ The last API (assets) is only a REST API because ZITADEL uses multipart form dat
|
|||||||
|
|
||||||
### SDKs
|
### SDKs
|
||||||
|
|
||||||
ZITADEL provides some [official and community supported SDKs](/docs/sdk-examples/introduction) for multiple languages and frameworks.
|
ZITADEL provides some [official and community supported SDKs](/sdk-examples/introduction) for multiple languages and frameworks.
|
||||||
Most languages allow you to build a client from proto definitions, which allows you to build your own client in case an SDK is missing.
|
Most languages allow you to build a client from proto definitions, which allows you to build your own client in case an SDK is missing.
|
||||||
|
|
||||||
### Proto
|
### Proto
|
||||||
@@ -274,7 +274,7 @@ ZITADEL hosts everything under a single domain: `{instance}.zitadel.cloud` or yo
|
|||||||
|
|
||||||
The domain is used as the OIDC issuer and as the base url for the gRPC and REST APIs, the Login and Management Console UI, which you'll find under `${CUSTOM_DOMAIN}/ui/console/`.
|
The domain is used as the OIDC issuer and as the base url for the gRPC and REST APIs, the Login and Management Console UI, which you'll find under `${CUSTOM_DOMAIN}/ui/console/`.
|
||||||
|
|
||||||
Are you self-hosting and having troubles with _Instance not found_ errors? [Check out this page](/docs/self-hosting/manage/custom-domain).
|
Are you self-hosting and having troubles with _Instance not found_ errors? [Check out this page](/self-hosting/manage/custom-domain).
|
||||||
|
|
||||||
## API path prefixes
|
## API path prefixes
|
||||||
|
|
||||||
@@ -314,7 +314,7 @@ For easy copying to your reverse proxy configuration, here is the list of URL pa
|
|||||||
```
|
```
|
||||||
## Postman Collection (Beta)
|
## Postman Collection (Beta)
|
||||||
|
|
||||||
We published an official Postman collection to help you explore and test the ZITADEL APIs.
|
We published an official Postman collection to help you explore and test the ZITADEL APIs.
|
||||||
|
|
||||||
The collection is organized by services, and includes a script to automatically authenticate requests. Before using it, make sure to configure the required environment variables in Postman:
|
The collection is organized by services, and includes a script to automatically authenticate requests. Before using it, make sure to configure the required environment variables in Postman:
|
||||||
|
|
||||||
@@ -330,4 +330,4 @@ The collection is organized by services, and includes a script to automatically
|
|||||||
|
|
||||||
[Fork the Postman Collection](https://app.getpostman.com/run-collection/44392838-6417c238-b9b9-4334-bef0-233ae38cbc51?action=collection%2Ffork&source=rip_markdown&collection-url=entityId%3D44392838-6417c238-b9b9-4334-bef0-233ae38cbc51%26entityType%3Dcollection%26workspaceId%3D54ef8cdd-5ea3-4f31-89f6-20720b45528c)
|
[Fork the Postman Collection](https://app.getpostman.com/run-collection/44392838-6417c238-b9b9-4334-bef0-233ae38cbc51?action=collection%2Ffork&source=rip_markdown&collection-url=entityId%3D44392838-6417c238-b9b9-4334-bef0-233ae38cbc51%26entityType%3Dcollection%26workspaceId%3D54ef8cdd-5ea3-4f31-89f6-20720b45528c)
|
||||||
|
|
||||||
This release is currently in **beta**, and we welcome your feedback to improve it.
|
This release is currently in **beta**, and we welcome your feedback to improve it.
|
||||||
+2
-2
@@ -110,7 +110,7 @@ When migrating your user management from v1 to v2, the most significant updates
|
|||||||
- You can choose at user creation whether an email verification code should be sent automatically.
|
- You can choose at user creation whether an email verification code should be sent automatically.
|
||||||
- Alternatively, the API can return the verification code directly to you, empowering you to send a customized verification email.
|
- Alternatively, the API can return the verification code directly to you, empowering you to send a customized verification email.
|
||||||
|
|
||||||
[Users API v2 Documentation](/docs/apis/resources/user_service_v2)
|
[Users API v2 Documentation](/reference/api/user)
|
||||||
|
|
||||||
### Projects
|
### Projects
|
||||||
|
|
||||||
@@ -170,4 +170,4 @@ This approach simplifies client-side logic, as you no longer need to route reque
|
|||||||
- OIDC
|
- OIDC
|
||||||
- SAML
|
- SAML
|
||||||
- API
|
- API
|
||||||
```
|
```
|
||||||
+4
-4
@@ -10,15 +10,15 @@ ZITADEL exposes a `Ready`- and `Healthy` endpoint to allow external systems like
|
|||||||
The `Ready` endpoint is located on the path `/debug/ready` and allows systems to probe if a ZITADEL process is ready to serve and accept traffic.
|
The `Ready` endpoint is located on the path `/debug/ready` and allows systems to probe if a ZITADEL process is ready to serve and accept traffic.
|
||||||
This endpoint is useful for operations like [zero downtime upgrade](../../concepts/architecture/solution#zero-downtime-updates) since it allows systems like Kubernetes to verify that ZITADEL is working on something (e.g. database schema migration) but is not yet ready to accept traffic.
|
This endpoint is useful for operations like [zero downtime upgrade](../../concepts/architecture/solution#zero-downtime-updates) since it allows systems like Kubernetes to verify that ZITADEL is working on something (e.g. database schema migration) but is not yet ready to accept traffic.
|
||||||
|
|
||||||
:::info
|
<Callout>
|
||||||
In Kubernetes this is called the `readinessProbe`.
|
In Kubernetes this is called the `readinessProbe`.
|
||||||
:::
|
</Callout>
|
||||||
|
|
||||||
## Healthy
|
## Healthy
|
||||||
|
|
||||||
The `Health` endpoint is located on the path `/debug/healthz` and allows systems to probe if a ZITADEL process is still alive.
|
The `Health` endpoint is located on the path `/debug/healthz` and allows systems to probe if a ZITADEL process is still alive.
|
||||||
This helps system like kubernetes or a load balancer to observe if the process is still alive to accept traffic.
|
This helps system like kubernetes or a load balancer to observe if the process is still alive to accept traffic.
|
||||||
|
|
||||||
:::info
|
<Callout>
|
||||||
In Kubernetes this is called the `livenessProbe`.
|
In Kubernetes this is called the `livenessProbe`.
|
||||||
:::
|
</Callout>
|
||||||
+2
-2
@@ -9,7 +9,7 @@ If you are self-hosting ZITADEL, you can access this endpoint with on the path `
|
|||||||
For example when running ZITADEL locally the endpoint is accessible on `http://localhost:8080/debug/metrics`.
|
For example when running ZITADEL locally the endpoint is accessible on `http://localhost:8080/debug/metrics`.
|
||||||
The metrics endpoint can be scrubbed by any tool of choice that supports the `otel` format, e.g an existing Prometheus.
|
The metrics endpoint can be scrubbed by any tool of choice that supports the `otel` format, e.g an existing Prometheus.
|
||||||
|
|
||||||
For our [Kubernetes/Helm](/docs/self-hosting/deploy/kubernetes) users, we provide an out of the box support for the [ServiceMonitor](https://github.com/zitadel/zitadel-charts/blob/main/charts/zitadel/templates/servicemonitor.yaml) custom resource.
|
For our [Kubernetes/Helm](/self-hosting/deploy/kubernetes) users, we provide an out of the box support for the [ServiceMonitor](https://github.com/zitadel/zitadel-charts/blob/main/charts/zitadel/templates/servicemonitor.yaml) custom resource.
|
||||||
|
|
||||||
By default, metrics are enabled but can be turned off through ZITADEL's [configuration](/docs/self-hosting/manage/configure).
|
By default, metrics are enabled but can be turned off through ZITADEL's [configuration](/self-hosting/manage/configure).
|
||||||
The (default) configuration is located in the [defaults.yaml](https://github.com/zitadel/zitadel/blob/main/cmd/defaults.yaml).
|
The (default) configuration is located in the [defaults.yaml](https://github.com/zitadel/zitadel/blob/main/cmd/defaults.yaml).
|
||||||
+1
-1
@@ -6,6 +6,6 @@
|
|||||||
| actor_token | Optional. A token that represents the identity of the acting party. In ZITADEL this the impersonator. |
|
| actor_token | Optional. A token that represents the identity of the acting party. In ZITADEL this the impersonator. |
|
||||||
| actor_token_type | An identifier that indicates the type of the token in the actor_token parameter. Required when actor_token is provided |
|
| actor_token_type | An identifier that indicates the type of the token in the actor_token parameter. Required when actor_token is provided |
|
||||||
| requested_token_type | Optional. An identifier that indicates the type of the token requested. Defaults to access token if not provided. |
|
| requested_token_type | Optional. An identifier that indicates the type of the token requested. Defaults to access token if not provided. |
|
||||||
| scope | [Scopes](/docs/apis/openidoauth/scopes) you would like to request from ZITADEL for the requested token. Scopes are space delimited, e.g. `openid email profile`. |
|
| scope | [Scopes](/apis/openidoauth/scopes) you would like to request from ZITADEL for the requested token. Scopes are space delimited, e.g. `openid email profile`. |
|
||||||
| audience | Optional. Must be a subset of the combined audiences from both subject and actor tokens. |
|
| audience | Optional. Must be a subset of the combined audiences from both subject and actor tokens. |
|
||||||
| resource | Currently not supported |
|
| resource | Currently not supported |
|
||||||
+2
-2
@@ -30,7 +30,7 @@ Key JSON
|
|||||||
| clientId | `78366401571920522@acme` | The client_id of the application, this is the same as the subject from tokens |
|
| clientId | `78366401571920522@acme` | The client_id of the application, this is the same as the subject from tokens |
|
||||||
| appId | `78366403256846242` | The id of the application (just for completeness, not used for JWT) |
|
| appId | `78366403256846242` | The id of the application (just for completeness, not used for JWT) |
|
||||||
|
|
||||||
```JSON
|
```json
|
||||||
{
|
{
|
||||||
"type": "application",
|
"type": "application",
|
||||||
"keyId": "81693565968962154",
|
"keyId": "81693565968962154",
|
||||||
@@ -52,7 +52,7 @@ JWT
|
|||||||
| iss | `"78366401571920522@acme"` | String which represents the requesting party (owner of the key), normally the `clientID` from the json key file |
|
| iss | `"78366401571920522@acme"` | String which represents the requesting party (owner of the key), normally the `clientID` from the json key file |
|
||||||
| sub | `"78366401571920522@acme"` | The subject ID of the application, normally the `clientID` from the json key file |
|
| sub | `"78366401571920522@acme"` | The subject ID of the application, normally the `clientID` from the json key file |
|
||||||
|
|
||||||
```JSON
|
```json
|
||||||
{
|
{
|
||||||
"iss": "78366401571920522@acme",
|
"iss": "78366401571920522@acme",
|
||||||
"sub": "78366401571920522@acme",
|
"sub": "78366401571920522@acme",
|
||||||
+7
-5
@@ -3,13 +3,15 @@ title: ZITADEL OIDC Authentication Request Playground
|
|||||||
sidebar_label: OIDC Playground
|
sidebar_label: OIDC Playground
|
||||||
---
|
---
|
||||||
|
|
||||||
import { SetAuthRequest } from "../../../src/components/authrequest";
|
import { ExternalLink } from "lucide-react";
|
||||||
|
|
||||||
The OIDC Playground is for testing OpenID Authentication Requests, giving you more insight how OpenID Connect works and how you can customize ZITADEL behavior with different parameters.
|
The OIDC Playground is for testing OpenID Authentication Requests, giving you more insight how OpenID Connect works and how you can customize ZITADEL behavior with different parameters.
|
||||||
|
|
||||||
An OpenID Connect (OIDC) [authentication request](https://openid.net/specs/openid-connect-core-1_0.html) is an OAuth 2.0 Authorization Request using additional parameters and scopes to request that the end-user be authenticated by ZITADEL.
|
An OpenID Connect (OIDC) [authentication request](https://openid.net/specs/openid-connect-core-1_0.html) is an OAuth 2.0 Authorization Request using additional parameters and scopes to request that the end-user be authenticated by ZITADEL.
|
||||||
|
|
||||||
<SetAuthRequest />
|
<a href="https://zitadel.com/playgrounds/oidc" target="_blank" className="flex items-center gap-2 text-primary hover:underline">
|
||||||
|
Go to the OIDC Playground <ExternalLink className="h-4 w-4" />
|
||||||
|
</a>
|
||||||
|
|
||||||
## Why this OIDC playground?
|
## Why this OIDC playground?
|
||||||
|
|
||||||
@@ -20,7 +22,7 @@ This playground should help you to initially craft an authentication request and
|
|||||||
|
|
||||||
## Request parameters explained
|
## Request parameters explained
|
||||||
|
|
||||||
Not all request parameters are available in the playground. Please refer to the full documentation of the [authorization endpoint](/apis/openidoauth/endpoints#authorization_endpoint).
|
Not all request parameters are available in the playground. Please refer to the full documentation of the [authorization endpoint](/apis/openidoauth/endpoints#authorization-endpoint).
|
||||||
|
|
||||||
### Your Domain
|
### Your Domain
|
||||||
|
|
||||||
@@ -57,7 +59,7 @@ Depending on the authentication and authorization flow of your application you m
|
|||||||
for most application types. The playground appends automatically a code challenge
|
for most application types. The playground appends automatically a code challenge
|
||||||
for PKCE flows.
|
for PKCE flows.
|
||||||
|
|
||||||
You need to append a "Code Challenge" by providing a random <span className="text-teal-600">Code Verifier</span> that is being hashed and encoded in the request to the token endpoint, please see our [guide](/guides/integrate/login/oidc/login-users#token-request) for more details.
|
You need to append a "Code Challenge" by providing a random <span className="text-teal-600">Code Verifier</span> that is being hashed and encoded in the request to the token endpoint, please see our [guide](/guides/integrate/login/oidc/oauth-recommended-flows#our-recommended-authorization-flows) for more details.
|
||||||
|
|
||||||
More in the [documentation](/apis/openidoauth/authn-methods) about authentication methods.
|
More in the [documentation](/apis/openidoauth/authn-methods) about authentication methods.
|
||||||
|
|
||||||
@@ -125,4 +127,4 @@ This can be achieved by adding the scope `urn:zitadel:iam:org:project:id:zitadel
|
|||||||
|
|
||||||
Please refer to our [guide](/guides/integrate/login/oidc/login-users) on how to login users.
|
Please refer to our [guide](/guides/integrate/login/oidc/login-users) on how to login users.
|
||||||
|
|
||||||
OpenID Connect certified libraries should allow you to customize the parameters and define scopes for the authorization request. You can also continue by using one of our [example applications](/docs/sdk-examples/introduction).
|
OpenID Connect certified libraries should allow you to customize the parameters and define scopes for the authorization request. You can also continue by using one of our [example applications](/sdk-examples/introduction).
|
||||||
+5
-3
@@ -47,7 +47,7 @@ Please check below the matrix for an overview where which scope is asserted.
|
|||||||
| Claims | Example | Description |
|
| Claims | Example | Description |
|
||||||
|:-------------------|:---------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|:-------------------|:---------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||||
| acr | TBA | TBA |
|
| acr | TBA | TBA |
|
||||||
| act | `{"iss": "${CUSTOM_DOMAIN}","sub": "259241944654282754"}` | JSON object describing the actor from the `actor_token` after [token exchange](/docs/guides/integrate/token-exchange#actor-token) |
|
| act | `{"iss": "${CUSTOM_DOMAIN}","sub": "259241944654282754"}` | JSON object describing the actor from the `actor_token` after [token exchange](/guides/integrate/token-exchange#actor-token) |
|
||||||
| address | `Lerchenfeldstrasse 3, 9014 St. Gallen` | TBA |
|
| address | `Lerchenfeldstrasse 3, 9014 St. Gallen` | TBA |
|
||||||
| amr | `pwd mfa` | Authentication Method References as defined in [RFC8176](https://tools.ietf.org/html/rfc8176) <br/> `password` value is deprecated, please check `pwd` |
|
| amr | `pwd mfa` | Authentication Method References as defined in [RFC8176](https://tools.ietf.org/html/rfc8176) <br/> `password` value is deprecated, please check `pwd` |
|
||||||
| aud | `69234237810729019` | The audience of the token, by default all client id's and the project id are included |
|
| aud | `69234237810729019` | The audience of the token, by default all client id's and the project id are included |
|
||||||
@@ -58,8 +58,10 @@ Please check below the matrix for an overview where which scope is asserted.
|
|||||||
| events | `{ "http://schemas.openid.net/event/backchannel-logout": {} }` | Security Events such as Back-Channel Logout |
|
| events | `{ "http://schemas.openid.net/event/backchannel-logout": {} }` | Security Events such as Back-Channel Logout |
|
||||||
| exp | `1311281970` | Time the token expires (as unix time) |
|
| exp | `1311281970` | Time the token expires (as unix time) |
|
||||||
| family_name | `Runner` | Last name of the subject |
|
| family_name | `Runner` | Last name of the subject |
|
||||||
|
| family_name | `Runner` | Last name of the subject |
|
||||||
| gender | `other` | Gender of the subject |
|
| gender | `other` | Gender of the subject |
|
||||||
| given_name | `Road` | First name of the subject |
|
| given_name | `Road` | First name of the subject |
|
||||||
|
| given_name | `Road` | First name of the subject |
|
||||||
| iat | `1311280970` | Time of the token was issued at (as unix time) |
|
| iat | `1311280970` | Time of the token was issued at (as unix time) |
|
||||||
| iss | `${CUSTOM_DOMAIN}` | Issuing domain of a token |
|
| iss | `${CUSTOM_DOMAIN}` | Issuing domain of a token |
|
||||||
| jti | `69234237813329048` | Unique id of the token |
|
| jti | `69234237813329048` | Unique id of the token |
|
||||||
@@ -78,7 +80,7 @@ Please check below the matrix for an overview where which scope is asserted.
|
|||||||
Custom claims are being inserted into user tokens in addition to the standard claims.
|
Custom claims are being inserted into user tokens in addition to the standard claims.
|
||||||
Your app can use custom claims to handle more complex scenarios, such as restricting access based on these claims.
|
Your app can use custom claims to handle more complex scenarios, such as restricting access based on these claims.
|
||||||
|
|
||||||
You can add custom claims using the [complement token flow](/docs/apis/actions/complement-token) of the [actions feature](/docs/guides/manage/console/actions-overview).
|
You can add custom claims using the [complement token flow](/apis/actions/complement-token) of the [actions feature](/guides/manage/console/actions-overview).
|
||||||
|
|
||||||
Multiple examples of Actions that result in custom claims can be found in our [Marketplace for ZITADEL Actions](https://github.com/zitadel/actions).
|
Multiple examples of Actions that result in custom claims can be found in our [Marketplace for ZITADEL Actions](https://github.com/zitadel/actions).
|
||||||
|
|
||||||
@@ -102,7 +104,7 @@ https://github.com/zitadel/actions/blob/main/examples/custom_roles.js#L20-L33
|
|||||||
|
|
||||||
## Reserved Claims
|
## Reserved Claims
|
||||||
|
|
||||||
ZITADEL reserves some claims to assert certain data. Please check out the [reserved scopes](scopes#reserved-scopes).
|
ZITADEL reserves some claims to assert certain data. Please check out the [reserved scopes](./scopes#reserved-scopes).
|
||||||
|
|
||||||
| Claims | Example | Description |
|
| Claims | Example | Description |
|
||||||
|:--------------------------------------------------|:---------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|:--------------------------------------------------|:---------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||||
+102
-113
@@ -3,8 +3,6 @@ title: OpenID Connect Endpoints in ZITADEL
|
|||||||
sidebar_label: OpenID Connect Endpoints
|
sidebar_label: OpenID Connect Endpoints
|
||||||
---
|
---
|
||||||
|
|
||||||
import Tabs from "@theme/Tabs";
|
|
||||||
import TabItem from "@theme/TabItem";
|
|
||||||
import TokenExchangeRequest from "./_token_exchange_request.mdx";
|
import TokenExchangeRequest from "./_token_exchange_request.mdx";
|
||||||
import TokenExchangeResponse from "./_token_exchange_response.mdx";
|
import TokenExchangeResponse from "./_token_exchange_response.mdx";
|
||||||
import TokenExchangeTypes from "./_token_exchange_types.mdx";
|
import TokenExchangeTypes from "./_token_exchange_types.mdx";
|
||||||
@@ -20,9 +18,9 @@ This would give us `${CUSTOM_DOMAIN}/.well-known/openid-configuration`.
|
|||||||
|
|
||||||
`${CUSTOM_DOMAIN}/oauth/v2/authorize`
|
`${CUSTOM_DOMAIN}/oauth/v2/authorize`
|
||||||
|
|
||||||
:::note
|
<Callout>
|
||||||
The authorization_endpoint is located with the login page, due to the need of accessing the same cookie domain
|
The authorization_endpoint is located with the login page, due to the need of accessing the same cookie domain
|
||||||
:::
|
</Callout>
|
||||||
|
|
||||||
The authorization_endpoint is the starting point for all initial user authentications. The user agent (browser) will be redirected to this endpoint to
|
The authorization_endpoint is the starting point for all initial user authentications. The user agent (browser) will be redirected to this endpoint to
|
||||||
authenticate the user in exchange for an authorization_code (authorization code flow) or tokens (implicit flow).
|
authenticate the user in exchange for an authorization_code (authorization code flow) or tokens (implicit flow).
|
||||||
@@ -50,15 +48,15 @@ authenticate the user in exchange for an authorization_code (authorization code
|
|||||||
| client_id | The id of your client as shown in Console. |
|
| client_id | The id of your client as shown in Console. |
|
||||||
| redirect_uri | Callback uri of the authorization request where the code or tokens will be sent to. Must match exactly one of the preregistered in Console. |
|
| redirect_uri | Callback uri of the authorization request where the code or tokens will be sent to. Must match exactly one of the preregistered in Console. |
|
||||||
| response_type | Determines whether a `code`, `id_token token` or just `id_token` will be returned. Most use cases will need `code`. See flow guide for more info. |
|
| response_type | Determines whether a `code`, `id_token token` or just `id_token` will be returned. Most use cases will need `code`. See flow guide for more info. |
|
||||||
| scope | `openid` is required, see [Scopes](scopes) for more possible values. Scopes are space delimited, e.g. `openid email profile` |
|
| scope | `openid` is required, see [Scopes](./scopes) for more possible values. Scopes are space delimited, e.g. `openid email profile` |
|
||||||
|
|
||||||
:::important
|
<Callout>
|
||||||
Following the [OIDC Core 1.0 specs](https://openid.net/specs/openid-connect-core-1_0.html#ScopeClaims) whenever an access_token is issued,
|
Following the [OIDC Core 1.0 specs](https://openid.net/specs/openid-connect-core-1_0.html#ScopeClaims) whenever an access_token is issued,
|
||||||
the id_token will not contain any claims of the scopes `profile`, `email`, `phone` and `address`.
|
the id_token will not contain any claims of the scopes `profile`, `email`, `phone` and `address`.
|
||||||
|
|
||||||
Send the access_token to the [userinfo_endpoint](#userinfo_endpoint) or [introspection_endpoint](#introspection_endpoint) the retrieve these claims
|
Send the access_token to the [userinfo_endpoint](#userinfo-endpoint) or [introspection_endpoint](#introspection-endpoint) the retrieve these claims
|
||||||
or set the `id_token_userinfo_assertion` Option ("User Info inside ID Token" in Management Console) to true.
|
or set the `id_token_userinfo_assertion` Option ("User Info inside ID Token" in Management Console) to true.
|
||||||
:::
|
</Callout>
|
||||||
|
|
||||||
Depending on your authorization method you will have to provide additional parameters or headers:
|
Depending on your authorization method you will have to provide additional parameters or headers:
|
||||||
|
|
||||||
@@ -72,13 +70,13 @@ Depending on your authorization method you will have to provide additional param
|
|||||||
{label: 'private_key_jwt', value: 'private_key_jwt'},
|
{label: 'private_key_jwt', value: 'private_key_jwt'},
|
||||||
]}
|
]}
|
||||||
>
|
>
|
||||||
<TabItem value="client_secret_basic">
|
<Tab value="client_secret_basic">
|
||||||
no additional parameters required
|
no additional parameters required
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="client_secret_post">
|
<Tab value="client_secret_post">
|
||||||
no additional parameters required
|
no additional parameters required
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="none">
|
<Tab value="none">
|
||||||
|
|
||||||
| Parameter | Description |
|
| Parameter | Description |
|
||||||
| --------------------- | ----------------------------------------------------- |
|
| --------------------- | ----------------------------------------------------- |
|
||||||
@@ -87,10 +85,10 @@ no additional parameters required
|
|||||||
|
|
||||||
see PKCE guide for more information
|
see PKCE guide for more information
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="private_key_jwt">
|
<Tab value="private_key_jwt">
|
||||||
no additional parameters required
|
no additional parameters required
|
||||||
</TabItem>
|
</Tab>
|
||||||
</Tabs>
|
</Tabs>
|
||||||
|
|
||||||
### Additional parameters
|
### Additional parameters
|
||||||
@@ -108,6 +106,7 @@ no additional parameters required
|
|||||||
|
|
||||||
#### Response modes
|
#### Response modes
|
||||||
|
|
||||||
|
ZITADEL supports the following `response_mode` values. When no response mode is requested, the response mode is chosen based on the configured Response Type of the application.
|
||||||
ZITADEL supports the following `response_mode` values. When no response mode is requested, the response mode is chosen based on the configured Response Type of the application.
|
ZITADEL supports the following `response_mode` values. When no response mode is requested, the response mode is chosen based on the configured Response Type of the application.
|
||||||
As per [OpenID Connect Core 1.0, Section 3.1.2.1](https://openid.net/specs/openid-connect-core-1_0.html#AuthRequest):
|
As per [OpenID Connect Core 1.0, Section 3.1.2.1](https://openid.net/specs/openid-connect-core-1_0.html#AuthRequest):
|
||||||
|
|
||||||
@@ -115,8 +114,8 @@ As per [OpenID Connect Core 1.0, Section 3.1.2.1](https://openid.net/specs/openi
|
|||||||
|
|
||||||
| Response Mode | Description |
|
| Response Mode | Description |
|
||||||
| ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| query | Encode the returned parameters in the URL query string. This is the default when the Response type is `code`, for example [Web applications](/docs/guides/manage/console/applications-overview#web). |
|
| query | Encode the returned parameters in the URL query string. This is the default when the Response type is `code`, for example [Web applications](/guides/manage/console/applications-overview#web). |
|
||||||
| fragment | Encode the returned parameters in the URL fragment. This is the default when the Response Type is `id_token`, for example implicit [User Agent apps](/docs/guides/manage/console/applications-overview#user-agent). This mode will not work for server-side applications, because fragments are never sent by the browser to the server. |
|
| fragment | Encode the returned parameters in the URL fragment. This is the default when the Response Type is `id_token`, for example implicit [User Agent apps](/guides/manage/console/applications-overview#user-agent). This mode will not work for server-side applications, because fragments are never sent by the browser to the server. |
|
||||||
| form_post[^1] | ZITADEL serves a small JavaScript to the browser which will send the returned parameters to the `redirect_uri` using HTTP POST. This mode only works for server-side applications and user agents which support / allow JavaScript. |
|
| form_post[^1] | ZITADEL serves a small JavaScript to the browser which will send the returned parameters to the `redirect_uri` using HTTP POST. This mode only works for server-side applications and user agents which support / allow JavaScript. |
|
||||||
|
|
||||||
[^1]: Implements [OAuth 2.0 Form Post Response Mode](https://openid.net/specs/oauth-v2-form-post-response-mode-1_0.html)
|
[^1]: Implements [OAuth 2.0 Form Post Response Mode](https://openid.net/specs/oauth-v2-form-post-response-mode-1_0.html)
|
||||||
@@ -147,10 +146,10 @@ When your `response_type` was either `id_token` or `id_token token` and no error
|
|||||||
|
|
||||||
Regardless of the authorization flow chosen, if an error occurs the following response will be returned to the redirect_uri.
|
Regardless of the authorization flow chosen, if an error occurs the following response will be returned to the redirect_uri.
|
||||||
|
|
||||||
:::note
|
<Callout>
|
||||||
If the redirect_uri is not provided, was not registered or anything other prevents the auth server form returning the response to the client,
|
If the redirect_uri is not provided, was not registered or anything other prevents the auth server form returning the response to the client,
|
||||||
the error will be display directly to the user on the auth server
|
the error will be display directly to the user on the auth server
|
||||||
:::
|
</Callout>
|
||||||
|
|
||||||
| Property | Description |
|
| Property | Description |
|
||||||
| ----------------- | -------------------------------------------------------------------- |
|
| ----------------- | -------------------------------------------------------------------- |
|
||||||
@@ -158,8 +157,7 @@ the error will be display directly to the user on the auth server
|
|||||||
| error_description | Description of the error type or additional information of the error |
|
| error_description | Description of the error type or additional information of the error |
|
||||||
| state | Unmodified `state` parameter from the request |
|
| state | Unmodified `state` parameter from the request |
|
||||||
|
|
||||||
#### Possible errors {#authorize-errors}
|
#### Possible errors
|
||||||
|
|
||||||
| error_type | Possible reason |
|
| error_type | Possible reason |
|
||||||
| ------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| invalid_request | The request is missing a required parameter, includes an invalid parameter value, includes a parameter more than once, or is otherwise malformed. |
|
| invalid_request | The request is missing a required parameter, includes an invalid parameter value, includes a parameter more than once, or is otherwise malformed. |
|
||||||
@@ -202,12 +200,12 @@ Depending on your authorization method you will have to provide additional param
|
|||||||
{label: 'private_key_jwt', value: 'private_key_jwt'},
|
{label: 'private_key_jwt', value: 'private_key_jwt'},
|
||||||
]}
|
]}
|
||||||
>
|
>
|
||||||
<TabItem value="client_secret_basic">
|
<Tab value="client_secret_basic">
|
||||||
|
|
||||||
Send your `client_id` and `client_secret` as Basic Auth Header. Check [Client Secret Basic Auth Method](authn-methods#client-secret-basic) on how to build it correctly.
|
Send your `client_id` and `client_secret` as Basic Auth Header. Check [Client Secret Basic Auth Method](./authn-methods#client-secret-basic) on how to build it correctly.
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="client_secret_post">
|
<Tab value="client_secret_post">
|
||||||
|
|
||||||
Send your `client_id` and `client_secret` as parameters in the body:
|
Send your `client_id` and `client_secret` as parameters in the body:
|
||||||
|
|
||||||
@@ -216,8 +214,8 @@ Send your `client_id` and `client_secret` as parameters in the body:
|
|||||||
| client_id | client_id of the application |
|
| client_id | client_id of the application |
|
||||||
| client_secret | client_secret of the application |
|
| client_secret | client_secret of the application |
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="none">
|
<Tab value="none">
|
||||||
|
|
||||||
Send your `client_id` and `code_verifier` for us to recompute the `code_challenge` of the authorization request.
|
Send your `client_id` and `code_verifier` for us to recompute the `code_challenge` of the authorization request.
|
||||||
|
|
||||||
@@ -226,21 +224,20 @@ Send your `client_id` and `code_verifier` for us to recompute the `code_challeng
|
|||||||
| client_id | client_id of the application |
|
| client_id | client_id of the application |
|
||||||
| code_verifier | code_verifier previously used to generate the code_challenge |
|
| code_verifier | code_verifier previously used to generate the code_challenge |
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="private_key_jwt">
|
<Tab value="private_key_jwt">
|
||||||
|
|
||||||
Send a client assertion as JWT for us to validate the signature against the registered public key.
|
Send a client assertion as JWT for us to validate the signature against the registered public key.
|
||||||
|
|
||||||
| Parameter | Description |
|
| Parameter | Description |
|
||||||
| --------------------- | ------------------------------------------------------------------------------------------------------------ |
|
| --------------------- | ------------------------------------------------------------------------------------------------------------ |
|
||||||
| client_assertion | JWT built and signed according to [Using JWTs for Client Authentication](authn-methods#jwt-with-private-key) |
|
| client_assertion | JWT built and signed according to [Using JWTs for Client Authentication](./authn-methods#jwt-with-private-key) |
|
||||||
| client_assertion_type | Must be `urn:ietf:params:oauth:client-assertion-type:jwt-bearer` |
|
| client_assertion_type | Must be `urn:ietf:params:oauth:client-assertion-type:jwt-bearer` |
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
</Tabs>
|
</Tabs>
|
||||||
|
|
||||||
#### Successful code response {#token-code-response}
|
#### Successful code response
|
||||||
|
|
||||||
| Property | Description |
|
| Property | Description |
|
||||||
| ------------- | ------------------------------------------------------------------------------------- |
|
| ------------- | ------------------------------------------------------------------------------------- |
|
||||||
| access_token | An `access_token` as JWT or opaque token |
|
| access_token | An `access_token` as JWT or opaque token |
|
||||||
@@ -257,10 +254,10 @@ Send a client assertion as JWT for us to validate the signature against the regi
|
|||||||
| Parameter | Description |
|
| Parameter | Description |
|
||||||
| ---------- | ----------------------------------------------------------------------------------------------------------------------- |
|
| ---------- | ----------------------------------------------------------------------------------------------------------------------- |
|
||||||
| grant_type | Must be `urn:ietf:params:oauth:grant-type:jwt-bearer` |
|
| grant_type | Must be `urn:ietf:params:oauth:grant-type:jwt-bearer` |
|
||||||
| assertion | JWT built and signed according to [Using JWTs for Authorization Grants](grant-types#using-jwts-as-authorization-grants) |
|
| assertion | JWT built and signed according to [Using JWTs for Authorization Grants](./grant-types#using-jw-ts-as-authorization-grants) |
|
||||||
| scope | [Scopes](scopes) you would like to request from ZITADEL. Scopes are space delimited, e.g. `openid email profile` |
|
| scope | [Scopes](./scopes) you would like to request from ZITADEL. Scopes are space delimited, e.g. `openid email profile` |
|
||||||
|
|
||||||
```BASH
|
```bash
|
||||||
curl --request POST \
|
curl --request POST \
|
||||||
--url ${CUSTOM_DOMAIN}/oauth/v2/token \
|
--url ${CUSTOM_DOMAIN}/oauth/v2/token \
|
||||||
--header 'Content-Type: application/x-www-form-urlencoded' \
|
--header 'Content-Type: application/x-www-form-urlencoded' \
|
||||||
@@ -268,8 +265,7 @@ curl --request POST \
|
|||||||
--data assertion=eyJhbGciOiJSUzI1Ni...
|
--data assertion=eyJhbGciOiJSUzI1Ni...
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Successful JWT profile response {#token-jwt-response}
|
#### Successful JWT profile response
|
||||||
|
|
||||||
| Property | Description |
|
| Property | Description |
|
||||||
| ------------ | ------------------------------------------------------------------------------------- |
|
| ------------ | ------------------------------------------------------------------------------------- |
|
||||||
| access_token | An `access_token` as JWT or opaque token |
|
| access_token | An `access_token` as JWT or opaque token |
|
||||||
@@ -281,7 +277,7 @@ curl --request POST \
|
|||||||
### Refresh token grant
|
### Refresh token grant
|
||||||
|
|
||||||
To request a new `access_token` without user interaction, you can use the `refresh_token` grant.
|
To request a new `access_token` without user interaction, you can use the `refresh_token` grant.
|
||||||
See [offline_access Scope](scopes#standard-scopes) for how to request a `refresh_token` in the authorization request.
|
See [offline_access Scope](./scopes#standard-scopes) for how to request a `refresh_token` in the authorization request.
|
||||||
|
|
||||||
#### Required request parameters
|
#### Required request parameters
|
||||||
|
|
||||||
@@ -289,7 +285,7 @@ See [offline_access Scope](scopes#standard-scopes) for how to request a `refresh
|
|||||||
| ------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| grant_type | Must be `refresh_token` |
|
| grant_type | Must be `refresh_token` |
|
||||||
| refresh_token | The refresh_token previously issued in the last authorization_code or refresh_token request. |
|
| refresh_token | The refresh_token previously issued in the last authorization_code or refresh_token request. |
|
||||||
| scope | [Scopes](scopes) you would like to request from ZITADEL for the new access_token. Must be a subset of the scope originally requested by the corresponding auth request. When omitted, the scopes requested by the original auth request will be reused. Scopes are space delimited, e.g. `openid email profile` |
|
| scope | [Scopes](./scopes) you would like to request from ZITADEL for the new access_token. Must be a subset of the scope originally requested by the corresponding auth request. When omitted, the scopes requested by the original auth request will be reused. Scopes are space delimited, e.g. `openid email profile` |
|
||||||
|
|
||||||
Depending on your authorization method you will have to provide additional parameters or headers:
|
Depending on your authorization method you will have to provide additional parameters or headers:
|
||||||
|
|
||||||
@@ -303,12 +299,12 @@ Depending on your authorization method you will have to provide additional param
|
|||||||
{label: 'private_key_jwt', value: 'private_key_jwt'},
|
{label: 'private_key_jwt', value: 'private_key_jwt'},
|
||||||
]}
|
]}
|
||||||
>
|
>
|
||||||
<TabItem value="client_secret_basic">
|
<Tab value="client_secret_basic">
|
||||||
|
|
||||||
Send your `client_id` and `client_secret` as Basic Auth Header. Check [Client Secret Basic Auth Method](authn-methods#client-secret-basic) on how to build it correctly.
|
Send your `client_id` and `client_secret` as Basic Auth Header. Check [Client Secret Basic Auth Method](./authn-methods#client-secret-basic) on how to build it correctly.
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="client_secret_post">
|
<Tab value="client_secret_post">
|
||||||
|
|
||||||
Send your `client_id` and `client_secret` as parameters in the body:
|
Send your `client_id` and `client_secret` as parameters in the body:
|
||||||
|
|
||||||
@@ -317,26 +313,25 @@ Send your `client_id` and `client_secret` as parameters in the body:
|
|||||||
| client_id | client_id of the application |
|
| client_id | client_id of the application |
|
||||||
| client_secret | client_secret of the application |
|
| client_secret | client_secret of the application |
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="none">
|
<Tab value="none">
|
||||||
|
|
||||||
Send your `client_id` as parameter in the body. No authentication is required.
|
Send your `client_id` as parameter in the body. No authentication is required.
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="private_key_jwt">
|
<Tab value="private_key_jwt">
|
||||||
|
|
||||||
Send a `client_assertion` as JWT for us to validate the signature against the registered public key.
|
Send a `client_assertion` as JWT for us to validate the signature against the registered public key.
|
||||||
|
|
||||||
| Parameter | Description |
|
| Parameter | Description |
|
||||||
| --------------------- | ------------------------------------------------------------------------------------------------------------ |
|
| --------------------- | ------------------------------------------------------------------------------------------------------------ |
|
||||||
| client_assertion | JWT built and signed according to [Using JWTs for Client Authentication](authn-methods#jwt-with-private-key) |
|
| client_assertion | JWT built and signed according to [Using JWTs for Client Authentication](./authn-methods#jwt-with-private-key) |
|
||||||
| client_assertion_type | Must be `urn:ietf:params:oauth:client-assertion-type:jwt-bearer` |
|
| client_assertion_type | Must be `urn:ietf:params:oauth:client-assertion-type:jwt-bearer` |
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
</Tabs>
|
</Tabs>
|
||||||
|
|
||||||
#### Successful refresh token response {#token-refresh-response}
|
#### Successful refresh token response
|
||||||
|
|
||||||
| Property | Description |
|
| Property | Description |
|
||||||
| ------------- | ------------------------------------------------------------------------------------- |
|
| ------------- | ------------------------------------------------------------------------------------- |
|
||||||
| access_token | An `access_token` as JWT or opaque token |
|
| access_token | An `access_token` as JWT or opaque token |
|
||||||
@@ -353,12 +348,12 @@ Send a `client_assertion` as JWT for us to validate the signature against the re
|
|||||||
| Parameter | Description |
|
| Parameter | Description |
|
||||||
| ---------- | ---------------------------------------------------------------------------------------------------------- |
|
| ---------- | ---------------------------------------------------------------------------------------------------------- |
|
||||||
| grant_type | Must be `client_credentials` |
|
| grant_type | Must be `client_credentials` |
|
||||||
| scope | [Scopes](scopes) you would like to request from ZITADEL. Scopes are space delimited, e.g. `openid profile` |
|
| scope | [Scopes](./scopes) you would like to request from ZITADEL. Scopes are space delimited, e.g. `openid profile` |
|
||||||
|
|
||||||
Additionally, you need to authenticate your client by either sending `client_id` and `client_secret` as Basic Auth Header.
|
Additionally, you need to authenticate your client by either sending `client_id` and `client_secret` as Basic Auth Header.
|
||||||
Check [Client Secret Basic Auth Method](authn-methods#client-secret-basic) on how to build it correctly.
|
Check [Client Secret Basic Auth Method](./authn-methods#client-secret-basic) on how to build it correctly.
|
||||||
|
|
||||||
```BASH
|
```bash
|
||||||
curl --request POST \
|
curl --request POST \
|
||||||
--url ${CUSTOM_DOMAIN}/oauth/v2/token \
|
--url ${CUSTOM_DOMAIN}/oauth/v2/token \
|
||||||
--header 'Content-Type: application/x-www-form-urlencoded' \
|
--header 'Content-Type: application/x-www-form-urlencoded' \
|
||||||
@@ -374,7 +369,7 @@ Or you can also send your `client_id` and `client_secret` as parameters in the b
|
|||||||
| client_id | client_id of the application |
|
| client_id | client_id of the application |
|
||||||
| client_secret | client_secret of the application |
|
| client_secret | client_secret of the application |
|
||||||
|
|
||||||
```BASH
|
```bash
|
||||||
curl --request POST \
|
curl --request POST \
|
||||||
--url ${CUSTOM_DOMAIN}/oauth/v2/token \
|
--url ${CUSTOM_DOMAIN}/oauth/v2/token \
|
||||||
--header 'Content-Type: application/x-www-form-urlencoded' \
|
--header 'Content-Type: application/x-www-form-urlencoded' \
|
||||||
@@ -384,8 +379,7 @@ curl --request POST \
|
|||||||
--data scope=openid profile
|
--data scope=openid profile
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Successful client credentials response {#token-client-credentials-response}
|
#### Successful client credentials response
|
||||||
|
|
||||||
| Property | Description |
|
| Property | Description |
|
||||||
| ------------ | ------------------------------------------------------------------------------------- |
|
| ------------ | ------------------------------------------------------------------------------------- |
|
||||||
| access_token | An `access_token` as JWT or opaque token |
|
| access_token | An `access_token` as JWT or opaque token |
|
||||||
@@ -395,15 +389,15 @@ curl --request POST \
|
|||||||
|
|
||||||
### Token Exchange grant
|
### Token Exchange grant
|
||||||
|
|
||||||
The Token Exchange grant implements [RFC 8693, OAuth 2.0 Token Exchange](https://www.rfc-editor.org/rfc/rfc8693) and can be used to exchange tokens to a different scope, audience or subject. Changing the subject of an authenticated token is called impersonation or delegation. ZITADEL also provides a [token exchange guide](/docs/guides/integrate/token-exchange) with more details on using the Token Exchange Grant.
|
The Token Exchange grant implements [RFC 8693, OAuth 2.0 Token Exchange](https://www.rfc-editor.org/rfc/rfc8693) and can be used to exchange tokens to a different scope, audience or subject. Changing the subject of an authenticated token is called impersonation or delegation. ZITADEL also provides a [token exchange guide](/guides/integrate/token-exchange) with more details on using the Token Exchange Grant.
|
||||||
|
|
||||||
:::info
|
<Callout>
|
||||||
Token Exchange is currently an experimental [beta](https://help.zitadel.com/zitadel-software-release-cycle#beta) feature. Be sure to enable it on the [feature API](/docs/guides/integrate/token-exchange#feature-api) before using it.
|
Token Exchange is currently an experimental [beta](https://help.zitadel.com/zitadel-software-release-cycle#beta) feature. Be sure to enable it on the [feature API](/guides/integrate/token-exchange#feature-api) before using it.
|
||||||
:::
|
</Callout>
|
||||||
|
|
||||||
#### Request parameters
|
#### Request parameters
|
||||||
|
|
||||||
<TokenExchangeRequest />
|
<TokenExchangeRequest components={props.components} />
|
||||||
|
|
||||||
Depending on your authorization method you will have to provide additional parameters or headers:
|
Depending on your authorization method you will have to provide additional parameters or headers:
|
||||||
|
|
||||||
@@ -418,12 +412,12 @@ Depending on your authorization method you will have to provide additional param
|
|||||||
]}
|
]}
|
||||||
>
|
>
|
||||||
|
|
||||||
<TabItem value="client_secret_basic">
|
<Tab value="client_secret_basic">
|
||||||
|
|
||||||
Send your `client_id` and `client_secret` as Basic Auth Header. Check [Client Secret Basic Auth Method](authn-methods#client-secret-basic) on how to build it correctly.
|
Send your `client_id` and `client_secret` as Basic Auth Header. Check [Client Secret Basic Auth Method](./authn-methods#client-secret-basic) on how to build it correctly.
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="client_secret_post">
|
<Tab value="client_secret_post">
|
||||||
|
|
||||||
Send your `client_id` and `client_secret` as parameters in the body:
|
Send your `client_id` and `client_secret` as parameters in the body:
|
||||||
|
|
||||||
@@ -432,31 +426,30 @@ Send your `client_id` and `client_secret` as parameters in the body:
|
|||||||
| client_id | client_id of the application |
|
| client_id | client_id of the application |
|
||||||
| client_secret | client_secret of the application |
|
| client_secret | client_secret of the application |
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="none">
|
<Tab value="none">
|
||||||
|
|
||||||
Send your `client_id` as parameter in the body. No authentication is required.
|
Send your `client_id` as parameter in the body. No authentication is required.
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="private_key_jwt">
|
<Tab value="private_key_jwt">
|
||||||
|
|
||||||
Send a `client_assertion` as JWT for us to validate the signature against the registered public key.
|
Send a `client_assertion` as JWT for us to validate the signature against the registered public key.
|
||||||
|
|
||||||
| Parameter | Description |
|
| Parameter | Description |
|
||||||
| --------------------- | ------------------------------------------------------------------------------------------------------------ |
|
| --------------------- | ------------------------------------------------------------------------------------------------------------ |
|
||||||
| client_assertion | JWT built and signed according to [Using JWTs for Client Authentication](authn-methods#jwt-with-private-key) |
|
| client_assertion | JWT built and signed according to [Using JWTs for Client Authentication](./authn-methods#jwt-with-private-key) |
|
||||||
| client_assertion_type | Must be `urn:ietf:params:oauth:client-assertion-type:jwt-bearer` |
|
| client_assertion_type | Must be `urn:ietf:params:oauth:client-assertion-type:jwt-bearer` |
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
</Tabs>
|
</Tabs>
|
||||||
|
|
||||||
#### Successful token exchange response {#token-exchange-response}
|
#### Successful token exchange response
|
||||||
|
<TokenExchangeResponse components={props.components} />
|
||||||
<TokenExchangeResponse />
|
|
||||||
|
|
||||||
#### Token types
|
#### Token types
|
||||||
|
|
||||||
<TokenExchangeTypes />
|
<TokenExchangeTypes components={props.components} />
|
||||||
|
|
||||||
### Error response
|
### Error response
|
||||||
|
|
||||||
@@ -491,11 +484,11 @@ values={[
|
|||||||
{label: 'private_key_jwt', value: 'private_key_jwt'},
|
{label: 'private_key_jwt', value: 'private_key_jwt'},
|
||||||
]}
|
]}
|
||||||
>
|
>
|
||||||
<TabItem value="client_secret_basic">
|
<Tab value="client_secret_basic">
|
||||||
|
|
||||||
Send your `client_id` and `client_secret` as Basic Auth Header. Check [Client Secret Basic Auth Method](authn-methods#client-secret-basic) on how to build it correctly.
|
Send your `client_id` and `client_secret` as Basic Auth Header. Check [Client Secret Basic Auth Method](./authn-methods#client-secret-basic) on how to build it correctly.
|
||||||
|
|
||||||
```BASH
|
```bash
|
||||||
curl --request POST \
|
curl --request POST \
|
||||||
--url ${CUSTOM_DOMAIN}/oauth/v2/introspect \
|
--url ${CUSTOM_DOMAIN}/oauth/v2/introspect \
|
||||||
--header 'Content-Type: application/x-www-form-urlencoded' \
|
--header 'Content-Type: application/x-www-form-urlencoded' \
|
||||||
@@ -503,18 +496,18 @@ curl --request POST \
|
|||||||
--data token=VjVxyCZmRmWYqd3_F5db9Pb9mHR5fqzhn...
|
--data token=VjVxyCZmRmWYqd3_F5db9Pb9mHR5fqzhn...
|
||||||
```
|
```
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
|
|
||||||
<TabItem value="private_key_jwt">
|
<Tab value="private_key_jwt">
|
||||||
|
|
||||||
Send a `client_assertion` as JWT for us to validate the signature against the registered public key.
|
Send a `client_assertion` as JWT for us to validate the signature against the registered public key.
|
||||||
|
|
||||||
| Parameter | Description |
|
| Parameter | Description |
|
||||||
| --------------------- | ----------------------------------------------------------------------------------------------------------- |
|
| --------------------- | ----------------------------------------------------------------------------------------------------------- |
|
||||||
| client_assertion | JWT built and signed according to [Using JWTs for Client Authentication](authn-methods#client-secret-basic) |
|
| client_assertion | JWT built and signed according to [Using JWTs for Client Authentication](./authn-methods#client-secret-basic) |
|
||||||
| client_assertion_type | must be `urn:ietf:params:oauth:client-assertion-type:jwt-bearer` |
|
| client_assertion_type | must be `urn:ietf:params:oauth:client-assertion-type:jwt-bearer` |
|
||||||
|
|
||||||
```BASH
|
```bash
|
||||||
curl --request POST \
|
curl --request POST \
|
||||||
--url ${CUSTOM_DOMAIN}/oauth/v2/introspect \
|
--url ${CUSTOM_DOMAIN}/oauth/v2/introspect \
|
||||||
--header 'Content-Type: application/x-www-form-urlencoded' \
|
--header 'Content-Type: application/x-www-form-urlencoded' \
|
||||||
@@ -523,11 +516,10 @@ curl --request POST \
|
|||||||
--data token=VjVxyCZmRmWYqd3_F5db9Pb9mHR5fqzhn...
|
--data token=VjVxyCZmRmWYqd3_F5db9Pb9mHR5fqzhn...
|
||||||
```
|
```
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
</Tabs>
|
</Tabs>
|
||||||
|
|
||||||
### Successful introspection response {#introspect-response}
|
### Successful introspection response
|
||||||
|
|
||||||
Upon successful authorization of the client a response with the boolean `active` is returned, indicating if the provided token
|
Upon successful authorization of the client a response with the boolean `active` is returned, indicating if the provided token
|
||||||
is active and the requesting client is part of the token audience.
|
is active and the requesting client is part of the token audience.
|
||||||
|
|
||||||
@@ -547,10 +539,9 @@ If `active` is **true**, further information will be provided:
|
|||||||
| username | ZITADEL's login name of the user. Consist of `username@primarydomain` |
|
| username | ZITADEL's login name of the user. Consist of `username@primarydomain` |
|
||||||
|
|
||||||
Additionally and depending on the granted scopes, information about the authorized user is provided.
|
Additionally and depending on the granted scopes, information about the authorized user is provided.
|
||||||
Check the [Claims](claims) page if a specific claims might be returned and for detailed description.
|
Check the [Claims](./claims) page if a specific claims might be returned and for detailed description.
|
||||||
|
|
||||||
### Error response {#introspect-error-response}
|
|
||||||
|
|
||||||
|
### Error response
|
||||||
If the authorization fails, an HTTP 401 with `invalid_client` will be returned.
|
If the authorization fails, an HTTP 401 with `invalid_client` will be returned.
|
||||||
|
|
||||||
## userinfo_endpoint
|
## userinfo_endpoint
|
||||||
@@ -561,19 +552,17 @@ This endpoint will return information about the authorized user.
|
|||||||
|
|
||||||
Send the `access_token` of the **user** (not the client) as Bearer Token in the `authorization` header:
|
Send the `access_token` of the **user** (not the client) as Bearer Token in the `authorization` header:
|
||||||
|
|
||||||
```BASH
|
```bash
|
||||||
curl --request GET \
|
curl --request GET \
|
||||||
--url ${CUSTOM_DOMAIN}/oidc/v1/userinfo
|
--url ${CUSTOM_DOMAIN}/oidc/v1/userinfo
|
||||||
--header 'Authorization: Bearer dsfdsjk29fm2as...'
|
--header 'Authorization: Bearer dsfdsjk29fm2as...'
|
||||||
```
|
```
|
||||||
|
|
||||||
### Successful userinfo response {#userinfo-response}
|
### Successful userinfo response
|
||||||
|
|
||||||
If the `access_token` is valid, the information about the user depending on the granted scopes is returned.
|
If the `access_token` is valid, the information about the user depending on the granted scopes is returned.
|
||||||
Check the [Claims](claims) page if a specific claims might be returned and for detailed description.
|
Check the [Claims](./claims) page if a specific claims might be returned and for detailed description.
|
||||||
|
|
||||||
### Error response {#userinfo-error-response}
|
|
||||||
|
|
||||||
|
### Error response
|
||||||
If the token is invalid or expired, an HTTP 401 will be returned.
|
If the token is invalid or expired, an HTTP 401 will be returned.
|
||||||
|
|
||||||
## revocation_endpoint
|
## revocation_endpoint
|
||||||
@@ -582,10 +571,10 @@ If the token is invalid or expired, an HTTP 401 will be returned.
|
|||||||
|
|
||||||
This endpoint enables clients to revoke an `access_token` or `refresh_token` they have been granted.
|
This endpoint enables clients to revoke an `access_token` or `refresh_token` they have been granted.
|
||||||
|
|
||||||
:::important
|
<Callout>
|
||||||
If you revoke an `access_token` only the specific token will be revoked. When revoking a `refresh_token`,
|
If you revoke an `access_token` only the specific token will be revoked. When revoking a `refresh_token`,
|
||||||
the corresponding `access_token` will be revoked as well.
|
the corresponding `access_token` will be revoked as well.
|
||||||
:::
|
</Callout>
|
||||||
|
|
||||||
| Parameter | Description |
|
| Parameter | Description |
|
||||||
| --------- | -------------------------------- |
|
| --------- | -------------------------------- |
|
||||||
@@ -603,12 +592,12 @@ values={[
|
|||||||
{label: 'private_key_jwt', value: 'private_key_jwt'},
|
{label: 'private_key_jwt', value: 'private_key_jwt'},
|
||||||
]}
|
]}
|
||||||
>
|
>
|
||||||
<TabItem value="client_secret_basic">
|
<Tab value="client_secret_basic">
|
||||||
|
|
||||||
Send your `client_id` and `client_secret` as Basic Auth Header. Check [Client Secret Basic Auth Method](authn-methods#client-secret-basic) on how to construct a request correctly.
|
Send your `client_id` and `client_secret` as Basic Auth Header. Check [Client Secret Basic Auth Method](./authn-methods#client-secret-basic) on how to construct a request correctly.
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="client_secret_post">
|
<Tab value="client_secret_post">
|
||||||
|
|
||||||
Send your `client_id` and `client_secret` as parameters in the body:
|
Send your `client_id` and `client_secret` as parameters in the body:
|
||||||
|
|
||||||
@@ -617,8 +606,8 @@ Send your `client_id` and `client_secret` as parameters in the body:
|
|||||||
| client_id | client_id of the application |
|
| client_id | client_id of the application |
|
||||||
| client_secret | client_secret of the application |
|
| client_secret | client_secret of the application |
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="none">
|
<Tab value="none">
|
||||||
|
|
||||||
Send your `client_id` as parameters in the body:
|
Send your `client_id` as parameters in the body:
|
||||||
|
|
||||||
@@ -626,17 +615,17 @@ Send your `client_id` as parameters in the body:
|
|||||||
| --------- | ---------------------------- |
|
| --------- | ---------------------------- |
|
||||||
| client_id | client_id of the application |
|
| client_id | client_id of the application |
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
<TabItem value="private_key_jwt">
|
<Tab value="private_key_jwt">
|
||||||
|
|
||||||
Send a `client_assertion` as JWT for ZITADEL to verify the signature against the registered public key.
|
Send a `client_assertion` as JWT for ZITADEL to verify the signature against the registered public key.
|
||||||
|
|
||||||
| Parameter | Description |
|
| Parameter | Description |
|
||||||
| --------------------- | ------------------------------------------------------------------------------------------------------------- |
|
| --------------------- | ------------------------------------------------------------------------------------------------------------- |
|
||||||
| client_assertion | JWT created and signed according to [Using JWTs for Client Authentication](authn-methods#client-secret-basic) |
|
| client_assertion | JWT created and signed according to [Using JWTs for Client Authentication](./authn-methods#client-secret-basic) |
|
||||||
| client_assertion_type | must be `urn:ietf:params:oauth:client-assertion-type:jwt-bearer` |
|
| client_assertion_type | must be `urn:ietf:params:oauth:client-assertion-type:jwt-bearer` |
|
||||||
|
|
||||||
```BASH
|
```bash
|
||||||
curl --request POST \
|
curl --request POST \
|
||||||
--url ${CUSTOM_DOMAIN}/oauth/v2/revoke \
|
--url ${CUSTOM_DOMAIN}/oauth/v2/revoke \
|
||||||
--header 'Content-Type: application/x-www-form-urlencoded' \
|
--header 'Content-Type: application/x-www-form-urlencoded' \
|
||||||
@@ -645,7 +634,7 @@ curl --request POST \
|
|||||||
--data token=VjVxyCZmRmWYqd3_F5db9Pb9mHR5fqzhn...
|
--data token=VjVxyCZmRmWYqd3_F5db9Pb9mHR5fqzhn...
|
||||||
```
|
```
|
||||||
|
|
||||||
</TabItem>
|
</Tab>
|
||||||
</Tabs>
|
</Tabs>
|
||||||
|
|
||||||
## end_session_endpoint
|
## end_session_endpoint
|
||||||
@@ -675,16 +664,16 @@ If neither an `id_token_hint` nor a `client_id` parameter is provided, the `post
|
|||||||
`${CUSTOM_DOMAIN}/oauth/v2/keys`
|
`${CUSTOM_DOMAIN}/oauth/v2/keys`
|
||||||
|
|
||||||
The endpoint returns a JSON Web Key Set (JWKS) containing the public keys that can be used to locally validate JWTs you received from ZITADEL.
|
The endpoint returns a JSON Web Key Set (JWKS) containing the public keys that can be used to locally validate JWTs you received from ZITADEL.
|
||||||
The alternative would be to validate tokens with the [introspection endpoint](#introspection_endpoint).
|
The alternative would be to validate tokens with the [introspection endpoint](#introspection-endpoint).
|
||||||
|
|
||||||
### Key rotation
|
### Key rotation
|
||||||
|
|
||||||
Keys are automatically rotated on a regular basis or on demand, meaning keys can change in irregular intervals.
|
Keys are automatically rotated on a regular basis or on demand, meaning keys can change in irregular intervals.
|
||||||
ZITADEL ensures that a proper `kid` is set with each key.
|
ZITADEL ensures that a proper `kid` is set with each key.
|
||||||
|
|
||||||
:::info Keys rotate without prior notice
|
<Callout title="Keys rotate without prior notice">
|
||||||
Be aware that these keys can be rotated without any prior notice.
|
Be aware that these keys can be rotated without any prior notice.
|
||||||
:::
|
</Callout>
|
||||||
|
|
||||||
### Caching
|
### Caching
|
||||||
|
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user