Quickstart

We're using the subdomain approach as it's likely we'll evolve aspects of HF into a Cloudflare app.

Given;

  • DOMAIN e.g. sygnal.com

    • Registered on CF, with DNS and proxy setup

  • ZONE-ID for that domain

Setup

DNS

Add a CNAME for hf to @

Set it to proxy on

Config

Add a KV store config of to CONFIG, with your ZONE-ID.

Key; DOMAIN:purge-cache

{
  "version": 1, 
  "zoneId": "ZONE-ID" 
}

Worker Route

*hf.DOMAIN/cache/purge -> cloudflare-clear-cache

Verify

https://hf.DOMAIN/cache/purge

A successful response is;

Cache Purge Initiated Successfully

Webflow Webhook

Get your site id

https://developers.webflow.com/reference/list-sites

e.g. 62296a1920ec667f814208e2

https://developers.webflow.com/reference/list-webhooks

Create Webhook

https://developers.webflow.com/reference/create-webhook

Paste in site_id

Select site_publish

Paste in your HF URL

e.g. https://hf.ponsonbydoctors.co.nz/cache/purge

Click Try It!

Check for a valid 201 response e.g.;

Last updated