UNPKG

@pulumi/pulumiservice

Version:

[![Slack](http://www.pulumi.com/images/docs/badges/slack.svg)](https://slack.pulumi.com) [![NPM version](https://badge.fury.io/js/%40pulumi%2Fpulumiservice.svg)](https://www.npmjs.com/package/@pulumi/pulumiservice) [![Python version](https://badge.fury.io

135 lines 5.78 kB
import * as pulumi from "@pulumi/pulumi"; import * as enums from "./types/enums"; /** * Pulumi Webhooks allow you to notify external services of events happening within your Pulumi organization or stack. For example, you can trigger a notification whenever a stack is updated. Whenever an event occurs, Pulumi will send an HTTP POST request to all registered webhooks. The webhook can then be used to emit some notification, start running integration tests, or even update additional stacks. * * ### Import * * Pulumi webhooks can be imported using the `id`, which for webhooks is `{org}/{project}/{stack}/{webhook-name}` e.g., * * ```sh * $ pulumi import pulumiservice:index:Webhook my_webhook my-org/my-project/my-stack/4b0d0671 * ``` */ export declare class Webhook extends pulumi.CustomResource { /** * Get an existing Webhook 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 opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input<pulumi.ID>, opts?: pulumi.CustomResourceOptions): Webhook; /** * Returns true if the given object is an instance of Webhook. 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 Webhook; /** * Indicates whether this webhook is enabled or not. */ readonly active: pulumi.Output<boolean>; /** * The friendly name displayed in the Pulumi Cloud. */ readonly displayName: pulumi.Output<string>; /** * Name of the environment. Only specified if this is an environment webhook. */ readonly environmentName: pulumi.Output<string | undefined>; /** * Optional set of filters to apply to the webhook. See [webhook docs](https://www.pulumi.com/docs/intro/pulumi-service/webhooks/#filters) for more information. */ readonly filters: pulumi.Output<enums.WebhookFilters[] | undefined>; /** * Format of the webhook payload. Can be either `raw`, `slack`, `ms_teams` or `pulumi_deployments`. Defaults to `raw`. */ readonly format: pulumi.Output<enums.WebhookFormat>; /** * Optional set of filter groups to apply to the webhook. See [webhook docs](https://www.pulumi.com/docs/intro/pulumi-service/webhooks/#groups) for more information. */ readonly groups: pulumi.Output<enums.WebhookGroup[] | undefined>; /** * Webhook identifier generated by Pulumi Cloud. */ readonly name: pulumi.Output<string>; /** * Name of the organization. */ readonly organizationName: pulumi.Output<string>; /** * URL to send request to. */ readonly payloadUrl: pulumi.Output<string>; /** * Name of the project. Only specified if this is a stack or environment webhook. */ readonly projectName: pulumi.Output<string | undefined>; /** * Optional. secret used as the HMAC key. See [webhook docs](https://www.pulumi.com/docs/intro/pulumi-service/webhooks/#headers) for more information. */ readonly secret: pulumi.Output<string | undefined>; /** * Name of the stack. Only specified if this is a stack webhook. */ readonly stackName: pulumi.Output<string | undefined>; /** * Create a Webhook 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: WebhookArgs, opts?: pulumi.CustomResourceOptions); } /** * The set of arguments for constructing a Webhook resource. */ export interface WebhookArgs { /** * Indicates whether this webhook is enabled or not. */ active: pulumi.Input<boolean>; /** * The friendly name displayed in the Pulumi Cloud. */ displayName: pulumi.Input<string>; /** * Name of the environment. Only specified if this is an environment webhook. */ environmentName?: pulumi.Input<string | undefined>; /** * Optional set of filters to apply to the webhook. See [webhook docs](https://www.pulumi.com/docs/intro/pulumi-service/webhooks/#filters) for more information. */ filters?: pulumi.Input<pulumi.Input<enums.WebhookFilters>[] | undefined>; /** * Format of the webhook payload. Can be either `raw` or `slack`. Defaults to `raw`. */ format?: pulumi.Input<enums.WebhookFormat | undefined>; /** * Optional set of filter groups to apply to the webhook. See [webhook docs](https://www.pulumi.com/docs/intro/pulumi-service/webhooks/#groups) for more information. */ groups?: pulumi.Input<pulumi.Input<enums.WebhookGroup>[] | undefined>; /** * Name of the organization. */ organizationName: pulumi.Input<string>; /** * URL to send request to. */ payloadUrl: pulumi.Input<string>; /** * Name of the project. Only specified if this is a stack or environment webhook. */ projectName?: pulumi.Input<string | undefined>; /** * Optional. secret used as the HMAC key. See [webhook docs](https://www.pulumi.com/docs/intro/pulumi-service/webhooks/#headers) for more information. */ secret?: pulumi.Input<string | undefined>; /** * Name of the stack. Only needed if this is a stack webhook. */ stackName?: pulumi.Input<string | undefined>; } //# sourceMappingURL=webhook.d.ts.map