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

com.pulumi.meraki.networks.WebhooksPayloadTemplates Maven / Gradle / Ivy

There is a newer version: 0.4.0-alpha.1731736975
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.meraki.networks;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Export;
import com.pulumi.core.annotations.ResourceType;
import com.pulumi.core.internal.Codegen;
import com.pulumi.meraki.Utilities;
import com.pulumi.meraki.networks.WebhooksPayloadTemplatesArgs;
import com.pulumi.meraki.networks.inputs.WebhooksPayloadTemplatesState;
import com.pulumi.meraki.networks.outputs.WebhooksPayloadTemplatesHeader;
import com.pulumi.meraki.networks.outputs.WebhooksPayloadTemplatesSharing;
import java.lang.String;
import java.util.List;
import javax.annotation.Nullable;

/**
 * ## Example Usage
 * 
 * <!--Start PulumiCodeChooser -->
 * 
 * {@code
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.meraki.networks.WebhooksPayloadTemplates;
 * import com.pulumi.meraki.networks.WebhooksPayloadTemplatesArgs;
 * import com.pulumi.meraki.networks.inputs.WebhooksPayloadTemplatesHeaderArgs;
 * 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 example = new WebhooksPayloadTemplates("example", WebhooksPayloadTemplatesArgs.builder()
 *             .body("{'event_type':'{{alertTypeId}}','client_payload':{'text':'{{alertData}}'}}")
 *             .bodyFile("Qm9keSBGaWxl")
 *             .headers(WebhooksPayloadTemplatesHeaderArgs.builder()
 *                 .name("Authorization")
 *                 .template("Bearer {{sharedSecret}}")
 *                 .build())
 *             .headersFile("SGVhZGVycyBGaWxl")
 *             .name("Custom Template")
 *             .networkId("string")
 *             .build());
 * 
 *         ctx.export("merakiNetworksWebhooksPayloadTemplatesExample", example);
 *     }
 * }
 * }
 * 
* <!--End PulumiCodeChooser --> * * ## Import * * ```sh * $ pulumi import meraki:networks/webhooksPayloadTemplates:WebhooksPayloadTemplates example "network_id,payload_template_id" * ``` * */ @ResourceType(type="meraki:networks/webhooksPayloadTemplates:WebhooksPayloadTemplates") public class WebhooksPayloadTemplates extends com.pulumi.resources.CustomResource { /** * The body of the payload template, in liquid template * */ @Export(name="body", refs={String.class}, tree="[0]") private Output body; /** * @return The body of the payload template, in liquid template * */ public Output body() { return this.body; } /** * A file containing liquid template used for the body of the webhook message. Either *body* or *bodyFile* must be specified. * */ @Export(name="bodyFile", refs={String.class}, tree="[0]") private Output bodyFile; /** * @return A file containing liquid template used for the body of the webhook message. Either *body* or *bodyFile* must be specified. * */ public Output bodyFile() { return this.bodyFile; } /** * The payload template headers, will be rendered as a key-value pair in the webhook. * */ @Export(name="headers", refs={List.class,WebhooksPayloadTemplatesHeader.class}, tree="[0,1]") private Output> headers; /** * @return The payload template headers, will be rendered as a key-value pair in the webhook. * */ public Output> headers() { return this.headers; } /** * A file containing the liquid template used with the webhook headers. * */ @Export(name="headersFile", refs={String.class}, tree="[0]") private Output headersFile; /** * @return A file containing the liquid template used with the webhook headers. * */ public Output headersFile() { return this.headersFile; } /** * The name of the payload template * */ @Export(name="name", refs={String.class}, tree="[0]") private Output name; /** * @return The name of the payload template * */ public Output name() { return this.name; } /** * networkId path parameter. Network ID * */ @Export(name="networkId", refs={String.class}, tree="[0]") private Output networkId; /** * @return networkId path parameter. Network ID * */ public Output networkId() { return this.networkId; } /** * Webhook payload template Id * */ @Export(name="payloadTemplateId", refs={String.class}, tree="[0]") private Output payloadTemplateId; /** * @return Webhook payload template Id * */ public Output payloadTemplateId() { return this.payloadTemplateId; } /** * Information on which entities have access to the template * */ @Export(name="sharing", refs={WebhooksPayloadTemplatesSharing.class}, tree="[0]") private Output sharing; /** * @return Information on which entities have access to the template * */ public Output sharing() { return this.sharing; } /** * The type of the payload template * */ @Export(name="type", refs={String.class}, tree="[0]") private Output type; /** * @return The type of the payload template * */ public Output type() { return this.type; } /** * * @param name The _unique_ name of the resulting resource. */ public WebhooksPayloadTemplates(java.lang.String name) { this(name, WebhooksPayloadTemplatesArgs.Empty); } /** * * @param name The _unique_ name of the resulting resource. * @param args The arguments to use to populate this resource's properties. */ public WebhooksPayloadTemplates(java.lang.String name, WebhooksPayloadTemplatesArgs 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 WebhooksPayloadTemplates(java.lang.String name, WebhooksPayloadTemplatesArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("meraki:networks/webhooksPayloadTemplates:WebhooksPayloadTemplates", name, makeArgs(args, options), makeResourceOptions(options, Codegen.empty()), false); } private WebhooksPayloadTemplates(java.lang.String name, Output id, @Nullable WebhooksPayloadTemplatesState state, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("meraki:networks/webhooksPayloadTemplates:WebhooksPayloadTemplates", name, state, makeResourceOptions(options, id), false); } private static WebhooksPayloadTemplatesArgs makeArgs(WebhooksPayloadTemplatesArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { if (options != null && options.getUrn().isPresent()) { return null; } return args == null ? WebhooksPayloadTemplatesArgs.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()) .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 state * @param options Optional settings to control the behavior of the CustomResource. */ public static WebhooksPayloadTemplates get(java.lang.String name, Output id, @Nullable WebhooksPayloadTemplatesState state, @Nullable com.pulumi.resources.CustomResourceOptions options) { return new WebhooksPayloadTemplates(name, id, state, options); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy