Skip to content

List examples

Add HEX timestamp to a request header

Add a custom header to requests sent to the origin server with the current timestamp in hexadecimal format for debugging, tracking, or custom routing purposes.

Custom cache

Store, retrieve, and remove assets from cache programmatically. Use this template to optimize performance and implement custom caching strategies.

Debugging logs

Send debugging information in an errored response to a logging service.

Maintenance page

Serve a custom maintenance page instead of fetching content from the origin server or cache. Ideal for downtime notifications, planned maintenance, or emergency messages.

Set security headers

Set common security headers such as X-XSS-Protection, X-Frame-Options, and X-Content-Type-Options.

Sign requests

Verify a signed request using the HMAC and SHA-256 algorithms or return a 403.

import { ListExamples } from "~/components";
<ListExamples directory="rules/snippets/examples" />

There are also two optional, additional properties:

  • filters string[]: A list of filters to render that helps someone filter the examples based on values in the frontmatter.
  • additionalProducts string[]: A list of additional product examples to look across our docs for. Looks for anything matching the products frontmatter in examples across other areas of the docs.