docs: describe combinations of flow and trigger types (#7519)

* docs(api): describe which flow and trigger types word together

* docs(actions): describe which flow and trigger types work together

* Update management.proto

---------

Co-authored-by: Livio Spring <livio.a@gmail.com>
This commit is contained in:
Silvan
2024-03-11 08:24:24 +01:00
committed by GitHub
parent 07ec2efa9d
commit 7b537243c4
5 changed files with 50 additions and 5 deletions

View File

@@ -4,10 +4,14 @@ title: Complement Token Flow
This flow is executed during the creation of tokens and token introspection. This flow is executed during the creation of tokens and token introspection.
The flow is represented by the following Ids in the API: `2`
## Pre Userinfo creation (id_token / userinfo / introspection endpoint) ## Pre Userinfo creation (id_token / userinfo / introspection endpoint)
This trigger is called before userinfo are set in the id_token or userinfo and introspection endpoint response. This trigger is called before userinfo are set in the id_token or userinfo and introspection endpoint response.
The trigger is represented by the following Ids in the API: `4`
### Parameters of Pre Userinfo creation ### Parameters of Pre Userinfo creation
- `ctx` - `ctx`
@@ -38,6 +42,8 @@ This trigger is called before userinfo are set in the id_token or userinfo and i
This trigger is called before the claims are set in the access token and the token type is `jwt`. This trigger is called before the claims are set in the access token and the token type is `jwt`.
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`

View File

@@ -2,12 +2,16 @@
title: Complement SAMLResponse title: Complement SAMLResponse
--- ---
This flow is executed before the return of the SAMLResponse. This flow is executed before the return of the SAML Response.
The flow is represented by the following Ids in the API: `4`
## Pre SAMLResponse creation ## Pre SAMLResponse creation
This trigger is called before attributes are set in the SAMLResponse. This trigger is called before attributes are set in the SAMLResponse.
The trigger is represented by the following Ids in the API: `6`.
### Parameters of Pre SAMLResponse creation ### Parameters of Pre SAMLResponse creation
- `ctx` - `ctx`

View File

@@ -4,10 +4,14 @@ title: External Authentication Flow
This flow is executed if the user logs in using an [identity provider](/guides/integrate/identity-providers) or using a [jwt token](/concepts/structure/jwt_idp). This flow is executed if the user logs in using an [identity provider](/guides/integrate/identity-providers) or using a [jwt token](/concepts/structure/jwt_idp).
The flow is represented by the following Ids in the API: `FLOW_TYPE_EXTERNAL_AUTHENTICATION` and `1`
## Post Authentication ## Post Authentication
A user has authenticated externally. ZITADEL retrieved and mapped the external information. A user has authenticated externally. ZITADEL retrieved and mapped the external information.
The trigger is represented by the following Ids in the API: `TRIGGER_TYPE_POST_AUTHENTICATION` or `1`.
### Parameters of Post Authentication Action ### Parameters of Post Authentication Action
- `ctx` - `ctx`
@@ -62,6 +66,8 @@ The first parameter contains the following fields
A user selected **Register** on the overview page after external authentication. ZITADEL did not create the user yet. A user selected **Register** on the overview page after external authentication. ZITADEL did not create the user yet.
The trigger is represented by the following Ids in the API: `TRIGGER_TYPE_PRE_CREATION` or `2`.
### Parameters of Pre Creation ### Parameters of Pre Creation
- `ctx` - `ctx`
@@ -106,6 +112,8 @@ A user selected **Register** on the overview page after external authentication.
A user selected **Register** on the overview page after external authentication and ZITADEL successfully created the user. A user selected **Register** on the overview page after external authentication and ZITADEL successfully created the user.
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`

View File

@@ -2,12 +2,16 @@
title: Internal Authentication Flow title: Internal Authentication Flow
--- ---
The flow is represented by the following Ids in the API: `3`
## Post Authentication ## Post Authentication
A user has authenticated directly at ZITADEL. A user has authenticated directly at ZITADEL.
ZITADEL validated the users inputs for password, one-time password, security key or passwordless factor. ZITADEL validated the users inputs for password, one-time password, security key or passwordless factor.
Each validation step triggers the action. Each validation step triggers the action.
The trigger is represented by the following Ids in the API: `TRIGGER_TYPE_POST_AUTHENTICATION` or `1`.
### Parameters of Post Authentication Action ### Parameters of Post Authentication Action
- `ctx` - `ctx`
@@ -33,6 +37,8 @@ Each validation step triggers the action.
A user registers directly at ZITADEL. A user registers directly at ZITADEL.
ZITADEL did not create the user yet. ZITADEL did not create the user yet.
The trigger is represented by the following Ids in the API: `TRIGGER_TYPE_PRE_CREATION` or `2`.
### Parameters of Pre Creation ### Parameters of Pre Creation
- `ctx` - `ctx`
@@ -78,6 +84,8 @@ ZITADEL did not create the user yet.
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`.
### Parameters of Post Creation ### Parameters of Post Creation
- `ctx` - `ctx`

View File

@@ -13009,18 +13009,37 @@ message ClearFlowResponse {
} }
message SetTriggerActionsRequest { message SetTriggerActionsRequest {
// id of the flow type /* id of the flow type.
* Following flows are currently allowed:
* - External Authentication: FLOW_TYPE_EXTERNAL_AUTHENTICATION or 1
* - Internal Authentication: 3
* - Complement Token: 2
* - Complement SAML Response: 4
*/
string flow_type = 1 [ string flow_type = 1 [
(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = { (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
example: "\"1\""; example: "\"1\"";
description: "At the moment you have to send the ID of the Flow Type: ExternalAuthentication=1, CustomiseToken=2, InternalAuthentication=3, PreUserinfoCreation=3";
} }
]; ];
// id of the trigger type /* id of the trigger type.
* Following triggers are currently allowed:
* - External Authentication:
* - Post Authentication: TRIGGER_TYPE_POST_AUTHENTICATION or 1
* - Pre Creation: TRIGGER_TYPE_PRE_CREATION or 2
* - Post Creation: TRIGGER_TYPE_POST_CREATION or 3
* - Internal Authentication:
* - Post Authentication: TRIGGER_TYPE_POST_AUTHENTICATION or 1
* - Pre Creation: TRIGGER_TYPE_PRE_CREATION or 2
* - Post Creation: TRIGGER_TYPE_POST_CREATION or 3
* - Complement Token:
* - Pre Userinfo Creation: 4
* - Pre Access Token Creation: 5
* - Complement SAML Response:
* - Pre SAML Response Creation: 6
*/
string trigger_type = 2 [ string trigger_type = 2 [
(grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = { (grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field) = {
example: "\"1\""; example: "\"1\"";
description: "At the moment you have to send the ID of the Trigger Type: PostAuthentication=1, PreCreation=2, PostCreation=3, PreUserinfoCreation=4, PreAccessTokenCreation=5";
} }
]; ];
repeated string action_ids = 3; repeated string action_ids = 3;