Skip to content

Commit ebe2ecf

Browse files
Use APIRequest compenent and other Style Guide adjustments
1 parent 6e4a01a commit ebe2ecf

File tree

1 file changed

+22
-22
lines changed

1 file changed

+22
-22
lines changed

src/content/docs/ssl/origin-configuration/authenticated-origin-pull/set-up/manage-certificates.mdx

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ head:
99

1010
---
1111

12+
import { APIRequest } from "~/components";
13+
1214
Refer to the following sections to learn how to manage certificates used with the different Authenticated Origin Pulls setups.
1315

1416
## Use specialized certificates
@@ -33,31 +35,29 @@ However, requests are dropped at your origin if your origin only accepts a valid
3335

3436
## Replace a client cert (without downtime)
3537

36-
For hostname:
38+
### Per-hostname
3739

3840
1. [Upload the new certificate](/api/resources/origin_tls_client_auth/subresources/hostnames/subresources/certificates/methods/create/).
3941

40-
2. [List your certificates(s)](/api/resources/origin_tls_client_auth/subresources/hostnames/subresources/certificates/methods/list/) and note the ID.
41-
42-
3. [Enable Authenticated Origin Pulls for that specific hostname](/api/resources/origin_tls_client_auth/subresources/hostnames/methods/update/) and enable the certificate you want to be used with the ID obtained in step 2:
43-
44-
```bash
45-
curl --request PUT \
46-
--url https://api.cloudflare.com/client/v4/zones/$ZONEID/origin_tls_client_auth/hostnames \
47-
--header 'authorization: Bearer $MYTOKEN' \
48-
--header 'content-type: application/json' \
49-
--data '{
50-
"config": [
51-
{
52-
"enabled": true,
53-
"hostname": "example.com",
54-
"cert_id": "$CERTID"
55-
}
56-
]
57-
}'
58-
```
59-
60-
For global:
42+
2. [List your certificates](/api/resources/origin_tls_client_auth/subresources/hostnames/subresources/certificates/methods/list/) and note the ID for the certificate you uploaded.
43+
44+
3. [Enable Authenticated Origin Pulls for the specific hostname](/api/resources/origin_tls_client_auth/subresources/hostnames/methods/update/) and enable the certificate you want to be used with the ID obtained in step 2:
45+
46+
<APIRequest
47+
path="/zones/{zone_id}/origin_tls_client_auth/hostnames"
48+
method="PUT"
49+
json={{
50+
"config": [
51+
{
52+
"enabled": true,
53+
"hostname": "<HOSTNAME>",
54+
"cert_id": "<CERT_ID>"
55+
}
56+
]
57+
}}
58+
/>
59+
60+
### Zone-level
6161

6262
1. [Upload the new certificate](/api/resources/origin_tls_client_auth/methods/create/).
6363

0 commit comments

Comments
 (0)