Skip to content

Commit 97ad85f

Browse files
Move ref zone API call into partial and replace
1 parent e58e68d commit 97ad85f

File tree

4 files changed

+21
-17
lines changed

4 files changed

+21
-17
lines changed

src/content/docs/dns/internal-dns/get-started.mdx

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -56,19 +56,7 @@ Although there are some steps that can be achieved on the dashboard, currently t
5656
1. Use the [Update DNS settings](/api/resources/dns/subresources/settings/methods/edit/) endpoint to add a reference from an internal zone to another internal zone. In `--data`, specify the `internal_dns` object with the parameter `reference_zone_id`.
5757

5858
<Example>
59-
In the following example, internal zone A (ID `8a904aeb565c42cfa207d98f6edea2f3`) is referencing internal zone B (ID `8e64c6fb4b514f3faf64de81efc11e51`).
60-
61-
```bash
62-
curl --request PATCH \
63-
https://api.cloudflare.com/client/v4/zones/8a904aeb565c42cfa207d98f6edea2f3/dns_settings \
64-
--header "Authorization: Bearer $CLOUDFLARE_API_TOKEN" \
65-
--header "Content-Type: application/json" \
66-
--data '{
67-
"internal_dns": {
68-
"reference_zone_id": "8e64c6fb4b514f3faf64de81efc11e51D"
69-
}
70-
}'
71-
```
59+
<Render file="internal-reference-zone-api"/>
7260
</ Example>
7361

7462
## 2. Link your internal zone to a view

src/content/docs/dns/internal-dns/internal-zones.mdx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,7 @@ During an [internal DNS query resolution](/dns/internal-dns/#architecture-overvi
3535
To configure a reference zone to be used in such cases, use the [Update DNS settings](/api/resources/dns/subresources/settings/methods/edit/) endpoint. In `--data`, specify the `internal_dns` object with the parameter `reference_zone_id`.
3636

3737
<Example>
38-
In the following example, internal zone A (ID `8a904aeb565c42cfa207d98f6edea2f3`) is referencing internal zone B (ID `8e64c6fb4b514f3faf64de81efc11e51`).
39-
40-
TBD > add full API call example using IDs mentioned above
38+
<Render file="internal-reference-zone-api"/>
4139
</ Example>
4240

4341
## Other actions

src/content/partials/dns/internal-dns-view-conditions.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
---
55

66
- DNS views can be empty, with no [internal zones](/dns/internal-dns/how-to/internal-zones/) linked to them.
7-
- A DNS view cannot contain public DNS zones[^1].
7+
- A DNS view cannot contain public DNS zones [^1].
88
- Each internal DNS zone name must be unique within a given DNS view.
99

1010
[^1]: DNS zones that contain public DNS records and are accessible by public resolvers.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
{}
3+
4+
---
5+
6+
In the following example, internal zone A (ID `8a904aeb565c42cfa207d98f6edea2f3`) is referencing internal zone B (ID `8e64c6fb4b514f3faf64de81efc11e51`).
7+
8+
```bash
9+
curl --request PATCH \
10+
https://api.cloudflare.com/client/v4/zones/8a904aeb565c42cfa207d98f6edea2f3/dns_settings \
11+
--header "Authorization: Bearer $CLOUDFLARE_API_TOKEN" \
12+
--header "Content-Type: application/json" \
13+
--data '{
14+
"internal_dns": {
15+
"reference_zone_id": "8e64c6fb4b514f3faf64de81efc11e51D"
16+
}
17+
}'
18+
```

0 commit comments

Comments
 (0)