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

com.pulumi.gcp.clouddomains.kotlin.Registration.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.

There is a newer version: 8.10.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.gcp.clouddomains.kotlin

import com.pulumi.core.Output
import com.pulumi.gcp.clouddomains.kotlin.outputs.RegistrationContactSettings
import com.pulumi.gcp.clouddomains.kotlin.outputs.RegistrationDnsSettings
import com.pulumi.gcp.clouddomains.kotlin.outputs.RegistrationManagementSettings
import com.pulumi.gcp.clouddomains.kotlin.outputs.RegistrationYearlyPrice
import com.pulumi.kotlin.KotlinCustomResource
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.ResourceMapper
import com.pulumi.kotlin.options.CustomResourceOptions
import com.pulumi.kotlin.options.CustomResourceOptionsBuilder
import com.pulumi.resources.Resource
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import com.pulumi.gcp.clouddomains.kotlin.outputs.RegistrationContactSettings.Companion.toKotlin as registrationContactSettingsToKotlin
import com.pulumi.gcp.clouddomains.kotlin.outputs.RegistrationDnsSettings.Companion.toKotlin as registrationDnsSettingsToKotlin
import com.pulumi.gcp.clouddomains.kotlin.outputs.RegistrationManagementSettings.Companion.toKotlin as registrationManagementSettingsToKotlin
import com.pulumi.gcp.clouddomains.kotlin.outputs.RegistrationYearlyPrice.Companion.toKotlin as registrationYearlyPriceToKotlin

/**
 * Builder for [Registration].
 */
@PulumiTagMarker
public class RegistrationResourceBuilder internal constructor() {
    public var name: String? = null

    public var args: RegistrationArgs = RegistrationArgs()

    public var opts: CustomResourceOptions = CustomResourceOptions()

    /**
     * @param name The _unique_ name of the resulting resource.
     */
    public fun name(`value`: String) {
        this.name = value
    }

    /**
     * @param block The arguments to use to populate this resource's properties.
     */
    public suspend fun args(block: suspend RegistrationArgsBuilder.() -> Unit) {
        val builder = RegistrationArgsBuilder()
        block(builder)
        this.args = builder.build()
    }

    /**
     * @param block A bag of options that control this resource's behavior.
     */
    public suspend fun opts(block: suspend CustomResourceOptionsBuilder.() -> Unit) {
        this.opts = com.pulumi.kotlin.options.CustomResourceOptions.opts(block)
    }

    internal fun build(): Registration {
        val builtJavaResource = com.pulumi.gcp.clouddomains.Registration(
            this.name,
            this.args.toJava(),
            this.opts.toJava(),
        )
        return Registration(builtJavaResource)
    }
}

/**
 * ## Example Usage
 * ### Clouddomains Registration Full
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 * const myRegistration = new gcp.clouddomains.Registration("my_registration", {
 *     domainName: "example-domain.com",
 *     location: "global",
 *     labels: {
 *         labelkey: "labelvalue",
 *     },
 *     yearlyPrice: {
 *         currencyCode: "USD",
 *         units: "12",
 *     },
 *     dnsSettings: {
 *         customDns: {
 *             nameServers: [
 *                 "ns-cloud-a1.googledomains.com.",
 *                 "ns-cloud-a2.googledomains.com.",
 *                 "ns-cloud-a3.googledomains.com.",
 *                 "ns-cloud-a4.googledomains.com.",
 *             ],
 *         },
 *     },
 *     contactSettings: {
 *         privacy: "REDACTED_CONTACT_DATA",
 *         registrantContact: {
 *             phoneNumber: "+12345000000",
 *             email: "[email protected]",
 *             postalAddress: {
 *                 regionCode: "US",
 *                 postalCode: "95050",
 *                 administrativeArea: "CA",
 *                 locality: "Example City",
 *                 addressLines: ["1234 Example street"],
 *                 recipients: ["example recipient"],
 *             },
 *         },
 *         adminContact: {
 *             phoneNumber: "+12345000000",
 *             email: "[email protected]",
 *             postalAddress: {
 *                 regionCode: "US",
 *                 postalCode: "95050",
 *                 administrativeArea: "CA",
 *                 locality: "Example City",
 *                 addressLines: ["1234 Example street"],
 *                 recipients: ["example recipient"],
 *             },
 *         },
 *         technicalContact: {
 *             phoneNumber: "+12345000000",
 *             email: "[email protected]",
 *             postalAddress: {
 *                 regionCode: "US",
 *                 postalCode: "95050",
 *                 administrativeArea: "CA",
 *                 locality: "Example City",
 *                 addressLines: ["1234 Example street"],
 *                 recipients: ["example recipient"],
 *             },
 *         },
 *     },
 * });
 * ```
 * ```python
 * import pulumi
 * import pulumi_gcp as gcp
 * my_registration = gcp.clouddomains.Registration("my_registration",
 *     domain_name="example-domain.com",
 *     location="global",
 *     labels={
 *         "labelkey": "labelvalue",
 *     },
 *     yearly_price=gcp.clouddomains.RegistrationYearlyPriceArgs(
 *         currency_code="USD",
 *         units="12",
 *     ),
 *     dns_settings=gcp.clouddomains.RegistrationDnsSettingsArgs(
 *         custom_dns=gcp.clouddomains.RegistrationDnsSettingsCustomDnsArgs(
 *             name_servers=[
 *                 "ns-cloud-a1.googledomains.com.",
 *                 "ns-cloud-a2.googledomains.com.",
 *                 "ns-cloud-a3.googledomains.com.",
 *                 "ns-cloud-a4.googledomains.com.",
 *             ],
 *         ),
 *     ),
 *     contact_settings=gcp.clouddomains.RegistrationContactSettingsArgs(
 *         privacy="REDACTED_CONTACT_DATA",
 *         registrant_contact=gcp.clouddomains.RegistrationContactSettingsRegistrantContactArgs(
 *             phone_number="+12345000000",
 *             email="[email protected]",
 *             postal_address=gcp.clouddomains.RegistrationContactSettingsRegistrantContactPostalAddressArgs(
 *                 region_code="US",
 *                 postal_code="95050",
 *                 administrative_area="CA",
 *                 locality="Example City",
 *                 address_lines=["1234 Example street"],
 *                 recipients=["example recipient"],
 *             ),
 *         ),
 *         admin_contact=gcp.clouddomains.RegistrationContactSettingsAdminContactArgs(
 *             phone_number="+12345000000",
 *             email="[email protected]",
 *             postal_address=gcp.clouddomains.RegistrationContactSettingsAdminContactPostalAddressArgs(
 *                 region_code="US",
 *                 postal_code="95050",
 *                 administrative_area="CA",
 *                 locality="Example City",
 *                 address_lines=["1234 Example street"],
 *                 recipients=["example recipient"],
 *             ),
 *         ),
 *         technical_contact=gcp.clouddomains.RegistrationContactSettingsTechnicalContactArgs(
 *             phone_number="+12345000000",
 *             email="[email protected]",
 *             postal_address=gcp.clouddomains.RegistrationContactSettingsTechnicalContactPostalAddressArgs(
 *                 region_code="US",
 *                 postal_code="95050",
 *                 administrative_area="CA",
 *                 locality="Example City",
 *                 address_lines=["1234 Example street"],
 *                 recipients=["example recipient"],
 *             ),
 *         ),
 *     ))
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using Gcp = Pulumi.Gcp;
 * return await Deployment.RunAsync(() =>
 * {
 *     var myRegistration = new Gcp.CloudDomains.Registration("my_registration", new()
 *     {
 *         DomainName = "example-domain.com",
 *         Location = "global",
 *         Labels =
 *         {
 *             { "labelkey", "labelvalue" },
 *         },
 *         YearlyPrice = new Gcp.CloudDomains.Inputs.RegistrationYearlyPriceArgs
 *         {
 *             CurrencyCode = "USD",
 *             Units = "12",
 *         },
 *         DnsSettings = new Gcp.CloudDomains.Inputs.RegistrationDnsSettingsArgs
 *         {
 *             CustomDns = new Gcp.CloudDomains.Inputs.RegistrationDnsSettingsCustomDnsArgs
 *             {
 *                 NameServers = new[]
 *                 {
 *                     "ns-cloud-a1.googledomains.com.",
 *                     "ns-cloud-a2.googledomains.com.",
 *                     "ns-cloud-a3.googledomains.com.",
 *                     "ns-cloud-a4.googledomains.com.",
 *                 },
 *             },
 *         },
 *         ContactSettings = new Gcp.CloudDomains.Inputs.RegistrationContactSettingsArgs
 *         {
 *             Privacy = "REDACTED_CONTACT_DATA",
 *             RegistrantContact = new Gcp.CloudDomains.Inputs.RegistrationContactSettingsRegistrantContactArgs
 *             {
 *                 PhoneNumber = "+12345000000",
 *                 Email = "[email protected]",
 *                 PostalAddress = new Gcp.CloudDomains.Inputs.RegistrationContactSettingsRegistrantContactPostalAddressArgs
 *                 {
 *                     RegionCode = "US",
 *                     PostalCode = "95050",
 *                     AdministrativeArea = "CA",
 *                     Locality = "Example City",
 *                     AddressLines = new[]
 *                     {
 *                         "1234 Example street",
 *                     },
 *                     Recipients = new[]
 *                     {
 *                         "example recipient",
 *                     },
 *                 },
 *             },
 *             AdminContact = new Gcp.CloudDomains.Inputs.RegistrationContactSettingsAdminContactArgs
 *             {
 *                 PhoneNumber = "+12345000000",
 *                 Email = "[email protected]",
 *                 PostalAddress = new Gcp.CloudDomains.Inputs.RegistrationContactSettingsAdminContactPostalAddressArgs
 *                 {
 *                     RegionCode = "US",
 *                     PostalCode = "95050",
 *                     AdministrativeArea = "CA",
 *                     Locality = "Example City",
 *                     AddressLines = new[]
 *                     {
 *                         "1234 Example street",
 *                     },
 *                     Recipients = new[]
 *                     {
 *                         "example recipient",
 *                     },
 *                 },
 *             },
 *             TechnicalContact = new Gcp.CloudDomains.Inputs.RegistrationContactSettingsTechnicalContactArgs
 *             {
 *                 PhoneNumber = "+12345000000",
 *                 Email = "[email protected]",
 *                 PostalAddress = new Gcp.CloudDomains.Inputs.RegistrationContactSettingsTechnicalContactPostalAddressArgs
 *                 {
 *                     RegionCode = "US",
 *                     PostalCode = "95050",
 *                     AdministrativeArea = "CA",
 *                     Locality = "Example City",
 *                     AddressLines = new[]
 *                     {
 *                         "1234 Example street",
 *                     },
 *                     Recipients = new[]
 *                     {
 *                         "example recipient",
 *                     },
 *                 },
 *             },
 *         },
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/clouddomains"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		_, err := clouddomains.NewRegistration(ctx, "my_registration", &clouddomains.RegistrationArgs{
 * 			DomainName: pulumi.String("example-domain.com"),
 * 			Location:   pulumi.String("global"),
 * 			Labels: pulumi.StringMap{
 * 				"labelkey": pulumi.String("labelvalue"),
 * 			},
 * 			YearlyPrice: &clouddomains.RegistrationYearlyPriceArgs{
 * 				CurrencyCode: pulumi.String("USD"),
 * 				Units:        pulumi.String("12"),
 * 			},
 * 			DnsSettings: &clouddomains.RegistrationDnsSettingsArgs{
 * 				CustomDns: &clouddomains.RegistrationDnsSettingsCustomDnsArgs{
 * 					NameServers: pulumi.StringArray{
 * 						pulumi.String("ns-cloud-a1.googledomains.com."),
 * 						pulumi.String("ns-cloud-a2.googledomains.com."),
 * 						pulumi.String("ns-cloud-a3.googledomains.com."),
 * 						pulumi.String("ns-cloud-a4.googledomains.com."),
 * 					},
 * 				},
 * 			},
 * 			ContactSettings: &clouddomains.RegistrationContactSettingsArgs{
 * 				Privacy: pulumi.String("REDACTED_CONTACT_DATA"),
 * 				RegistrantContact: &clouddomains.RegistrationContactSettingsRegistrantContactArgs{
 * 					PhoneNumber: pulumi.String("+12345000000"),
 * 					Email:       pulumi.String("[email protected]"),
 * 					PostalAddress: &clouddomains.RegistrationContactSettingsRegistrantContactPostalAddressArgs{
 * 						RegionCode:         pulumi.String("US"),
 * 						PostalCode:         pulumi.String("95050"),
 * 						AdministrativeArea: pulumi.String("CA"),
 * 						Locality:           pulumi.String("Example City"),
 * 						AddressLines: pulumi.StringArray{
 * 							pulumi.String("1234 Example street"),
 * 						},
 * 						Recipients: pulumi.StringArray{
 * 							pulumi.String("example recipient"),
 * 						},
 * 					},
 * 				},
 * 				AdminContact: &clouddomains.RegistrationContactSettingsAdminContactArgs{
 * 					PhoneNumber: pulumi.String("+12345000000"),
 * 					Email:       pulumi.String("[email protected]"),
 * 					PostalAddress: &clouddomains.RegistrationContactSettingsAdminContactPostalAddressArgs{
 * 						RegionCode:         pulumi.String("US"),
 * 						PostalCode:         pulumi.String("95050"),
 * 						AdministrativeArea: pulumi.String("CA"),
 * 						Locality:           pulumi.String("Example City"),
 * 						AddressLines: pulumi.StringArray{
 * 							pulumi.String("1234 Example street"),
 * 						},
 * 						Recipients: pulumi.StringArray{
 * 							pulumi.String("example recipient"),
 * 						},
 * 					},
 * 				},
 * 				TechnicalContact: &clouddomains.RegistrationContactSettingsTechnicalContactArgs{
 * 					PhoneNumber: pulumi.String("+12345000000"),
 * 					Email:       pulumi.String("[email protected]"),
 * 					PostalAddress: &clouddomains.RegistrationContactSettingsTechnicalContactPostalAddressArgs{
 * 						RegionCode:         pulumi.String("US"),
 * 						PostalCode:         pulumi.String("95050"),
 * 						AdministrativeArea: pulumi.String("CA"),
 * 						Locality:           pulumi.String("Example City"),
 * 						AddressLines: pulumi.StringArray{
 * 							pulumi.String("1234 Example street"),
 * 						},
 * 						Recipients: pulumi.StringArray{
 * 							pulumi.String("example recipient"),
 * 						},
 * 					},
 * 				},
 * 			},
 * 		})
 * 		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.gcp.clouddomains.Registration;
 * import com.pulumi.gcp.clouddomains.RegistrationArgs;
 * import com.pulumi.gcp.clouddomains.inputs.RegistrationYearlyPriceArgs;
 * import com.pulumi.gcp.clouddomains.inputs.RegistrationDnsSettingsArgs;
 * import com.pulumi.gcp.clouddomains.inputs.RegistrationDnsSettingsCustomDnsArgs;
 * import com.pulumi.gcp.clouddomains.inputs.RegistrationContactSettingsArgs;
 * import com.pulumi.gcp.clouddomains.inputs.RegistrationContactSettingsRegistrantContactArgs;
 * import com.pulumi.gcp.clouddomains.inputs.RegistrationContactSettingsRegistrantContactPostalAddressArgs;
 * import com.pulumi.gcp.clouddomains.inputs.RegistrationContactSettingsAdminContactArgs;
 * import com.pulumi.gcp.clouddomains.inputs.RegistrationContactSettingsAdminContactPostalAddressArgs;
 * import com.pulumi.gcp.clouddomains.inputs.RegistrationContactSettingsTechnicalContactArgs;
 * import com.pulumi.gcp.clouddomains.inputs.RegistrationContactSettingsTechnicalContactPostalAddressArgs;
 * 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 myRegistration = new Registration("myRegistration", RegistrationArgs.builder()
 *             .domainName("example-domain.com")
 *             .location("global")
 *             .labels(Map.of("labelkey", "labelvalue"))
 *             .yearlyPrice(RegistrationYearlyPriceArgs.builder()
 *                 .currencyCode("USD")
 *                 .units(12)
 *                 .build())
 *             .dnsSettings(RegistrationDnsSettingsArgs.builder()
 *                 .customDns(RegistrationDnsSettingsCustomDnsArgs.builder()
 *                     .nameServers(
 *                         "ns-cloud-a1.googledomains.com.",
 *                         "ns-cloud-a2.googledomains.com.",
 *                         "ns-cloud-a3.googledomains.com.",
 *                         "ns-cloud-a4.googledomains.com.")
 *                     .build())
 *                 .build())
 *             .contactSettings(RegistrationContactSettingsArgs.builder()
 *                 .privacy("REDACTED_CONTACT_DATA")
 *                 .registrantContact(RegistrationContactSettingsRegistrantContactArgs.builder()
 *                     .phoneNumber("+12345000000")
 *                     .email("[email protected]")
 *                     .postalAddress(RegistrationContactSettingsRegistrantContactPostalAddressArgs.builder()
 *                         .regionCode("US")
 *                         .postalCode("95050")
 *                         .administrativeArea("CA")
 *                         .locality("Example City")
 *                         .addressLines("1234 Example street")
 *                         .recipients("example recipient")
 *                         .build())
 *                     .build())
 *                 .adminContact(RegistrationContactSettingsAdminContactArgs.builder()
 *                     .phoneNumber("+12345000000")
 *                     .email("[email protected]")
 *                     .postalAddress(RegistrationContactSettingsAdminContactPostalAddressArgs.builder()
 *                         .regionCode("US")
 *                         .postalCode("95050")
 *                         .administrativeArea("CA")
 *                         .locality("Example City")
 *                         .addressLines("1234 Example street")
 *                         .recipients("example recipient")
 *                         .build())
 *                     .build())
 *                 .technicalContact(RegistrationContactSettingsTechnicalContactArgs.builder()
 *                     .phoneNumber("+12345000000")
 *                     .email("[email protected]")
 *                     .postalAddress(RegistrationContactSettingsTechnicalContactPostalAddressArgs.builder()
 *                         .regionCode("US")
 *                         .postalCode("95050")
 *                         .administrativeArea("CA")
 *                         .locality("Example City")
 *                         .addressLines("1234 Example street")
 *                         .recipients("example recipient")
 *                         .build())
 *                     .build())
 *                 .build())
 *             .build());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   myRegistration:
 *     type: gcp:clouddomains:Registration
 *     name: my_registration
 *     properties:
 *       domainName: example-domain.com
 *       location: global
 *       labels:
 *         labelkey: labelvalue
 *       yearlyPrice:
 *         currencyCode: USD
 *         units: 12
 *       dnsSettings:
 *         customDns:
 *           nameServers:
 *             - ns-cloud-a1.googledomains.com.
 *             - ns-cloud-a2.googledomains.com.
 *             - ns-cloud-a3.googledomains.com.
 *             - ns-cloud-a4.googledomains.com.
 *       contactSettings:
 *         privacy: REDACTED_CONTACT_DATA
 *         registrantContact:
 *           phoneNumber: '+12345000000'
 *           email: [email protected]
 *           postalAddress:
 *             regionCode: US
 *             postalCode: '95050'
 *             administrativeArea: CA
 *             locality: Example City
 *             addressLines:
 *               - 1234 Example street
 *             recipients:
 *               - example recipient
 *         adminContact:
 *           phoneNumber: '+12345000000'
 *           email: [email protected]
 *           postalAddress:
 *             regionCode: US
 *             postalCode: '95050'
 *             administrativeArea: CA
 *             locality: Example City
 *             addressLines:
 *               - 1234 Example street
 *             recipients:
 *               - example recipient
 *         technicalContact:
 *           phoneNumber: '+12345000000'
 *           email: [email protected]
 *           postalAddress:
 *             regionCode: US
 *             postalCode: '95050'
 *             administrativeArea: CA
 *             locality: Example City
 *             addressLines:
 *               - 1234 Example street
 *             recipients:
 *               - example recipient
 * ```
 * 
 * ## Import
 * Registration can be imported using any of these accepted formats:
 * * `projects/{{project}}/locations/{{location}}/registrations/{{domain_name}}`
 * * `{{project}}/{{location}}/{{domain_name}}`
 * * `{{location}}/{{domain_name}}`
 * When using the `pulumi import` command, Registration can be imported using one of the formats above. For example:
 * ```sh
 * $ pulumi import gcp:clouddomains/registration:Registration default projects/{{project}}/locations/{{location}}/registrations/{{domain_name}}
 * ```
 * ```sh
 * $ pulumi import gcp:clouddomains/registration:Registration default {{project}}/{{location}}/{{domain_name}}
 * ```
 * ```sh
 * $ pulumi import gcp:clouddomains/registration:Registration default {{location}}/{{domain_name}}
 * ```
 */
public class Registration internal constructor(
    override val javaResource: com.pulumi.gcp.clouddomains.Registration,
) : KotlinCustomResource(javaResource, RegistrationMapper) {
    /**
     * The list of contact notices that the caller acknowledges. Possible value is PUBLIC_CONTACT_DATA_ACKNOWLEDGEMENT
     */
    public val contactNotices: Output>?
        get() = javaResource.contactNotices().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.map({ args0 -> args0 })
            }).orElse(null)
        })

    /**
     * Required. Settings for contact information linked to the Registration.
     * Structure is documented below.
     */
    public val contactSettings: Output
        get() = javaResource.contactSettings().applyValue({ args0 ->
            args0.let({ args0 ->
                registrationContactSettingsToKotlin(args0)
            })
        })

    /**
     * Output only. Time at which the automation was created.
     */
    public val createTime: Output
        get() = javaResource.createTime().applyValue({ args0 -> args0 })

    /**
     * Settings controlling the DNS configuration of the Registration.
     */
    public val dnsSettings: Output?
        get() = javaResource.dnsSettings().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 ->
                    registrationDnsSettingsToKotlin(args0)
                })
            }).orElse(null)
        })

    /**
     * Required. The domain name. Unicode domain names must be expressed in Punycode format.
     */
    public val domainName: Output
        get() = javaResource.domainName().applyValue({ args0 -> args0 })

    /**
     * The list of domain notices that you acknowledge. Possible value is HSTS_PRELOADED
     */
    public val domainNotices: Output>?
        get() = javaResource.domainNotices().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.map({ args0 -> args0 })
            }).orElse(null)
        })

    /**
     * All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
     */
    public val effectiveLabels: Output>
        get() = javaResource.effectiveLabels().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.key.to(args0.value)
            }).toMap()
        })

    /**
     * Output only. Time at which the automation was updated.
     */
    public val expireTime: Output
        get() = javaResource.expireTime().applyValue({ args0 -> args0 })

    /**
     * Output only. The set of issues with the Registration that require attention.
     */
    public val issues: Output>
        get() = javaResource.issues().applyValue({ args0 -> args0.map({ args0 -> args0 }) })

    /**
     * Set of labels associated with the Registration. **Note**: This field is non-authoritative, and will only manage the
     * labels present in your configuration. Please refer to the field 'effective_labels' for all of the labels present on the
     * resource.
     */
    public val labels: Output>?
        get() = javaResource.labels().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.map({ args0 ->
                    args0.key.to(args0.value)
                }).toMap()
            }).orElse(null)
        })

    /**
     * The location for the resource
     */
    public val location: Output
        get() = javaResource.location().applyValue({ args0 -> args0 })

    /**
     * Settings for management of the Registration, including renewal, billing, and transfer
     */
    public val managementSettings: Output
        get() = javaResource.managementSettings().applyValue({ args0 ->
            args0.let({ args0 ->
                registrationManagementSettingsToKotlin(args0)
            })
        })

    /**
     * Output only. Name of the Registration resource, in the format projects/*/locations/*/registrations/.
     * */*/
     */
    public val name: Output
        get() = javaResource.name().applyValue({ args0 -> args0 })

    public val project: Output
        get() = javaResource.project().applyValue({ args0 -> args0 })

    /**
     * The combination of labels configured directly on the resource
     * and default labels configured on the provider.
     */
    public val pulumiLabels: Output>
        get() = javaResource.pulumiLabels().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.key.to(args0.value)
            }).toMap()
        })

    /**
     * Output only. The reason the domain registration failed. Only set for domains in REGISTRATION_FAILED state.
     */
    public val registerFailureReason: Output
        get() = javaResource.registerFailureReason().applyValue({ args0 -> args0 })

    /**
     * Output only. The current state of the Registration.
     */
    public val state: Output
        get() = javaResource.state().applyValue({ args0 -> args0 })

    /**
     * Output only. Set of options for the contactSettings.privacy field that this Registration supports.
     */
    public val supportedPrivacies: Output>
        get() = javaResource.supportedPrivacies().applyValue({ args0 -> args0.map({ args0 -> args0 }) })

    /**
     * Required. Yearly price to register or renew the domain. The value that should be put here can be obtained from
     * registrations.retrieveRegisterParameters or registrations.searchDomains calls.
     * Structure is documented below.
     */
    public val yearlyPrice: Output
        get() = javaResource.yearlyPrice().applyValue({ args0 ->
            args0.let({ args0 ->
                registrationYearlyPriceToKotlin(args0)
            })
        })
}

public object RegistrationMapper : ResourceMapper {
    override fun supportsMappingOfType(javaResource: Resource): Boolean =
        com.pulumi.gcp.clouddomains.Registration::class == javaResource::class

    override fun map(javaResource: Resource): Registration = Registration(
        javaResource as
            com.pulumi.gcp.clouddomains.Registration,
    )
}

/**
 * @see [Registration].
 * @param name The _unique_ name of the resulting resource.
 * @param block Builder for [Registration].
 */
public suspend fun registration(
    name: String,
    block: suspend RegistrationResourceBuilder.() -> Unit,
): Registration {
    val builder = RegistrationResourceBuilder()
    builder.name(name)
    block(builder)
    return builder.build()
}

/**
 * @see [Registration].
 * @param name The _unique_ name of the resulting resource.
 */
public fun registration(name: String): Registration {
    val builder = RegistrationResourceBuilder()
    builder.name(name)
    return builder.build()
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy