Skip to content

Commit b04c669

Browse files
Add placeholder component syntax
1 parent 9657b01 commit b04c669

File tree

4 files changed

+66
-0
lines changed

4 files changed

+66
-0
lines changed

src/content/docs/cloudflare-for-platforms/cloudflare-for-saas/domain-support/custom-metadata.mdx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,12 @@ curl --request PATCH \
5151
}'
5252
```
5353

54+
<APIRequest
55+
path=""
56+
method=""
57+
json={{}}
58+
/>
59+
5460
Changes to metadata will propagate across Cloudflare’s edge within 30 seconds.
5561

5662
---

src/content/docs/cloudflare-for-platforms/cloudflare-for-saas/performance/early-hints-for-saas.mdx

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,12 @@ curl "https://api.cloudflare.com/client/v4/zones/{zone_id}/custom_hostnames" \
4848
}'
4949
```
5050

51+
<APIRequest
52+
path=""
53+
method=""
54+
json={{}}
55+
/>
56+
5157
4. For an existing custom hostname, locate the `id` of that hostname via a `GET` call:
5258

5359
```bash
@@ -56,6 +62,12 @@ curl "https://api.cloudflare.com/client/v4/zones/{zone_id}/custom_hostnames?host
5662
--header "X-Auth-Key: <API_KEY>"
5763
```
5864

65+
<APIRequest
66+
path=""
67+
method=""
68+
json={{}}
69+
/>
70+
5971
5. Then make an API call such as the example below, specifying `"early_hints": "on"`:
6072

6173
```bash
@@ -78,4 +90,10 @@ curl --request PATCH \
7890
}'
7991
```
8092

93+
<APIRequest
94+
path=""
95+
method=""
96+
json={{}}
97+
/>
98+
8199
Currently, all options within `settings` are required in order to prevent those options from being set to default. You can pull the current settings state prior to updating Early Hints by leveraging the output that returns the `id` for the hostname.

src/content/docs/cloudflare-for-platforms/cloudflare-for-saas/security/certificate-management/custom-certificates/certificate-signing-requests.mdx

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,12 @@ curl https://api.cloudflare.com/client/v4/zones/{zone_id}/custom_csrs \
8282
}
8383
```
8484

85+
<APIRequest
86+
path=""
87+
method=""
88+
json={{}}
89+
/>
90+
8591
Replace the `\n` characters with actual newlines before passing to your customer. This can be accomplished by piping the output of the prior call to a tool like jq and perl, such as:
8692

8793
```bash
@@ -92,6 +98,12 @@ curl https://api.cloudflare.com/client/v4/zones/{zone_id}/custom_csrs \
9298
--data "$request_body" | jq .result.csr | perl -npe s'/\\n/\n/g; s/"//g' > csr.txt
9399
```
94100

101+
<APIRequest
102+
path=""
103+
method=""
104+
json={{}}
105+
/>
106+
95107
### 3. Customer obtains certificate
96108

97109
Your customer will take the provided CSR and work with their CA to obtain a signed, publicly trusted certificate.
@@ -133,4 +145,10 @@ You can request the (paginated) collection of all previously generated custom CS
133145

134146
Delete one or more of the CSRs to delete the underlying private key by making a `DELETE` request to `https://api.cloudflare.com/client/v4/zones/{zone_id}/custom_csrs/{csr_id}`.
135147

148+
<APIRequest
149+
path=""
150+
method=""
151+
json={{}}
152+
/>
153+
136154
You may delete a CSR provided there are no custom certificates using the private key that was generated for the CSR. If you attempt to delete a CSR whose private key is still in use, you will receive an error.

src/content/docs/cloudflare-for-platforms/cloudflare-for-saas/security/waf-for-saas/index.mdx

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,12 @@ curl "https://api.cloudflare.com/client/v4/zones/{zone_id}/custom_hostnames" \
2828
--data '{"Hostname":"example.com"}, "Ssl":{wildcard:false}}'
2929
```
3030

31+
<APIRequest
32+
path=""
33+
method=""
34+
json={{}}
35+
/>
36+
3137
## 1. Associate custom metadata to a custom hostname
3238

3339
To apply WAF to your custom hostname, you need to create an association between your customer's domain and the WAF configuration that you would like to attach to it. Cloudflare's product, [custom metadata](/cloudflare-for-platforms/cloudflare-for-saas/domain-support/custom-metadata/) allows you to do this via the API.
@@ -44,6 +50,12 @@ curl "https://api.cloudflare.com/client/v4/zones/{zone_id}/custom_hostnames" \
4450
--header "X-Auth-Key: <API_KEY>"
4551
```
4652

53+
<APIRequest
54+
path=""
55+
method=""
56+
json={{}}
57+
/>
58+
4759
4. Plan your [custom metadata](/cloudflare-for-platforms/cloudflare-for-saas/domain-support/custom-metadata/). It is fully customizable. In the example below, we have chosen the tag `"security_level"` to which we expect to assign three values (low, medium, and high).
4860

4961
:::note
@@ -68,6 +80,12 @@ curl --request PATCH \
6880
}'
6981
```
7082

83+
<APIRequest
84+
path=""
85+
method=""
86+
json={{}}
87+
/>
88+
7189
This assigns custom metadata to your custom hostname so that it has a security tag associated with its ID.
7290

7391
## 2. Trigger security products based on tags
@@ -100,6 +118,12 @@ curl --request PUT \
100118
}'
101119
```
102120

121+
<APIRequest
122+
path=""
123+
method=""
124+
json={{}}
125+
/>
126+
103127
To build rules through the dashboard:
104128

105129
1. Log in to the [Cloudflare dashboard](https://dash.cloudflare.com) and navigate to your account and website.

0 commit comments

Comments
 (0)