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

com.pulumi.cloudflare.kotlin.WebAnalyticsSiteArgs.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

The newest version!
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.cloudflare.kotlin

import com.pulumi.cloudflare.WebAnalyticsSiteArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.jvm.JvmName

/**
 * Provides a Cloudflare Web Analytics Site resource.
 * ## Example Usage
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as cloudflare from "@pulumi/cloudflare";
 * const example = new cloudflare.WebAnalyticsSite("example", {
 *     accountId: "f037e56e89293a057740de681ac9abbe",
 *     zoneTag: "0da42c8d2132a9ddaf714f9e7c920711",
 *     autoInstall: true,
 * });
 * ```
 * ```python
 * import pulumi
 * import pulumi_cloudflare as cloudflare
 * example = cloudflare.WebAnalyticsSite("example",
 *     account_id="f037e56e89293a057740de681ac9abbe",
 *     zone_tag="0da42c8d2132a9ddaf714f9e7c920711",
 *     auto_install=True)
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using Cloudflare = Pulumi.Cloudflare;
 * return await Deployment.RunAsync(() =>
 * {
 *     var example = new Cloudflare.WebAnalyticsSite("example", new()
 *     {
 *         AccountId = "f037e56e89293a057740de681ac9abbe",
 *         ZoneTag = "0da42c8d2132a9ddaf714f9e7c920711",
 *         AutoInstall = true,
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	"github.com/pulumi/pulumi-cloudflare/sdk/v5/go/cloudflare"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		_, err := cloudflare.NewWebAnalyticsSite(ctx, "example", &cloudflare.WebAnalyticsSiteArgs{
 * 			AccountId:   pulumi.String("f037e56e89293a057740de681ac9abbe"),
 * 			ZoneTag:     pulumi.String("0da42c8d2132a9ddaf714f9e7c920711"),
 * 			AutoInstall: pulumi.Bool(true),
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		return nil
 * 	})
 * }
 * ```
 * ```java
 * package generated_program;
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.cloudflare.WebAnalyticsSite;
 * import com.pulumi.cloudflare.WebAnalyticsSiteArgs;
 * 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 WebAnalyticsSite("example", WebAnalyticsSiteArgs.builder()
 *             .accountId("f037e56e89293a057740de681ac9abbe")
 *             .zoneTag("0da42c8d2132a9ddaf714f9e7c920711")
 *             .autoInstall(true)
 *             .build());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   example:
 *     type: cloudflare:WebAnalyticsSite
 *     properties:
 *       accountId: f037e56e89293a057740de681ac9abbe
 *       zoneTag: 0da42c8d2132a9ddaf714f9e7c920711
 *       autoInstall: true
 * ```
 * 
 * ## Import
 * ```sh
 * $ pulumi import cloudflare:index/webAnalyticsSite:WebAnalyticsSite example /
 * ```
 * @property accountId The account identifier to target for the resource. **Modifying this attribute will force creation of a new resource.**
 * @property autoInstall Whether Cloudflare will automatically inject the JavaScript snippet for orange-clouded sites. **Modifying this attribute will force creation of a new resource.**
 * @property host The hostname to use for gray-clouded sites. Must provide only one of `zone_tag`. **Modifying this attribute will force creation of a new resource.**
 * @property zoneTag The zone identifier for orange-clouded sites. Must provide only one of `host`. **Modifying this attribute will force creation of a new resource.**
 */
public data class WebAnalyticsSiteArgs(
    public val accountId: Output? = null,
    public val autoInstall: Output? = null,
    public val host: Output? = null,
    public val zoneTag: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.cloudflare.WebAnalyticsSiteArgs =
        com.pulumi.cloudflare.WebAnalyticsSiteArgs.builder()
            .accountId(accountId?.applyValue({ args0 -> args0 }))
            .autoInstall(autoInstall?.applyValue({ args0 -> args0 }))
            .host(host?.applyValue({ args0 -> args0 }))
            .zoneTag(zoneTag?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [WebAnalyticsSiteArgs].
 */
@PulumiTagMarker
public class WebAnalyticsSiteArgsBuilder internal constructor() {
    private var accountId: Output? = null

    private var autoInstall: Output? = null

    private var host: Output? = null

    private var zoneTag: Output? = null

    /**
     * @param value The account identifier to target for the resource. **Modifying this attribute will force creation of a new resource.**
     */
    @JvmName("dqccuorsmautfwvs")
    public suspend fun accountId(`value`: Output) {
        this.accountId = value
    }

    /**
     * @param value Whether Cloudflare will automatically inject the JavaScript snippet for orange-clouded sites. **Modifying this attribute will force creation of a new resource.**
     */
    @JvmName("awlbbqdyflfgcigi")
    public suspend fun autoInstall(`value`: Output) {
        this.autoInstall = value
    }

    /**
     * @param value The hostname to use for gray-clouded sites. Must provide only one of `zone_tag`. **Modifying this attribute will force creation of a new resource.**
     */
    @JvmName("nsfroqpmaemvkdfo")
    public suspend fun host(`value`: Output) {
        this.host = value
    }

    /**
     * @param value The zone identifier for orange-clouded sites. Must provide only one of `host`. **Modifying this attribute will force creation of a new resource.**
     */
    @JvmName("tcqayfxlmlamptps")
    public suspend fun zoneTag(`value`: Output) {
        this.zoneTag = value
    }

    /**
     * @param value The account identifier to target for the resource. **Modifying this attribute will force creation of a new resource.**
     */
    @JvmName("aybcpritkhpqfjyp")
    public suspend fun accountId(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.accountId = mapped
    }

    /**
     * @param value Whether Cloudflare will automatically inject the JavaScript snippet for orange-clouded sites. **Modifying this attribute will force creation of a new resource.**
     */
    @JvmName("bxvjbfvmcgysacew")
    public suspend fun autoInstall(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.autoInstall = mapped
    }

    /**
     * @param value The hostname to use for gray-clouded sites. Must provide only one of `zone_tag`. **Modifying this attribute will force creation of a new resource.**
     */
    @JvmName("lfmsdahsrehxojpx")
    public suspend fun host(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.host = mapped
    }

    /**
     * @param value The zone identifier for orange-clouded sites. Must provide only one of `host`. **Modifying this attribute will force creation of a new resource.**
     */
    @JvmName("wfryguvponbpscdg")
    public suspend fun zoneTag(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.zoneTag = mapped
    }

    internal fun build(): WebAnalyticsSiteArgs = WebAnalyticsSiteArgs(
        accountId = accountId,
        autoInstall = autoInstall,
        host = host,
        zoneTag = zoneTag,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy