Skip to content

Commit 6aa1eb9

Browse files
authored
[APO]Update verify-apo-works.mdx (#21757)
Option to confirm APO is up and running via a terminal.
1 parent 9e1a6e3 commit 6aa1eb9

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

src/content/docs/automatic-platform-optimization/get-started/verify-apo-works.mdx

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,23 @@ You can check whether or not APO is working by verifying APO headers are present
2020
* `cf-edge-cache` | `cache, platform=wordpress`
2121
* The `cf-edge-cache` headers confirms the WordPress plugin is installed and enabled.
2222

23+
In a terminal, use the following cURL. The header `'accept: text/html'` is important
24+
25+
```sh
26+
curl -svo /dev/null -A "CF" 'https://example.com/' -H 'accept: text/html' 2>&1 | grep 'cf-cache-status\|cf-edge\|cf-apo-via'
27+
```
28+
29+
```sh output
30+
< cf-cache-status: HIT
31+
< cf-apo-via: cache
32+
< cf-edge-cache: cache,platform=wordpress
33+
```
34+
35+
As always, `cf-cache-status` displays if the asset hit the cache or was considered dynamic and served from the origin.
36+
37+
- The `cf-apo-via` header returns the APO status for the given request.
38+
- The `cf-edge-cache` header means the WordPress plugin is installed and enabled.
39+
2340
## Verify the APO integration and WordPress integration work
2441

2542
Open your WordPress site and publish a change. When the integration is working, the page is cached with `cf-cache-status: HIT` and `cf-apo-via: tcache`

0 commit comments

Comments
 (0)