Welcome to Pulumi Registry, your window into the cloud. Read the announcement.

Keycloak

v4.7.0 published on Thursday, Nov 18, 2021 by Pulumi

getAuthenticationFlow

This data source can be used to fetch the ID of an authentication flow within Keycloak.

Example Usage

using Pulumi;
using Keycloak = Pulumi.Keycloak;

class MyStack : Stack
{
    public MyStack()
    {
        var realm = new Keycloak.Realm("realm", new Keycloak.RealmArgs
        {
            Realm = "my-realm",
            Enabled = true,
        });
        var browserAuthCookie = realm.Id.Apply(id => Keycloak.GetAuthenticationFlow.InvokeAsync(new Keycloak.GetAuthenticationFlowArgs
        {
            RealmId = id,
            Alias = "browser",
        }));
    }

}
package main

import (
	"github.com/pulumi/pulumi-keycloak/sdk/v4/go/keycloak"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		realm, err := keycloak.NewRealm(ctx, "realm", &keycloak.RealmArgs{
			Realm:   pulumi.String("my-realm"),
			Enabled: pulumi.Bool(true),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
import pulumi
import pulumi_keycloak as keycloak

realm = keycloak.Realm("realm",
    realm="my-realm",
    enabled=True)
browser_auth_cookie = realm.id.apply(lambda id: keycloak.get_authentication_flow(realm_id=id,
    alias="browser"))
import * as pulumi from "@pulumi/pulumi";
import * as keycloak from "@pulumi/keycloak";

const realm = new keycloak.Realm("realm", {
    realm: "my-realm",
    enabled: true,
});
const browserAuthCookie = realm.id.apply(id => keycloak.getAuthenticationFlow({
    realmId: id,
    alias: "browser",
}));

Using getAuthenticationFlow

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getAuthenticationFlow(args: GetAuthenticationFlowArgs, opts?: InvokeOptions): Promise<GetAuthenticationFlowResult>
function getAuthenticationFlowOutput(args: GetAuthenticationFlowOutputArgs, opts?: InvokeOptions): Output<GetAuthenticationFlowResult>
def get_authentication_flow(alias: Optional[str] = None,
                            realm_id: Optional[str] = None,
                            opts: Optional[InvokeOptions] = None) -> GetAuthenticationFlowResult
def get_authentication_flow_output(alias: Optional[pulumi.Input[str]] = None,
                            realm_id: Optional[pulumi.Input[str]] = None,
                            opts: Optional[InvokeOptions] = None) -> Output[GetAuthenticationFlowResult]
func GetAuthenticationFlow(ctx *Context, args *GetAuthenticationFlowArgs, opts ...InvokeOption) (*GetAuthenticationFlowResult, error)
func GetAuthenticationFlowOutput(ctx *Context, args *GetAuthenticationFlowOutputArgs, opts ...InvokeOption) GetAuthenticationFlowResultOutput

> Note: This function is named GetAuthenticationFlow in the Go SDK.

public static class GetAuthenticationFlow 
{
    public static Task<GetAuthenticationFlowResult> InvokeAsync(GetAuthenticationFlowArgs args, InvokeOptions? opts = null)
    public static Output<GetAuthenticationFlowResult> Invoke(GetAuthenticationFlowInvokeArgs args, InvokeOptions? opts = null)
}

The following arguments are supported:

Alias string
The alias of the flow.
RealmId string
The realm the authentication flow exists in.
Alias string
The alias of the flow.
RealmId string
The realm the authentication flow exists in.
alias string
The alias of the flow.
realmId string
The realm the authentication flow exists in.
alias str
The alias of the flow.
realm_id str
The realm the authentication flow exists in.

getAuthenticationFlow Result

The following output properties are available:

Alias string
Id string
The provider-assigned unique ID for this managed resource.
RealmId string
Alias string
Id string
The provider-assigned unique ID for this managed resource.
RealmId string
alias string
id string
The provider-assigned unique ID for this managed resource.
realmId string
alias str
id str
The provider-assigned unique ID for this managed resource.
realm_id str

Package Details

Repository
https://github.com/pulumi/pulumi-keycloak
License
Apache-2.0
Notes
This Pulumi package is based on the keycloak Terraform Provider.