1. Packages
  2. Google Cloud (GCP) Classic
  3. API Docs
  4. certificatemanager
  5. getDnsAuthorization
Google Cloud v9.0.0 published on Thursday, Sep 18, 2025 by Pulumi

gcp.certificatemanager.getDnsAuthorization

Explore with Pulumi AI

gcp logo
Google Cloud v9.0.0 published on Thursday, Sep 18, 2025 by Pulumi

    Use this data source to get information about a Certificate Manager DNS Authorization. For more details, see the API documentation.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as gcp from "@pulumi/gcp";
    
    const _default = gcp.certificatemanager.getDnsAuthorization({
        name: "my-dns-auth",
        location: "global",
    });
    
    import pulumi
    import pulumi_gcp as gcp
    
    default = gcp.certificatemanager.get_dns_authorization(name="my-dns-auth",
        location="global")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-gcp/sdk/v9/go/gcp/certificatemanager"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := certificatemanager.LookupDnsAuthorization(ctx, &certificatemanager.LookupDnsAuthorizationArgs{
    			Name:     "my-dns-auth",
    			Location: pulumi.StringRef("global"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Gcp = Pulumi.Gcp;
    
    return await Deployment.RunAsync(() => 
    {
        var @default = Gcp.CertificateManager.GetDnsAuthorization.Invoke(new()
        {
            Name = "my-dns-auth",
            Location = "global",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.gcp.certificatemanager.CertificatemanagerFunctions;
    import com.pulumi.gcp.certificatemanager.inputs.GetDnsAuthorizationArgs;
    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) {
            final var default = CertificatemanagerFunctions.getDnsAuthorization(GetDnsAuthorizationArgs.builder()
                .name("my-dns-auth")
                .location("global")
                .build());
    
        }
    }
    
    variables:
      default:
        fn::invoke:
          function: gcp:certificatemanager:getDnsAuthorization
          arguments:
            name: my-dns-auth
            location: global
    

    Using getDnsAuthorization

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getDnsAuthorization(args: GetDnsAuthorizationArgs, opts?: InvokeOptions): Promise<GetDnsAuthorizationResult>
    function getDnsAuthorizationOutput(args: GetDnsAuthorizationOutputArgs, opts?: InvokeOptions): Output<GetDnsAuthorizationResult>
    def get_dns_authorization(domain: Optional[str] = None,
                              location: Optional[str] = None,
                              name: Optional[str] = None,
                              project: Optional[str] = None,
                              opts: Optional[InvokeOptions] = None) -> GetDnsAuthorizationResult
    def get_dns_authorization_output(domain: Optional[pulumi.Input[str]] = None,
                              location: Optional[pulumi.Input[str]] = None,
                              name: Optional[pulumi.Input[str]] = None,
                              project: Optional[pulumi.Input[str]] = None,
                              opts: Optional[InvokeOptions] = None) -> Output[GetDnsAuthorizationResult]
    func LookupDnsAuthorization(ctx *Context, args *LookupDnsAuthorizationArgs, opts ...InvokeOption) (*LookupDnsAuthorizationResult, error)
    func LookupDnsAuthorizationOutput(ctx *Context, args *LookupDnsAuthorizationOutputArgs, opts ...InvokeOption) LookupDnsAuthorizationResultOutput

    > Note: This function is named LookupDnsAuthorization in the Go SDK.

    public static class GetDnsAuthorization 
    {
        public static Task<GetDnsAuthorizationResult> InvokeAsync(GetDnsAuthorizationArgs args, InvokeOptions? opts = null)
        public static Output<GetDnsAuthorizationResult> Invoke(GetDnsAuthorizationInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetDnsAuthorizationResult> getDnsAuthorization(GetDnsAuthorizationArgs args, InvokeOptions options)
    public static Output<GetDnsAuthorizationResult> getDnsAuthorization(GetDnsAuthorizationArgs args, InvokeOptions options)
    
    fn::invoke:
      function: gcp:certificatemanager/getDnsAuthorization:getDnsAuthorization
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Domain string
    The name of the DNS Authorization.
    Name string
    The name of the DNS Authorization.
    Location string
    The Certificate Manager location. If not specified, "global" is used.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    Domain string
    The name of the DNS Authorization.
    Name string
    The name of the DNS Authorization.
    Location string
    The Certificate Manager location. If not specified, "global" is used.
    Project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    domain String
    The name of the DNS Authorization.
    name String
    The name of the DNS Authorization.
    location String
    The Certificate Manager location. If not specified, "global" is used.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    domain string
    The name of the DNS Authorization.
    name string
    The name of the DNS Authorization.
    location string
    The Certificate Manager location. If not specified, "global" is used.
    project string
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    domain str
    The name of the DNS Authorization.
    name str
    The name of the DNS Authorization.
    location str
    The Certificate Manager location. If not specified, "global" is used.
    project str
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
    domain String
    The name of the DNS Authorization.
    name String
    The name of the DNS Authorization.
    location String
    The Certificate Manager location. If not specified, "global" is used.
    project String
    The ID of the project in which the resource belongs. If it is not provided, the provider project is used.

    getDnsAuthorization Result

    The following output properties are available:

    Description string
    DnsResourceRecords List<GetDnsAuthorizationDnsResourceRecord>
    Domain string
    EffectiveLabels Dictionary<string, string>
    Id string
    The provider-assigned unique ID for this managed resource.
    Labels Dictionary<string, string>
    Name string
    PulumiLabels Dictionary<string, string>
    Type string
    Location string
    Project string
    Description string
    DnsResourceRecords []GetDnsAuthorizationDnsResourceRecord
    Domain string
    EffectiveLabels map[string]string
    Id string
    The provider-assigned unique ID for this managed resource.
    Labels map[string]string
    Name string
    PulumiLabels map[string]string
    Type string
    Location string
    Project string
    description String
    dnsResourceRecords List<GetDnsAuthorizationDnsResourceRecord>
    domain String
    effectiveLabels Map<String,String>
    id String
    The provider-assigned unique ID for this managed resource.
    labels Map<String,String>
    name String
    pulumiLabels Map<String,String>
    type String
    location String
    project String
    description string
    dnsResourceRecords GetDnsAuthorizationDnsResourceRecord[]
    domain string
    effectiveLabels {[key: string]: string}
    id string
    The provider-assigned unique ID for this managed resource.
    labels {[key: string]: string}
    name string
    pulumiLabels {[key: string]: string}
    type string
    location string
    project string
    description str
    dns_resource_records Sequence[GetDnsAuthorizationDnsResourceRecord]
    domain str
    effective_labels Mapping[str, str]
    id str
    The provider-assigned unique ID for this managed resource.
    labels Mapping[str, str]
    name str
    pulumi_labels Mapping[str, str]
    type str
    location str
    project str
    description String
    dnsResourceRecords List<Property Map>
    domain String
    effectiveLabels Map<String>
    id String
    The provider-assigned unique ID for this managed resource.
    labels Map<String>
    name String
    pulumiLabels Map<String>
    type String
    location String
    project String

    Supporting Types

    GetDnsAuthorizationDnsResourceRecord

    Data string
    Data of the DNS Resource Record.
    Name string
    The name of the DNS Authorization.
    Type string
    Type of the DNS Resource Record.
    Data string
    Data of the DNS Resource Record.
    Name string
    The name of the DNS Authorization.
    Type string
    Type of the DNS Resource Record.
    data String
    Data of the DNS Resource Record.
    name String
    The name of the DNS Authorization.
    type String
    Type of the DNS Resource Record.
    data string
    Data of the DNS Resource Record.
    name string
    The name of the DNS Authorization.
    type string
    Type of the DNS Resource Record.
    data str
    Data of the DNS Resource Record.
    name str
    The name of the DNS Authorization.
    type str
    Type of the DNS Resource Record.
    data String
    Data of the DNS Resource Record.
    name String
    The name of the DNS Authorization.
    type String
    Type of the DNS Resource Record.

    Package Details

    Repository
    Google Cloud (GCP) Classic pulumi/pulumi-gcp
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the google-beta Terraform Provider.
    gcp logo
    Google Cloud v9.0.0 published on Thursday, Sep 18, 2025 by Pulumi