com.pulumi.cloudflare.kotlin.ZeroTrustDexTestArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-cloudflare-kotlin Show documentation
Show all versions of pulumi-cloudflare-kotlin Show documentation
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.ZeroTrustDexTestArgs.builder
import com.pulumi.cloudflare.kotlin.inputs.ZeroTrustDexTestDataArgs
import com.pulumi.cloudflare.kotlin.inputs.ZeroTrustDexTestDataArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName
/**
* Provides a Cloudflare Device Dex Test resource. Device Dex Tests allow for building location-aware device settings policies.
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as cloudflare from "@pulumi/cloudflare";
* const example = new cloudflare.ZeroTrustDexTest("example", {
* accountId: "f037e56e89293a057740de681ac9abbe",
* name: "GET homepage",
* description: "Send a HTTP GET request to the home endpoint every half hour.",
* interval: "0h30m0s",
* enabled: true,
* data: {
* host: "https://example.com/home",
* kind: "http",
* method: "GET",
* },
* });
* ```
* ```python
* import pulumi
* import pulumi_cloudflare as cloudflare
* example = cloudflare.ZeroTrustDexTest("example",
* account_id="f037e56e89293a057740de681ac9abbe",
* name="GET homepage",
* description="Send a HTTP GET request to the home endpoint every half hour.",
* interval="0h30m0s",
* enabled=True,
* data={
* "host": "https://example.com/home",
* "kind": "http",
* "method": "GET",
* })
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using Cloudflare = Pulumi.Cloudflare;
* return await Deployment.RunAsync(() =>
* {
* var example = new Cloudflare.ZeroTrustDexTest("example", new()
* {
* AccountId = "f037e56e89293a057740de681ac9abbe",
* Name = "GET homepage",
* Description = "Send a HTTP GET request to the home endpoint every half hour.",
* Interval = "0h30m0s",
* Enabled = true,
* Data = new Cloudflare.Inputs.ZeroTrustDexTestDataArgs
* {
* Host = "https://example.com/home",
* Kind = "http",
* Method = "GET",
* },
* });
* });
* ```
* ```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.NewZeroTrustDexTest(ctx, "example", &cloudflare.ZeroTrustDexTestArgs{
* AccountId: pulumi.String("f037e56e89293a057740de681ac9abbe"),
* Name: pulumi.String("GET homepage"),
* Description: pulumi.String("Send a HTTP GET request to the home endpoint every half hour."),
* Interval: pulumi.String("0h30m0s"),
* Enabled: pulumi.Bool(true),
* Data: &cloudflare.ZeroTrustDexTestDataArgs{
* Host: pulumi.String("https://example.com/home"),
* Kind: pulumi.String("http"),
* Method: pulumi.String("GET"),
* },
* })
* 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.ZeroTrustDexTest;
* import com.pulumi.cloudflare.ZeroTrustDexTestArgs;
* import com.pulumi.cloudflare.inputs.ZeroTrustDexTestDataArgs;
* 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 ZeroTrustDexTest("example", ZeroTrustDexTestArgs.builder()
* .accountId("f037e56e89293a057740de681ac9abbe")
* .name("GET homepage")
* .description("Send a HTTP GET request to the home endpoint every half hour.")
* .interval("0h30m0s")
* .enabled(true)
* .data(ZeroTrustDexTestDataArgs.builder()
* .host("https://example.com/home")
* .kind("http")
* .method("GET")
* .build())
* .build());
* }
* }
* ```
* ```yaml
* resources:
* example:
* type: cloudflare:ZeroTrustDexTest
* properties:
* accountId: f037e56e89293a057740de681ac9abbe
* name: GET homepage
* description: Send a HTTP GET request to the home endpoint every half hour.
* interval: 0h30m0s
* enabled: true
* data:
* host: https://example.com/home
* kind: http
* method: GET
* ```
*
* ## Import
* ```sh
* $ pulumi import cloudflare:index/zeroTrustDexTest:ZeroTrustDexTest example /
* ```
* @property accountId The account identifier to target for the resource. **Modifying this attribute will force creation of a new resource.**
* @property data The configuration object which contains the details for the WARP client to conduct the test.
* @property description Additional details about the test.
* @property enabled Determines whether or not the test is active.
* @property interval How often the test will run.
* @property name The name of the Device Dex Test. Must be unique.
*/
public data class ZeroTrustDexTestArgs(
public val accountId: Output? = null,
public val `data`: Output? = null,
public val description: Output? = null,
public val enabled: Output? = null,
public val interval: Output? = null,
public val name: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.cloudflare.ZeroTrustDexTestArgs =
com.pulumi.cloudflare.ZeroTrustDexTestArgs.builder()
.accountId(accountId?.applyValue({ args0 -> args0 }))
.`data`(`data`?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.description(description?.applyValue({ args0 -> args0 }))
.enabled(enabled?.applyValue({ args0 -> args0 }))
.interval(interval?.applyValue({ args0 -> args0 }))
.name(name?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [ZeroTrustDexTestArgs].
*/
@PulumiTagMarker
public class ZeroTrustDexTestArgsBuilder internal constructor() {
private var accountId: Output? = null
private var `data`: Output? = null
private var description: Output? = null
private var enabled: Output? = null
private var interval: Output? = null
private var name: Output? = null
/**
* @param value The account identifier to target for the resource. **Modifying this attribute will force creation of a new resource.**
*/
@JvmName("mydcfqpwmtfaaowt")
public suspend fun accountId(`value`: Output) {
this.accountId = value
}
/**
* @param value The configuration object which contains the details for the WARP client to conduct the test.
*/
@JvmName("dqmoahbbvxmetnyv")
public suspend fun `data`(`value`: Output) {
this.`data` = value
}
/**
* @param value Additional details about the test.
*/
@JvmName("whtlgxqwvhyqofmy")
public suspend fun description(`value`: Output) {
this.description = value
}
/**
* @param value Determines whether or not the test is active.
*/
@JvmName("lmrphjhvbkeeeseh")
public suspend fun enabled(`value`: Output) {
this.enabled = value
}
/**
* @param value How often the test will run.
*/
@JvmName("ccxfoutlxoegrsca")
public suspend fun interval(`value`: Output) {
this.interval = value
}
/**
* @param value The name of the Device Dex Test. Must be unique.
*/
@JvmName("asfwjnxqupgwiyps")
public suspend fun name(`value`: Output) {
this.name = value
}
/**
* @param value The account identifier to target for the resource. **Modifying this attribute will force creation of a new resource.**
*/
@JvmName("lqwehpyywkaprtxw")
public suspend fun accountId(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.accountId = mapped
}
/**
* @param value The configuration object which contains the details for the WARP client to conduct the test.
*/
@JvmName("mqrcphrwqynimbaj")
public suspend fun `data`(`value`: ZeroTrustDexTestDataArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.`data` = mapped
}
/**
* @param argument The configuration object which contains the details for the WARP client to conduct the test.
*/
@JvmName("acbhamelftpbltno")
public suspend fun `data`(argument: suspend ZeroTrustDexTestDataArgsBuilder.() -> Unit) {
val toBeMapped = ZeroTrustDexTestDataArgsBuilder().applySuspend { argument() }.build()
val mapped = of(toBeMapped)
this.`data` = mapped
}
/**
* @param value Additional details about the test.
*/
@JvmName("mjpccrshvrpfvhib")
public suspend fun description(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.description = mapped
}
/**
* @param value Determines whether or not the test is active.
*/
@JvmName("ggmmsshvcgfufjdm")
public suspend fun enabled(`value`: Boolean?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.enabled = mapped
}
/**
* @param value How often the test will run.
*/
@JvmName("sdgmnmughqdcudye")
public suspend fun interval(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.interval = mapped
}
/**
* @param value The name of the Device Dex Test. Must be unique.
*/
@JvmName("yupfjecjrmfucnvg")
public suspend fun name(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.name = mapped
}
internal fun build(): ZeroTrustDexTestArgs = ZeroTrustDexTestArgs(
accountId = accountId,
`data` = `data`,
description = description,
enabled = enabled,
interval = interval,
name = name,
)
}