Okta

Pulumi Official
Package maintained by Pulumi
v3.14.0 published on Thursday, Aug 4, 2022 by Pulumi

EventHookVerification

Verifies the Event Hook. The resource won’t be created unless the URI provided in the event hook returns a valid JSON object with verification. See Event Hooks documentation for details.

Example Usage

using Pulumi;
using Okta = Pulumi.Okta;

class MyStack : Stack
{
    public MyStack()
    {
        var exampleEventHook = new Okta.EventHook("exampleEventHook", new Okta.EventHookArgs
        {
            Events = 
            {
                "user.lifecycle.create",
                "user.lifecycle.delete.initiated",
            },
            Channel = 
            {
                { "type", "HTTP" },
                { "version", "1.0.0" },
                { "uri", "https://example.com/test" },
            },
            Auth = 
            {
                { "type", "HEADER" },
                { "key", "Authorization" },
                { "value", "123" },
            },
        });
        var exampleEventHookVerification = new Okta.EventHookVerification("exampleEventHookVerification", new Okta.EventHookVerificationArgs
        {
            EventHookId = exampleEventHook.Id,
        });
    }

}
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		exampleEventHook, err := okta.NewEventHook(ctx, "exampleEventHook", &okta.EventHookArgs{
			Events: pulumi.StringArray{
				pulumi.String("user.lifecycle.create"),
				pulumi.String("user.lifecycle.delete.initiated"),
			},
			Channel: pulumi.StringMap{
				"type":    pulumi.String("HTTP"),
				"version": pulumi.String("1.0.0"),
				"uri":     pulumi.String("https://example.com/test"),
			},
			Auth: pulumi.StringMap{
				"type":  pulumi.String("HEADER"),
				"key":   pulumi.String("Authorization"),
				"value": pulumi.String("123"),
			},
		})
		if err != nil {
			return err
		}
		_, err = okta.NewEventHookVerification(ctx, "exampleEventHookVerification", &okta.EventHookVerificationArgs{
			EventHookId: exampleEventHook.ID(),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.okta.EventHook;
import com.pulumi.okta.EventHookArgs;
import com.pulumi.okta.EventHookVerification;
import com.pulumi.okta.EventHookVerificationArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var exampleEventHook = new EventHook("exampleEventHook", EventHookArgs.builder()        
            .events(            
                "user.lifecycle.create",
                "user.lifecycle.delete.initiated")
            .channel(Map.ofEntries(
                Map.entry("type", "HTTP"),
                Map.entry("version", "1.0.0"),
                Map.entry("uri", "https://example.com/test")
            ))
            .auth(Map.ofEntries(
                Map.entry("type", "HEADER"),
                Map.entry("key", "Authorization"),
                Map.entry("value", "123")
            ))
            .build());

        var exampleEventHookVerification = new EventHookVerification("exampleEventHookVerification", EventHookVerificationArgs.builder()        
            .eventHookId(exampleEventHook.id())
            .build());

    }
}
import pulumi
import pulumi_okta as okta

example_event_hook = okta.EventHook("exampleEventHook",
    events=[
        "user.lifecycle.create",
        "user.lifecycle.delete.initiated",
    ],
    channel={
        "type": "HTTP",
        "version": "1.0.0",
        "uri": "https://example.com/test",
    },
    auth={
        "type": "HEADER",
        "key": "Authorization",
        "value": "123",
    })
example_event_hook_verification = okta.EventHookVerification("exampleEventHookVerification", event_hook_id=example_event_hook.id)
import * as pulumi from "@pulumi/pulumi";
import * as okta from "@pulumi/okta";

const exampleEventHook = new okta.EventHook("exampleEventHook", {
    events: [
        "user.lifecycle.create",
        "user.lifecycle.delete.initiated",
    ],
    channel: {
        type: "HTTP",
        version: "1.0.0",
        uri: "https://example.com/test",
    },
    auth: {
        type: "HEADER",
        key: "Authorization",
        value: "123",
    },
});
const exampleEventHookVerification = new okta.EventHookVerification("exampleEventHookVerification", {eventHookId: exampleEventHook.id});
resources:
  exampleEventHook:
    type: okta:EventHook
    properties:
      events:
        - user.lifecycle.create
        - user.lifecycle.delete.initiated
      channel:
        type: HTTP
        version: 1.0.0
        uri: https://example.com/test
      auth:
        type: HEADER
        key: Authorization
        value: 123
  exampleEventHookVerification:
    type: okta:EventHookVerification
    properties:
      eventHookId: ${exampleEventHook.id}

Create a EventHookVerification Resource

new EventHookVerification(name: string, args: EventHookVerificationArgs, opts?: CustomResourceOptions);
@overload
def EventHookVerification(resource_name: str,
                          opts: Optional[ResourceOptions] = None,
                          event_hook_id: Optional[str] = None)
@overload
def EventHookVerification(resource_name: str,
                          args: EventHookVerificationArgs,
                          opts: Optional[ResourceOptions] = None)
func NewEventHookVerification(ctx *Context, name string, args EventHookVerificationArgs, opts ...ResourceOption) (*EventHookVerification, error)
public EventHookVerification(string name, EventHookVerificationArgs args, CustomResourceOptions? opts = null)
public EventHookVerification(String name, EventHookVerificationArgs args)
public EventHookVerification(String name, EventHookVerificationArgs args, CustomResourceOptions options)
type: okta:EventHookVerification
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args EventHookVerificationArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
args EventHookVerificationArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args EventHookVerificationArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args EventHookVerificationArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args EventHookVerificationArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

EventHookVerification Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

The EventHookVerification resource accepts the following input properties:

EventHookId string

Event Hook ID.

EventHookId string

Event Hook ID.

eventHookId String

Event Hook ID.

eventHookId string

Event Hook ID.

event_hook_id str

Event Hook ID.

eventHookId String

Event Hook ID.

Outputs

All input properties are implicitly available as output properties. Additionally, the EventHookVerification resource produces the following output properties:

Id string

The provider-assigned unique ID for this managed resource.

Id string

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

id string

The provider-assigned unique ID for this managed resource.

id str

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

Look up an Existing EventHookVerification Resource

Get an existing EventHookVerification resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: EventHookVerificationState, opts?: CustomResourceOptions): EventHookVerification
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        event_hook_id: Optional[str] = None) -> EventHookVerification
func GetEventHookVerification(ctx *Context, name string, id IDInput, state *EventHookVerificationState, opts ...ResourceOption) (*EventHookVerification, error)
public static EventHookVerification Get(string name, Input<string> id, EventHookVerificationState? state, CustomResourceOptions? opts = null)
public static EventHookVerification get(String name, Output<String> id, EventHookVerificationState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
EventHookId string

Event Hook ID.

EventHookId string

Event Hook ID.

eventHookId String

Event Hook ID.

eventHookId string

Event Hook ID.

event_hook_id str

Event Hook ID.

eventHookId String

Event Hook ID.

Import

This resource does not support importing.

Package Details

Repository
https://github.com/pulumi/pulumi-okta
License
Apache-2.0
Notes

This Pulumi package is based on the okta Terraform Provider.