DigitalOcean

v4.16.0 published on Wednesday, Sep 28, 2022 by Pulumi

getRecords

Retrieve information about all DNS records within a domain, with the ability to filter and sort the results. If no filters are specified, all records will be returned.

Using getRecords

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 getRecords(args: GetRecordsArgs, opts?: InvokeOptions): Promise<GetRecordsResult>
function getRecordsOutput(args: GetRecordsOutputArgs, opts?: InvokeOptions): Output<GetRecordsResult>
def get_records(domain: Optional[str] = None,
                filters: Optional[Sequence[GetRecordsFilter]] = None,
                sorts: Optional[Sequence[GetRecordsSort]] = None,
                opts: Optional[InvokeOptions] = None) -> GetRecordsResult
def get_records_output(domain: Optional[pulumi.Input[str]] = None,
                filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetRecordsFilterArgs]]]] = None,
                sorts: Optional[pulumi.Input[Sequence[pulumi.Input[GetRecordsSortArgs]]]] = None,
                opts: Optional[InvokeOptions] = None) -> Output[GetRecordsResult]
func GetRecords(ctx *Context, args *GetRecordsArgs, opts ...InvokeOption) (*GetRecordsResult, error)
func GetRecordsOutput(ctx *Context, args *GetRecordsOutputArgs, opts ...InvokeOption) GetRecordsResultOutput

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

public static class GetRecords 
{
    public static Task<GetRecordsResult> InvokeAsync(GetRecordsArgs args, InvokeOptions? opts = null)
    public static Output<GetRecordsResult> Invoke(GetRecordsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetRecordsResult> getRecords(GetRecordsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
  function: digitalocean:index/getRecords:getRecords
  arguments:
    # arguments dictionary

The following arguments are supported:

Domain string

The domain name to search for DNS records

Filters List<Pulumi.DigitalOcean.Inputs.GetRecordsFilter>

Filter the results. The filter block is documented below.

Sorts List<Pulumi.DigitalOcean.Inputs.GetRecordsSort>

Sort the results. The sort block is documented below.

Domain string

The domain name to search for DNS records

Filters []GetRecordsFilter

Filter the results. The filter block is documented below.

Sorts []GetRecordsSort

Sort the results. The sort block is documented below.

domain String

The domain name to search for DNS records

filters List<GetRecordsFilter>

Filter the results. The filter block is documented below.

sorts List<GetRecordsSort>

Sort the results. The sort block is documented below.

domain string

The domain name to search for DNS records

filters GetRecordsFilter[]

Filter the results. The filter block is documented below.

sorts GetRecordsSort[]

Sort the results. The sort block is documented below.

domain str

The domain name to search for DNS records

filters Sequence[GetRecordsFilter]

Filter the results. The filter block is documented below.

sorts Sequence[GetRecordsSort]

Sort the results. The sort block is documented below.

domain String

The domain name to search for DNS records

filters List<Property Map>

Filter the results. The filter block is documented below.

sorts List<Property Map>

Sort the results. The sort block is documented below.

getRecords Result

The following output properties are available:

Domain string
Id string

The provider-assigned unique ID for this managed resource.

Records []GetRecordsRecord
Filters []GetRecordsFilter
Sorts []GetRecordsSort
domain String
id String

The provider-assigned unique ID for this managed resource.

records List<GetRecordsRecord>
filters List<GetRecordsFilter>
sorts List<GetRecordsSort>
domain string
id string

The provider-assigned unique ID for this managed resource.

records GetRecordsRecord[]
filters GetRecordsFilter[]
sorts GetRecordsSort[]
domain str
id str

The provider-assigned unique ID for this managed resource.

records Sequence[GetRecordsRecord]
filters Sequence[GetRecordsFilter]
sorts Sequence[GetRecordsSort]
domain String
id String

The provider-assigned unique ID for this managed resource.

records List<Property Map>
filters List<Property Map>
sorts List<Property Map>

Supporting Types

GetRecordsFilter

Key string

Filter the DNS records by this key. This may be one of domain, flags, name, port, priority, tag, ttl, type, value, or weight.

Values List<string>

A list of values to match against the key field. Only retrieves DNS records where the key field takes on one or more of the values provided here.

All bool

Set to true to require that a field match all of the values instead of just one or more of them. This is useful when matching against multi-valued fields such as lists or sets where you want to ensure that all of the values are present in the list or set.

MatchBy string

One of exact (default), re, or substring. For string-typed fields, specify re to match by using the values as regular expressions, or specify substring to match by treating the values as substrings to find within the string field.

Key string

Filter the DNS records by this key. This may be one of domain, flags, name, port, priority, tag, ttl, type, value, or weight.

Values []string

A list of values to match against the key field. Only retrieves DNS records where the key field takes on one or more of the values provided here.

All bool

Set to true to require that a field match all of the values instead of just one or more of them. This is useful when matching against multi-valued fields such as lists or sets where you want to ensure that all of the values are present in the list or set.

MatchBy string

One of exact (default), re, or substring. For string-typed fields, specify re to match by using the values as regular expressions, or specify substring to match by treating the values as substrings to find within the string field.

key String

Filter the DNS records by this key. This may be one of domain, flags, name, port, priority, tag, ttl, type, value, or weight.

values List<String>

A list of values to match against the key field. Only retrieves DNS records where the key field takes on one or more of the values provided here.

all Boolean

Set to true to require that a field match all of the values instead of just one or more of them. This is useful when matching against multi-valued fields such as lists or sets where you want to ensure that all of the values are present in the list or set.

matchBy String

One of exact (default), re, or substring. For string-typed fields, specify re to match by using the values as regular expressions, or specify substring to match by treating the values as substrings to find within the string field.

key string

Filter the DNS records by this key. This may be one of domain, flags, name, port, priority, tag, ttl, type, value, or weight.

values string[]

A list of values to match against the key field. Only retrieves DNS records where the key field takes on one or more of the values provided here.

all boolean

Set to true to require that a field match all of the values instead of just one or more of them. This is useful when matching against multi-valued fields such as lists or sets where you want to ensure that all of the values are present in the list or set.

matchBy string

One of exact (default), re, or substring. For string-typed fields, specify re to match by using the values as regular expressions, or specify substring to match by treating the values as substrings to find within the string field.

key str

Filter the DNS records by this key. This may be one of domain, flags, name, port, priority, tag, ttl, type, value, or weight.

values Sequence[str]

A list of values to match against the key field. Only retrieves DNS records where the key field takes on one or more of the values provided here.

all bool

Set to true to require that a field match all of the values instead of just one or more of them. This is useful when matching against multi-valued fields such as lists or sets where you want to ensure that all of the values are present in the list or set.

match_by str

One of exact (default), re, or substring. For string-typed fields, specify re to match by using the values as regular expressions, or specify substring to match by treating the values as substrings to find within the string field.

key String

Filter the DNS records by this key. This may be one of domain, flags, name, port, priority, tag, ttl, type, value, or weight.

values List<String>

A list of values to match against the key field. Only retrieves DNS records where the key field takes on one or more of the values provided here.

all Boolean

Set to true to require that a field match all of the values instead of just one or more of them. This is useful when matching against multi-valued fields such as lists or sets where you want to ensure that all of the values are present in the list or set.

matchBy String

One of exact (default), re, or substring. For string-typed fields, specify re to match by using the values as regular expressions, or specify substring to match by treating the values as substrings to find within the string field.

GetRecordsRecord

Domain string

The domain name to search for DNS records

Flags int
Id int
Name string
Port int
Priority int
Tag string
Ttl int
Type string
Value string
Weight int
Domain string

The domain name to search for DNS records

Flags int
Id int
Name string
Port int
Priority int
Tag string
Ttl int
Type string
Value string
Weight int
domain String

The domain name to search for DNS records

flags Integer
id Integer
name String
port Integer
priority Integer
tag String
ttl Integer
type String
value String
weight Integer
domain string

The domain name to search for DNS records

flags number
id number
name string
port number
priority number
tag string
ttl number
type string
value string
weight number
domain str

The domain name to search for DNS records

flags int
id int
name str
port int
priority int
tag str
ttl int
type str
value str
weight int
domain String

The domain name to search for DNS records

flags Number
id Number
name String
port Number
priority Number
tag String
ttl Number
type String
value String
weight Number

GetRecordsSort

Key string

Sort the DNS records by this key. This may be one of domain, flags, name, port, priority, tag, ttl, type, value, or weight.

Direction string

The sort direction. This may be either asc or desc.

Key string

Sort the DNS records by this key. This may be one of domain, flags, name, port, priority, tag, ttl, type, value, or weight.

Direction string

The sort direction. This may be either asc or desc.

key String

Sort the DNS records by this key. This may be one of domain, flags, name, port, priority, tag, ttl, type, value, or weight.

direction String

The sort direction. This may be either asc or desc.

key string

Sort the DNS records by this key. This may be one of domain, flags, name, port, priority, tag, ttl, type, value, or weight.

direction string

The sort direction. This may be either asc or desc.

key str

Sort the DNS records by this key. This may be one of domain, flags, name, port, priority, tag, ttl, type, value, or weight.

direction str

The sort direction. This may be either asc or desc.

key String

Sort the DNS records by this key. This may be one of domain, flags, name, port, priority, tag, ttl, type, value, or weight.

direction String

The sort direction. This may be either asc or desc.

Package Details

Repository
https://github.com/pulumi/pulumi-digitalocean
License
Apache-2.0
Notes

This Pulumi package is based on the digitalocean Terraform Provider.