1. Packages
  2. Unifi
  3. API Docs
  4. dns
  5. Record
Viewing docs for Unifi v0.2.0
published on Tuesday, Feb 17, 2026 by Pulumiverse
unifi logo
Viewing docs for Unifi v0.2.0
published on Tuesday, Feb 17, 2026 by Pulumiverse

    The unifi.dns.Record resource manages DNS records in the UniFi controller’s DNS server.

    This resource allows you to configure various types of DNS records for local name resolution. Common use cases include:

    • Creating A records for local servers and devices
    • Setting up CNAME aliases for internal services
    • Configuring MX records for local mail servers
    • Adding TXT records for service verification

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as unifi from "@pulumiverse/unifi";
    
    const aRecord = new unifi.dns.Record("a_record", {
        name: "example.mydomain.com",
        type: "A",
        value: "192.168.1.190",
    });
    const cnameRecord = new unifi.dns.Record("cname_record", {
        name: "example.mydomain.com",
        type: "CNAME",
        value: "example.com",
    });
    
    import pulumi
    import pulumiverse_unifi as unifi
    
    a_record = unifi.dns.Record("a_record",
        name="example.mydomain.com",
        type="A",
        value="192.168.1.190")
    cname_record = unifi.dns.Record("cname_record",
        name="example.mydomain.com",
        type="CNAME",
        value="example.com")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumiverse/pulumi-unifi/sdk/go/unifi/dns"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := dns.NewRecord(ctx, "a_record", &dns.RecordArgs{
    			Name:  pulumi.String("example.mydomain.com"),
    			Type:  pulumi.String("A"),
    			Value: pulumi.String("192.168.1.190"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = dns.NewRecord(ctx, "cname_record", &dns.RecordArgs{
    			Name:  pulumi.String("example.mydomain.com"),
    			Type:  pulumi.String("CNAME"),
    			Value: pulumi.String("example.com"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Unifi = Pulumiverse.Unifi;
    
    return await Deployment.RunAsync(() => 
    {
        var aRecord = new Unifi.Dns.Record("a_record", new()
        {
            Name = "example.mydomain.com",
            Type = "A",
            Value = "192.168.1.190",
        });
    
        var cnameRecord = new Unifi.Dns.Record("cname_record", new()
        {
            Name = "example.mydomain.com",
            Type = "CNAME",
            Value = "example.com",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumiverse.unifi.dns.Record;
    import com.pulumiverse.unifi.dns.RecordArgs;
    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 aRecord = new Record("aRecord", RecordArgs.builder()
                .name("example.mydomain.com")
                .type("A")
                .value("192.168.1.190")
                .build());
    
            var cnameRecord = new Record("cnameRecord", RecordArgs.builder()
                .name("example.mydomain.com")
                .type("CNAME")
                .value("example.com")
                .build());
    
        }
    }
    
    resources:
      aRecord:
        type: unifi:dns:Record
        name: a_record
        properties:
          name: example.mydomain.com
          type: A
          value: 192.168.1.190
      cnameRecord:
        type: unifi:dns:Record
        name: cname_record
        properties:
          name: example.mydomain.com
          type: CNAME
          value: example.com
    

    Create Record Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Record(name: string, args: RecordArgs, opts?: CustomResourceOptions);
    @overload
    def Record(resource_name: str,
               args: RecordArgs,
               opts: Optional[ResourceOptions] = None)
    
    @overload
    def Record(resource_name: str,
               opts: Optional[ResourceOptions] = None,
               type: Optional[str] = None,
               value: Optional[str] = None,
               enabled: Optional[bool] = None,
               name: Optional[str] = None,
               port: Optional[int] = None,
               priority: Optional[int] = None,
               site: Optional[str] = None,
               ttl: Optional[int] = None,
               weight: Optional[int] = None)
    func NewRecord(ctx *Context, name string, args RecordArgs, opts ...ResourceOption) (*Record, error)
    public Record(string name, RecordArgs args, CustomResourceOptions? opts = null)
    public Record(String name, RecordArgs args)
    public Record(String name, RecordArgs args, CustomResourceOptions options)
    
    type: unifi:dns:Record
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args RecordArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args RecordArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args RecordArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args RecordArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args RecordArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var recordResource = new Unifi.Dns.Record("recordResource", new()
    {
        Type = "string",
        Value = "string",
        Enabled = false,
        Name = "string",
        Port = 0,
        Priority = 0,
        Site = "string",
        Ttl = 0,
        Weight = 0,
    });
    
    example, err := dns.NewRecord(ctx, "recordResource", &dns.RecordArgs{
    	Type:     pulumi.String("string"),
    	Value:    pulumi.String("string"),
    	Enabled:  pulumi.Bool(false),
    	Name:     pulumi.String("string"),
    	Port:     pulumi.Int(0),
    	Priority: pulumi.Int(0),
    	Site:     pulumi.String("string"),
    	Ttl:      pulumi.Int(0),
    	Weight:   pulumi.Int(0),
    })
    
    var recordResource = new Record("recordResource", RecordArgs.builder()
        .type("string")
        .value("string")
        .enabled(false)
        .name("string")
        .port(0)
        .priority(0)
        .site("string")
        .ttl(0)
        .weight(0)
        .build());
    
    record_resource = unifi.dns.Record("recordResource",
        type="string",
        value="string",
        enabled=False,
        name="string",
        port=0,
        priority=0,
        site="string",
        ttl=0,
        weight=0)
    
    const recordResource = new unifi.dns.Record("recordResource", {
        type: "string",
        value: "string",
        enabled: false,
        name: "string",
        port: 0,
        priority: 0,
        site: "string",
        ttl: 0,
        weight: 0,
    });
    
    type: unifi:dns:Record
    properties:
        enabled: false
        name: string
        port: 0
        priority: 0
        site: string
        ttl: 0
        type: string
        value: string
        weight: 0
    

    Record Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The Record resource accepts the following input properties:

    Type string
    The type of DNS record. Valid values are:

    • A - Maps a hostname to IPv4 address
    • AAAA - Maps a hostname to IPv6 address
    • CNAME - Creates an alias for another domain name
    • MX - Specifies mail servers for the domain
    • NS - Delegates a subdomain to a set of name servers
    • PTR - Creates a pointer to a canonical name (reverse DNS)
    • SOA - Specifies authoritative information about the domain
    • SRV - Specifies location of services (hostname and port)
    • TXT - Holds descriptive text
    Value string
    The content of the DNS record. The expected value depends on the record type:

    • For A records: IPv4 address (e.g., '192.168.1.10')
    • For AAAA records: IPv6 address
    • For CNAME records: Canonical name (e.g., 'server1.example.com')
    • For MX records: Mail server hostname
    • For TXT records: Text content (e.g., 'v=spf1 include:_spf.example.com ~all')
    Enabled bool
    Whether the DNS record is active. Defaults to true. Set to false to temporarily disable resolution without removing the record.
    Name string
    DNS record name.
    Port int
    The port number for SRV records. Valid values are between 1 and 65535. Only used with SRV records.
    Priority int
    Priority value for MX and SRV records. Lower values indicate higher priority. Required for MX and SRV records, ignored for other types.
    Site string
    The name of the UniFi site where this resource should be applied. If not specified, the default site will be used.
    Ttl int
    Time To Live (TTL) in seconds, determines how long DNS resolvers should cache this record. Set to 0 for automatic TTL. Common values: 300 (5 minutes), 3600 (1 hour), 86400 (1 day).
    Weight int
    A relative weight for SRV records with the same priority. Higher values get proportionally more traffic. Only used with SRV records.
    Type string
    The type of DNS record. Valid values are:

    • A - Maps a hostname to IPv4 address
    • AAAA - Maps a hostname to IPv6 address
    • CNAME - Creates an alias for another domain name
    • MX - Specifies mail servers for the domain
    • NS - Delegates a subdomain to a set of name servers
    • PTR - Creates a pointer to a canonical name (reverse DNS)
    • SOA - Specifies authoritative information about the domain
    • SRV - Specifies location of services (hostname and port)
    • TXT - Holds descriptive text
    Value string
    The content of the DNS record. The expected value depends on the record type:

    • For A records: IPv4 address (e.g., '192.168.1.10')
    • For AAAA records: IPv6 address
    • For CNAME records: Canonical name (e.g., 'server1.example.com')
    • For MX records: Mail server hostname
    • For TXT records: Text content (e.g., 'v=spf1 include:_spf.example.com ~all')
    Enabled bool
    Whether the DNS record is active. Defaults to true. Set to false to temporarily disable resolution without removing the record.
    Name string
    DNS record name.
    Port int
    The port number for SRV records. Valid values are between 1 and 65535. Only used with SRV records.
    Priority int
    Priority value for MX and SRV records. Lower values indicate higher priority. Required for MX and SRV records, ignored for other types.
    Site string
    The name of the UniFi site where this resource should be applied. If not specified, the default site will be used.
    Ttl int
    Time To Live (TTL) in seconds, determines how long DNS resolvers should cache this record. Set to 0 for automatic TTL. Common values: 300 (5 minutes), 3600 (1 hour), 86400 (1 day).
    Weight int
    A relative weight for SRV records with the same priority. Higher values get proportionally more traffic. Only used with SRV records.
    type String
    The type of DNS record. Valid values are:

    • A - Maps a hostname to IPv4 address
    • AAAA - Maps a hostname to IPv6 address
    • CNAME - Creates an alias for another domain name
    • MX - Specifies mail servers for the domain
    • NS - Delegates a subdomain to a set of name servers
    • PTR - Creates a pointer to a canonical name (reverse DNS)
    • SOA - Specifies authoritative information about the domain
    • SRV - Specifies location of services (hostname and port)
    • TXT - Holds descriptive text
    value String
    The content of the DNS record. The expected value depends on the record type:

    • For A records: IPv4 address (e.g., '192.168.1.10')
    • For AAAA records: IPv6 address
    • For CNAME records: Canonical name (e.g., 'server1.example.com')
    • For MX records: Mail server hostname
    • For TXT records: Text content (e.g., 'v=spf1 include:_spf.example.com ~all')
    enabled Boolean
    Whether the DNS record is active. Defaults to true. Set to false to temporarily disable resolution without removing the record.
    name String
    DNS record name.
    port Integer
    The port number for SRV records. Valid values are between 1 and 65535. Only used with SRV records.
    priority Integer
    Priority value for MX and SRV records. Lower values indicate higher priority. Required for MX and SRV records, ignored for other types.
    site String
    The name of the UniFi site where this resource should be applied. If not specified, the default site will be used.
    ttl Integer
    Time To Live (TTL) in seconds, determines how long DNS resolvers should cache this record. Set to 0 for automatic TTL. Common values: 300 (5 minutes), 3600 (1 hour), 86400 (1 day).
    weight Integer
    A relative weight for SRV records with the same priority. Higher values get proportionally more traffic. Only used with SRV records.
    type string
    The type of DNS record. Valid values are:

    • A - Maps a hostname to IPv4 address
    • AAAA - Maps a hostname to IPv6 address
    • CNAME - Creates an alias for another domain name
    • MX - Specifies mail servers for the domain
    • NS - Delegates a subdomain to a set of name servers
    • PTR - Creates a pointer to a canonical name (reverse DNS)
    • SOA - Specifies authoritative information about the domain
    • SRV - Specifies location of services (hostname and port)
    • TXT - Holds descriptive text
    value string
    The content of the DNS record. The expected value depends on the record type:

    • For A records: IPv4 address (e.g., '192.168.1.10')
    • For AAAA records: IPv6 address
    • For CNAME records: Canonical name (e.g., 'server1.example.com')
    • For MX records: Mail server hostname
    • For TXT records: Text content (e.g., 'v=spf1 include:_spf.example.com ~all')
    enabled boolean
    Whether the DNS record is active. Defaults to true. Set to false to temporarily disable resolution without removing the record.
    name string
    DNS record name.
    port number
    The port number for SRV records. Valid values are between 1 and 65535. Only used with SRV records.
    priority number
    Priority value for MX and SRV records. Lower values indicate higher priority. Required for MX and SRV records, ignored for other types.
    site string
    The name of the UniFi site where this resource should be applied. If not specified, the default site will be used.
    ttl number
    Time To Live (TTL) in seconds, determines how long DNS resolvers should cache this record. Set to 0 for automatic TTL. Common values: 300 (5 minutes), 3600 (1 hour), 86400 (1 day).
    weight number
    A relative weight for SRV records with the same priority. Higher values get proportionally more traffic. Only used with SRV records.
    type str
    The type of DNS record. Valid values are:

    • A - Maps a hostname to IPv4 address
    • AAAA - Maps a hostname to IPv6 address
    • CNAME - Creates an alias for another domain name
    • MX - Specifies mail servers for the domain
    • NS - Delegates a subdomain to a set of name servers
    • PTR - Creates a pointer to a canonical name (reverse DNS)
    • SOA - Specifies authoritative information about the domain
    • SRV - Specifies location of services (hostname and port)
    • TXT - Holds descriptive text
    value str
    The content of the DNS record. The expected value depends on the record type:

    • For A records: IPv4 address (e.g., '192.168.1.10')
    • For AAAA records: IPv6 address
    • For CNAME records: Canonical name (e.g., 'server1.example.com')
    • For MX records: Mail server hostname
    • For TXT records: Text content (e.g., 'v=spf1 include:_spf.example.com ~all')
    enabled bool
    Whether the DNS record is active. Defaults to true. Set to false to temporarily disable resolution without removing the record.
    name str
    DNS record name.
    port int
    The port number for SRV records. Valid values are between 1 and 65535. Only used with SRV records.
    priority int
    Priority value for MX and SRV records. Lower values indicate higher priority. Required for MX and SRV records, ignored for other types.
    site str
    The name of the UniFi site where this resource should be applied. If not specified, the default site will be used.
    ttl int
    Time To Live (TTL) in seconds, determines how long DNS resolvers should cache this record. Set to 0 for automatic TTL. Common values: 300 (5 minutes), 3600 (1 hour), 86400 (1 day).
    weight int
    A relative weight for SRV records with the same priority. Higher values get proportionally more traffic. Only used with SRV records.
    type String
    The type of DNS record. Valid values are:

    • A - Maps a hostname to IPv4 address
    • AAAA - Maps a hostname to IPv6 address
    • CNAME - Creates an alias for another domain name
    • MX - Specifies mail servers for the domain
    • NS - Delegates a subdomain to a set of name servers
    • PTR - Creates a pointer to a canonical name (reverse DNS)
    • SOA - Specifies authoritative information about the domain
    • SRV - Specifies location of services (hostname and port)
    • TXT - Holds descriptive text
    value String
    The content of the DNS record. The expected value depends on the record type:

    • For A records: IPv4 address (e.g., '192.168.1.10')
    • For AAAA records: IPv6 address
    • For CNAME records: Canonical name (e.g., 'server1.example.com')
    • For MX records: Mail server hostname
    • For TXT records: Text content (e.g., 'v=spf1 include:_spf.example.com ~all')
    enabled Boolean
    Whether the DNS record is active. Defaults to true. Set to false to temporarily disable resolution without removing the record.
    name String
    DNS record name.
    port Number
    The port number for SRV records. Valid values are between 1 and 65535. Only used with SRV records.
    priority Number
    Priority value for MX and SRV records. Lower values indicate higher priority. Required for MX and SRV records, ignored for other types.
    site String
    The name of the UniFi site where this resource should be applied. If not specified, the default site will be used.
    ttl Number
    Time To Live (TTL) in seconds, determines how long DNS resolvers should cache this record. Set to 0 for automatic TTL. Common values: 300 (5 minutes), 3600 (1 hour), 86400 (1 day).
    weight Number
    A relative weight for SRV records with the same priority. Higher values get proportionally more traffic. Only used with SRV records.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Record resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing Record Resource

    Get an existing Record resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: RecordState, opts?: CustomResourceOptions): Record
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            enabled: Optional[bool] = None,
            name: Optional[str] = None,
            port: Optional[int] = None,
            priority: Optional[int] = None,
            site: Optional[str] = None,
            ttl: Optional[int] = None,
            type: Optional[str] = None,
            value: Optional[str] = None,
            weight: Optional[int] = None) -> Record
    func GetRecord(ctx *Context, name string, id IDInput, state *RecordState, opts ...ResourceOption) (*Record, error)
    public static Record Get(string name, Input<string> id, RecordState? state, CustomResourceOptions? opts = null)
    public static Record get(String name, Output<String> id, RecordState state, CustomResourceOptions options)
    resources:  _:    type: unifi:dns:Record    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Enabled bool
    Whether the DNS record is active. Defaults to true. Set to false to temporarily disable resolution without removing the record.
    Name string
    DNS record name.
    Port int
    The port number for SRV records. Valid values are between 1 and 65535. Only used with SRV records.
    Priority int
    Priority value for MX and SRV records. Lower values indicate higher priority. Required for MX and SRV records, ignored for other types.
    Site string
    The name of the UniFi site where this resource should be applied. If not specified, the default site will be used.
    Ttl int
    Time To Live (TTL) in seconds, determines how long DNS resolvers should cache this record. Set to 0 for automatic TTL. Common values: 300 (5 minutes), 3600 (1 hour), 86400 (1 day).
    Type string
    The type of DNS record. Valid values are:

    • A - Maps a hostname to IPv4 address
    • AAAA - Maps a hostname to IPv6 address
    • CNAME - Creates an alias for another domain name
    • MX - Specifies mail servers for the domain
    • NS - Delegates a subdomain to a set of name servers
    • PTR - Creates a pointer to a canonical name (reverse DNS)
    • SOA - Specifies authoritative information about the domain
    • SRV - Specifies location of services (hostname and port)
    • TXT - Holds descriptive text
    Value string
    The content of the DNS record. The expected value depends on the record type:

    • For A records: IPv4 address (e.g., '192.168.1.10')
    • For AAAA records: IPv6 address
    • For CNAME records: Canonical name (e.g., 'server1.example.com')
    • For MX records: Mail server hostname
    • For TXT records: Text content (e.g., 'v=spf1 include:_spf.example.com ~all')
    Weight int
    A relative weight for SRV records with the same priority. Higher values get proportionally more traffic. Only used with SRV records.
    Enabled bool
    Whether the DNS record is active. Defaults to true. Set to false to temporarily disable resolution without removing the record.
    Name string
    DNS record name.
    Port int
    The port number for SRV records. Valid values are between 1 and 65535. Only used with SRV records.
    Priority int
    Priority value for MX and SRV records. Lower values indicate higher priority. Required for MX and SRV records, ignored for other types.
    Site string
    The name of the UniFi site where this resource should be applied. If not specified, the default site will be used.
    Ttl int
    Time To Live (TTL) in seconds, determines how long DNS resolvers should cache this record. Set to 0 for automatic TTL. Common values: 300 (5 minutes), 3600 (1 hour), 86400 (1 day).
    Type string
    The type of DNS record. Valid values are:

    • A - Maps a hostname to IPv4 address
    • AAAA - Maps a hostname to IPv6 address
    • CNAME - Creates an alias for another domain name
    • MX - Specifies mail servers for the domain
    • NS - Delegates a subdomain to a set of name servers
    • PTR - Creates a pointer to a canonical name (reverse DNS)
    • SOA - Specifies authoritative information about the domain
    • SRV - Specifies location of services (hostname and port)
    • TXT - Holds descriptive text
    Value string
    The content of the DNS record. The expected value depends on the record type:

    • For A records: IPv4 address (e.g., '192.168.1.10')
    • For AAAA records: IPv6 address
    • For CNAME records: Canonical name (e.g., 'server1.example.com')
    • For MX records: Mail server hostname
    • For TXT records: Text content (e.g., 'v=spf1 include:_spf.example.com ~all')
    Weight int
    A relative weight for SRV records with the same priority. Higher values get proportionally more traffic. Only used with SRV records.
    enabled Boolean
    Whether the DNS record is active. Defaults to true. Set to false to temporarily disable resolution without removing the record.
    name String
    DNS record name.
    port Integer
    The port number for SRV records. Valid values are between 1 and 65535. Only used with SRV records.
    priority Integer
    Priority value for MX and SRV records. Lower values indicate higher priority. Required for MX and SRV records, ignored for other types.
    site String
    The name of the UniFi site where this resource should be applied. If not specified, the default site will be used.
    ttl Integer
    Time To Live (TTL) in seconds, determines how long DNS resolvers should cache this record. Set to 0 for automatic TTL. Common values: 300 (5 minutes), 3600 (1 hour), 86400 (1 day).
    type String
    The type of DNS record. Valid values are:

    • A - Maps a hostname to IPv4 address
    • AAAA - Maps a hostname to IPv6 address
    • CNAME - Creates an alias for another domain name
    • MX - Specifies mail servers for the domain
    • NS - Delegates a subdomain to a set of name servers
    • PTR - Creates a pointer to a canonical name (reverse DNS)
    • SOA - Specifies authoritative information about the domain
    • SRV - Specifies location of services (hostname and port)
    • TXT - Holds descriptive text
    value String
    The content of the DNS record. The expected value depends on the record type:

    • For A records: IPv4 address (e.g., '192.168.1.10')
    • For AAAA records: IPv6 address
    • For CNAME records: Canonical name (e.g., 'server1.example.com')
    • For MX records: Mail server hostname
    • For TXT records: Text content (e.g., 'v=spf1 include:_spf.example.com ~all')
    weight Integer
    A relative weight for SRV records with the same priority. Higher values get proportionally more traffic. Only used with SRV records.
    enabled boolean
    Whether the DNS record is active. Defaults to true. Set to false to temporarily disable resolution without removing the record.
    name string
    DNS record name.
    port number
    The port number for SRV records. Valid values are between 1 and 65535. Only used with SRV records.
    priority number
    Priority value for MX and SRV records. Lower values indicate higher priority. Required for MX and SRV records, ignored for other types.
    site string
    The name of the UniFi site where this resource should be applied. If not specified, the default site will be used.
    ttl number
    Time To Live (TTL) in seconds, determines how long DNS resolvers should cache this record. Set to 0 for automatic TTL. Common values: 300 (5 minutes), 3600 (1 hour), 86400 (1 day).
    type string
    The type of DNS record. Valid values are:

    • A - Maps a hostname to IPv4 address
    • AAAA - Maps a hostname to IPv6 address
    • CNAME - Creates an alias for another domain name
    • MX - Specifies mail servers for the domain
    • NS - Delegates a subdomain to a set of name servers
    • PTR - Creates a pointer to a canonical name (reverse DNS)
    • SOA - Specifies authoritative information about the domain
    • SRV - Specifies location of services (hostname and port)
    • TXT - Holds descriptive text
    value string
    The content of the DNS record. The expected value depends on the record type:

    • For A records: IPv4 address (e.g., '192.168.1.10')
    • For AAAA records: IPv6 address
    • For CNAME records: Canonical name (e.g., 'server1.example.com')
    • For MX records: Mail server hostname
    • For TXT records: Text content (e.g., 'v=spf1 include:_spf.example.com ~all')
    weight number
    A relative weight for SRV records with the same priority. Higher values get proportionally more traffic. Only used with SRV records.
    enabled bool
    Whether the DNS record is active. Defaults to true. Set to false to temporarily disable resolution without removing the record.
    name str
    DNS record name.
    port int
    The port number for SRV records. Valid values are between 1 and 65535. Only used with SRV records.
    priority int
    Priority value for MX and SRV records. Lower values indicate higher priority. Required for MX and SRV records, ignored for other types.
    site str
    The name of the UniFi site where this resource should be applied. If not specified, the default site will be used.
    ttl int
    Time To Live (TTL) in seconds, determines how long DNS resolvers should cache this record. Set to 0 for automatic TTL. Common values: 300 (5 minutes), 3600 (1 hour), 86400 (1 day).
    type str
    The type of DNS record. Valid values are:

    • A - Maps a hostname to IPv4 address
    • AAAA - Maps a hostname to IPv6 address
    • CNAME - Creates an alias for another domain name
    • MX - Specifies mail servers for the domain
    • NS - Delegates a subdomain to a set of name servers
    • PTR - Creates a pointer to a canonical name (reverse DNS)
    • SOA - Specifies authoritative information about the domain
    • SRV - Specifies location of services (hostname and port)
    • TXT - Holds descriptive text
    value str
    The content of the DNS record. The expected value depends on the record type:

    • For A records: IPv4 address (e.g., '192.168.1.10')
    • For AAAA records: IPv6 address
    • For CNAME records: Canonical name (e.g., 'server1.example.com')
    • For MX records: Mail server hostname
    • For TXT records: Text content (e.g., 'v=spf1 include:_spf.example.com ~all')
    weight int
    A relative weight for SRV records with the same priority. Higher values get proportionally more traffic. Only used with SRV records.
    enabled Boolean
    Whether the DNS record is active. Defaults to true. Set to false to temporarily disable resolution without removing the record.
    name String
    DNS record name.
    port Number
    The port number for SRV records. Valid values are between 1 and 65535. Only used with SRV records.
    priority Number
    Priority value for MX and SRV records. Lower values indicate higher priority. Required for MX and SRV records, ignored for other types.
    site String
    The name of the UniFi site where this resource should be applied. If not specified, the default site will be used.
    ttl Number
    Time To Live (TTL) in seconds, determines how long DNS resolvers should cache this record. Set to 0 for automatic TTL. Common values: 300 (5 minutes), 3600 (1 hour), 86400 (1 day).
    type String
    The type of DNS record. Valid values are:

    • A - Maps a hostname to IPv4 address
    • AAAA - Maps a hostname to IPv6 address
    • CNAME - Creates an alias for another domain name
    • MX - Specifies mail servers for the domain
    • NS - Delegates a subdomain to a set of name servers
    • PTR - Creates a pointer to a canonical name (reverse DNS)
    • SOA - Specifies authoritative information about the domain
    • SRV - Specifies location of services (hostname and port)
    • TXT - Holds descriptive text
    value String
    The content of the DNS record. The expected value depends on the record type:

    • For A records: IPv4 address (e.g., '192.168.1.10')
    • For AAAA records: IPv6 address
    • For CNAME records: Canonical name (e.g., 'server1.example.com')
    • For MX records: Mail server hostname
    • For TXT records: Text content (e.g., 'v=spf1 include:_spf.example.com ~all')
    weight Number
    A relative weight for SRV records with the same priority. Higher values get proportionally more traffic. Only used with SRV records.

    Package Details

    Repository
    unifi pulumiverse/pulumi-unifi
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the unifi Terraform Provider.
    unifi logo
    Viewing docs for Unifi v0.2.0
    published on Tuesday, Feb 17, 2026 by Pulumiverse
      Try Pulumi Cloud free. Your team will thank you.