import * as pulumi from "@pulumi/pulumi"; /** * With this resource, you can bind an action to a trigger. Once an action is created and deployed, it can be attached (i.e. bound) to a trigger so that it will be executed as part of a flow. * * Ordering of an action within a specific flow is not currently supported when using this resource; the action will get appended to the end of the flow. To precisely manage ordering, it is advised to either do so with the dashboard UI or with the `auth0TriggerBindings` resource. * * !> This resource appends an action to the trigger binding. In contrast, the `auth0.TriggerActions` resource manages all * the action bindings to a trigger. To avoid potential issues, it is recommended not to use this resource in conjunction * with the `auth0.TriggerAction` resource when binding actions to the same trigger. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as auth0 from "@pulumi/auth0"; * * const loginAlert = new auth0.Action("login_alert", { * name: "Alert after login", * code: `exports.onContinuePostLogin = async (event, api) => { * console.log(\\"foo\\"); * };\\" * `, * deploy: true, * supportedTriggers: { * id: "post-login", * version: "v3", * }, * }); * const postLoginAlertAction = new auth0.TriggerAction("post_login_alert_action", { * trigger: "post-login", * actionId: loginAlert.id, * }); * ``` * * ## Import * * This resource can be imported by specifying the * * trigger and action ID separated by "::" (note the double colon) * * :: * * Example: * * ```sh * $ pulumi import auth0:index/triggerAction:TriggerAction post_login_action "post-login::28b5c8fa-d371-5734-acf6-d0cf80ead918" * ``` */ export declare class TriggerAction extends pulumi.CustomResource { /** * Get an existing TriggerAction resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input, state?: TriggerActionState, opts?: pulumi.CustomResourceOptions): TriggerAction; /** * Returns true if the given object is an instance of TriggerAction. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is TriggerAction; /** * The ID of the action to bind to the trigger. */ readonly actionId: pulumi.Output; /** * The name for this action within the trigger. This can be useful for distinguishing between multiple instances of the same action bound to a trigger. Defaults to action name when not provided. */ readonly displayName: pulumi.Output; /** * The ID of the trigger to bind with. Available options: `post-login`, `credentials-exchange`, `pre-user-registration`, `post-user-registration`, `post-change-password`, `send-phone-message`, `password-reset-post-challenge`, `custom-email-provider`, `custom-phone-provider`. */ readonly trigger: pulumi.Output; /** * Create a TriggerAction resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: TriggerActionArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering TriggerAction resources. */ export interface TriggerActionState { /** * The ID of the action to bind to the trigger. */ actionId?: pulumi.Input; /** * The name for this action within the trigger. This can be useful for distinguishing between multiple instances of the same action bound to a trigger. Defaults to action name when not provided. */ displayName?: pulumi.Input; /** * The ID of the trigger to bind with. Available options: `post-login`, `credentials-exchange`, `pre-user-registration`, `post-user-registration`, `post-change-password`, `send-phone-message`, `password-reset-post-challenge`, `custom-email-provider`, `custom-phone-provider`. */ trigger?: pulumi.Input; } /** * The set of arguments for constructing a TriggerAction resource. */ export interface TriggerActionArgs { /** * The ID of the action to bind to the trigger. */ actionId: pulumi.Input; /** * The name for this action within the trigger. This can be useful for distinguishing between multiple instances of the same action bound to a trigger. Defaults to action name when not provided. */ displayName?: pulumi.Input; /** * The ID of the trigger to bind with. Available options: `post-login`, `credentials-exchange`, `pre-user-registration`, `post-user-registration`, `post-change-password`, `send-phone-message`, `password-reset-post-challenge`, `custom-email-provider`, `custom-phone-provider`. */ trigger: pulumi.Input; }