@digitalocean/dots - v1.0.1
    Preparing search index...

    Interface RecordsRequestBuilder

    Builds and executes requests for operations under /v2/domains/{domain_name}/records

    interface RecordsRequestBuilder {
        byDomain_record_id(
            domain_record_id: number,
        ): WithDomain_record_ItemRequestBuilder;
        get(
            requestConfiguration?: RequestConfiguration<
                RecordsRequestBuilderGetQueryParameters,
            >,
        ): Promise<undefined | RecordsGetResponse>;
        post(
            body:
                | Domain_record_aaaa
                | Domain_record_a
                | Domain_record_caa
                | Domain_record_cname
                | Domain_record_mx
                | Domain_record_ns
                | Domain_record_soa
                | Domain_record_srv
                | Domain_record_txt,
            requestConfiguration?: RequestConfiguration<object>,
        ): Promise<undefined | RecordsPostResponse>;
        toGetRequestInformation(
            requestConfiguration?: RequestConfiguration<
                RecordsRequestBuilderGetQueryParameters,
            >,
        ): RequestInformation;
        toPostRequestInformation(
            body:
                | Domain_record_aaaa
                | Domain_record_a
                | Domain_record_caa
                | Domain_record_cname
                | Domain_record_mx
                | Domain_record_ns
                | Domain_record_soa
                | Domain_record_srv
                | Domain_record_txt,
            requestConfiguration?: RequestConfiguration<object>,
        ): RequestInformation;
        withUrl(rawUrl: string): RecordsRequestBuilder;
    }

    Hierarchy

    Index

    Methods

    • To get a listing of all records configured for a domain, send a GET request to /v2/domains/$DOMAIN_NAME/records.The list of records returned can be filtered by using the name and type query parameters. For example, to only include A records for a domain, send a GET request to /v2/domains/$DOMAIN_NAME/records?type=A. name must be a fully qualified record name. For example, to only include records matching sub.example.com, send a GET request to /v2/domains/$DOMAIN_NAME/records?name=sub.example.com. Both name and type may be used together.

      Parameters

      Returns Promise<undefined | RecordsGetResponse>

      error when the service returns a 401 status code

      error when the service returns a 404 status code

      error when the service returns a 429 status code

      error when the service returns a 500 status code

      error when the service returns a 4XX or 5XX status code

    post

    • post(
          body:
              | Domain_record_aaaa
              | Domain_record_a
              | Domain_record_caa
              | Domain_record_cname
              | Domain_record_mx
              | Domain_record_ns
              | Domain_record_soa
              | Domain_record_srv
              | Domain_record_txt,
          requestConfiguration?: RequestConfiguration<object>,
      ): Promise<undefined | RecordsPostResponse>

      To create a new record to a domain, send a POST request to/v2/domains/$DOMAIN_NAME/records.The request must include all of the required fields for the domain record typebeing added.See the attribute table for details regarding recordtypes and their respective required attributes.

      Parameters

      • body:
            | Domain_record_aaaa
            | Domain_record_a
            | Domain_record_caa
            | Domain_record_cname
            | Domain_record_mx
            | Domain_record_ns
            | Domain_record_soa
            | Domain_record_srv
            | Domain_record_txt

        The request body

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns Promise<undefined | RecordsPostResponse>

      error when the service returns a 401 status code

      error when the service returns a 404 status code

      error when the service returns a 429 status code

      error when the service returns a 500 status code

      error when the service returns a 4XX or 5XX status code

    • To get a listing of all records configured for a domain, send a GET request to /v2/domains/$DOMAIN_NAME/records.The list of records returned can be filtered by using the name and type query parameters. For example, to only include A records for a domain, send a GET request to /v2/domains/$DOMAIN_NAME/records?type=A. name must be a fully qualified record name. For example, to only include records matching sub.example.com, send a GET request to /v2/domains/$DOMAIN_NAME/records?name=sub.example.com. Both name and type may be used together.

      Parameters

      Returns RequestInformation

    • To create a new record to a domain, send a POST request to/v2/domains/$DOMAIN_NAME/records.The request must include all of the required fields for the domain record typebeing added.See the attribute table for details regarding recordtypes and their respective required attributes.

      Parameters

      • body:
            | Domain_record_aaaa
            | Domain_record_a
            | Domain_record_caa
            | Domain_record_cname
            | Domain_record_mx
            | Domain_record_ns
            | Domain_record_soa
            | Domain_record_srv
            | Domain_record_txt

        The request body

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns RequestInformation

    • Parameters

      • rawUrl: string

      Returns RecordsRequestBuilder