All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azurenative.appcomplianceautomation.Webhook Maven / Gradle / Ivy

There is a newer version: 2.78.0
Show newest version
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.azurenative.appcomplianceautomation;

import com.pulumi.azurenative.Utilities;
import com.pulumi.azurenative.appcomplianceautomation.WebhookArgs;
import com.pulumi.azurenative.appcomplianceautomation.outputs.SystemDataResponse;
import com.pulumi.core.Alias;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Export;
import com.pulumi.core.annotations.ResourceType;
import com.pulumi.core.internal.Codegen;
import java.lang.String;
import java.util.List;
import java.util.Optional;
import javax.annotation.Nullable;

/**
 * A class represent an AppComplianceAutomation webhook resource.
 * Azure REST API version: 2024-06-27.
 * 
 * ## Example Usage
 * ### Webhook_CreateOrUpdate
 * 
 * 
 * {@code
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azurenative.appcomplianceautomation.Webhook;
 * import com.pulumi.azurenative.appcomplianceautomation.WebhookArgs;
 * 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 webhook = new Webhook("webhook", WebhookArgs.builder()
 *             .contentType("application/json")
 *             .enableSslVerification("true")
 *             .events("generate_snapshot_failed")
 *             .payloadUrl("https://example.com")
 *             .reportName("testReportName")
 *             .sendAllEvents("false")
 *             .status("Enabled")
 *             .updateWebhookKey("true")
 *             .webhookKey("00000000-0000-0000-0000-000000000000")
 *             .webhookName("testWebhookName")
 *             .build());
 * 
 *     }
 * }
 * 
 * }
 * 
* * ## Import * * An existing resource can be imported using its type token, name, and identifier, e.g. * * ```sh * $ pulumi import azure-native:appcomplianceautomation:Webhook testWebhookName /providers/Microsoft.AppComplianceAutomation/reports/{reportName}/webhooks/{webhookName} * ``` * */ @ResourceType(type="azure-native:appcomplianceautomation:Webhook") public class Webhook extends com.pulumi.resources.CustomResource { /** * content type * */ @Export(name="contentType", refs={String.class}, tree="[0]") private Output contentType; /** * @return content type * */ public Output> contentType() { return Codegen.optional(this.contentType); } /** * webhook deliveryStatus * */ @Export(name="deliveryStatus", refs={String.class}, tree="[0]") private Output deliveryStatus; /** * @return webhook deliveryStatus * */ public Output deliveryStatus() { return this.deliveryStatus; } /** * whether to enable ssl verification * */ @Export(name="enableSslVerification", refs={String.class}, tree="[0]") private Output enableSslVerification; /** * @return whether to enable ssl verification * */ public Output> enableSslVerification() { return Codegen.optional(this.enableSslVerification); } /** * under which event notification should be sent. * */ @Export(name="events", refs={List.class,String.class}, tree="[0,1]") private Output> events; /** * @return under which event notification should be sent. * */ public Output>> events() { return Codegen.optional(this.events); } /** * The name of the resource * */ @Export(name="name", refs={String.class}, tree="[0]") private Output name; /** * @return The name of the resource * */ public Output name() { return this.name; } /** * webhook payload url * */ @Export(name="payloadUrl", refs={String.class}, tree="[0]") private Output payloadUrl; /** * @return webhook payload url * */ public Output> payloadUrl() { return Codegen.optional(this.payloadUrl); } /** * Azure Resource Provisioning State * */ @Export(name="provisioningState", refs={String.class}, tree="[0]") private Output provisioningState; /** * @return Azure Resource Provisioning State * */ public Output provisioningState() { return this.provisioningState; } /** * whether to send notification under any event. * */ @Export(name="sendAllEvents", refs={String.class}, tree="[0]") private Output sendAllEvents; /** * @return whether to send notification under any event. * */ public Output> sendAllEvents() { return Codegen.optional(this.sendAllEvents); } /** * Webhook status. * */ @Export(name="status", refs={String.class}, tree="[0]") private Output status; /** * @return Webhook status. * */ public Output> status() { return Codegen.optional(this.status); } /** * Azure Resource Manager metadata containing createdBy and modifiedBy information. * */ @Export(name="systemData", refs={SystemDataResponse.class}, tree="[0]") private Output systemData; /** * @return Azure Resource Manager metadata containing createdBy and modifiedBy information. * */ public Output systemData() { return this.systemData; } /** * Tenant id. * */ @Export(name="tenantId", refs={String.class}, tree="[0]") private Output tenantId; /** * @return Tenant id. * */ public Output tenantId() { return this.tenantId; } /** * The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" * */ @Export(name="type", refs={String.class}, tree="[0]") private Output type; /** * @return The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" * */ public Output type() { return this.type; } /** * whether to update webhookKey. * */ @Export(name="updateWebhookKey", refs={String.class}, tree="[0]") private Output updateWebhookKey; /** * @return whether to update webhookKey. * */ public Output> updateWebhookKey() { return Codegen.optional(this.updateWebhookKey); } /** * Webhook id in database. * */ @Export(name="webhookId", refs={String.class}, tree="[0]") private Output webhookId; /** * @return Webhook id in database. * */ public Output webhookId() { return this.webhookId; } /** * webhook secret token. If not set, this field value is null; otherwise, please set a string value. * */ @Export(name="webhookKey", refs={String.class}, tree="[0]") private Output webhookKey; /** * @return webhook secret token. If not set, this field value is null; otherwise, please set a string value. * */ public Output> webhookKey() { return Codegen.optional(this.webhookKey); } /** * whether webhookKey is enabled. * */ @Export(name="webhookKeyEnabled", refs={String.class}, tree="[0]") private Output webhookKeyEnabled; /** * @return whether webhookKey is enabled. * */ public Output webhookKeyEnabled() { return this.webhookKeyEnabled; } /** * * @param name The _unique_ name of the resulting resource. */ public Webhook(java.lang.String name) { this(name, WebhookArgs.Empty); } /** * * @param name The _unique_ name of the resulting resource. * @param args The arguments to use to populate this resource's properties. */ public Webhook(java.lang.String name, WebhookArgs args) { this(name, args, null); } /** * * @param name The _unique_ name of the resulting resource. * @param args The arguments to use to populate this resource's properties. * @param options A bag of options that control this resource's behavior. */ public Webhook(java.lang.String name, WebhookArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("azure-native:appcomplianceautomation:Webhook", name, makeArgs(args, options), makeResourceOptions(options, Codegen.empty()), false); } private Webhook(java.lang.String name, Output id, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("azure-native:appcomplianceautomation:Webhook", name, null, makeResourceOptions(options, id), false); } private static WebhookArgs makeArgs(WebhookArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { if (options != null && options.getUrn().isPresent()) { return null; } return args == null ? WebhookArgs.Empty : args; } private static com.pulumi.resources.CustomResourceOptions makeResourceOptions(@Nullable com.pulumi.resources.CustomResourceOptions options, @Nullable Output id) { var defaultOptions = com.pulumi.resources.CustomResourceOptions.builder() .version(Utilities.getVersion()) .aliases(List.of( Output.of(Alias.builder().type("azure-native:appcomplianceautomation/v20240627:Webhook").build()) )) .build(); return com.pulumi.resources.CustomResourceOptions.merge(defaultOptions, options, id); } /** * Get an existing Host 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 options Optional settings to control the behavior of the CustomResource. */ public static Webhook get(java.lang.String name, Output id, @Nullable com.pulumi.resources.CustomResourceOptions options) { return new Webhook(name, id, options); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy