Skip to content
Start here

Primary Zone Configuration Details

client.DNS.ZoneTransfers.Outgoing.Get(ctx, query) (*ZoneTransferOutgoingGetResponse, error)
GET/zones/{zone_id}/secondary_dns/outgoing

Get primary zone configuration for outgoing zone transfers.

Security
API Token

The preferred authorization scheme for interacting with the Cloudflare API. Create a token.

Example:Authorization: Bearer Sn3lZJTBX6kkg7OdcBUAxOO963GEIyGQqnFTOFYY
API Email + API Key

The previous authorization scheme for interacting with the Cloudflare API, used in conjunction with a Global API key.

Example:X-Auth-Email: user@example.com

The previous authorization scheme for interacting with the Cloudflare API. When possible, use API tokens instead of Global API keys.

Example:X-Auth-Key: 144c9defac04969c7bfad8efaa8ea194
Accepted Permissions (at least one required)
Zone Settings WriteZone Settings ReadDNS ReadZone WriteDNS Write
ParametersExpand Collapse
query ZoneTransferOutgoingGetParams
ZoneID param.Field[string]
ReturnsExpand Collapse
type ZoneTransferOutgoingGetResponse struct{…}
ID stringOptional
CheckedTime stringOptional

The time for a specific event.

CreatedTime stringOptional

The time for a specific event.

LastTransferredTime stringOptional

The time for a specific event.

Name stringOptional

Zone name.

Peers []stringOptional

A list of peer tags.

SOASerial float64Optional

The serial number of the SOA for the given zone.

Primary Zone Configuration Details

package main

import (
  "context"
  "fmt"

  "github.com/stainless-sdks/cloudflare-go"
  "github.com/stainless-sdks/cloudflare-go/dns"
  "github.com/stainless-sdks/cloudflare-go/option"
)

func main() {
  client := cloudflare.NewClient(
    option.WithAPIToken("Sn3lZJTBX6kkg7OdcBUAxOO963GEIyGQqnFTOFYY"),
  )
  outgoing, err := client.DNS.ZoneTransfers.Outgoing.Get(context.TODO(), dns.ZoneTransferOutgoingGetParams{
    ZoneID: cloudflare.F("269d8f4853475ca241c4e730be286b20"),
  })
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", outgoing.ID)
}
{
  "errors": [
    {
      "code": 1000,
      "message": "message",
      "documentation_url": "documentation_url",
      "source": {
        "pointer": "pointer"
      }
    }
  ],
  "messages": [
    {
      "code": 1000,
      "message": "message",
      "documentation_url": "documentation_url",
      "source": {
        "pointer": "pointer"
      }
    }
  ],
  "success": true,
  "result": {
    "id": "269d8f4853475ca241c4e730be286b20",
    "checked_time": "2019-10-24T17:09:42.883908+01:00",
    "created_time": "2019-10-24T17:09:42.883908+01:00",
    "last_transferred_time": "2019-10-24T17:09:42.883908+01:00",
    "name": "www.example.com.",
    "peers": [
      "23ff594956f20c2a721606e94745a8aa",
      "00920f38ce07c2e2f4df50b1f61d4194"
    ],
    "soa_serial": 2019102400
  }
}
Returns Examples
{
  "errors": [
    {
      "code": 1000,
      "message": "message",
      "documentation_url": "documentation_url",
      "source": {
        "pointer": "pointer"
      }
    }
  ],
  "messages": [
    {
      "code": 1000,
      "message": "message",
      "documentation_url": "documentation_url",
      "source": {
        "pointer": "pointer"
      }
    }
  ],
  "success": true,
  "result": {
    "id": "269d8f4853475ca241c4e730be286b20",
    "checked_time": "2019-10-24T17:09:42.883908+01:00",
    "created_time": "2019-10-24T17:09:42.883908+01:00",
    "last_transferred_time": "2019-10-24T17:09:42.883908+01:00",
    "name": "www.example.com.",
    "peers": [
      "23ff594956f20c2a721606e94745a8aa",
      "00920f38ce07c2e2f4df50b1f61d4194"
    ],
    "soa_serial": 2019102400
  }
}