Deploy hook: keep tracked pages fresh

On this page

The deploy hook lets your deploy pipeline tell Quillly that your site just changed. Quillly then reads your sitemap and re-checks your Site pages at once, instead of at its daily run. At the end, every deploy triggers that re-check on its own.

Before you start, you need:

  • A Site pages section that tracks your sitemap. Site pages shows how to set one up.

  • Access to your deploy pipeline, such as GitHub Actions, and a place in it to store secrets.

Set up the deploy hook#

  1. Copy the deploy hook URL#

    Open Site pages and click Deploy hook. The dialog shows the Deploy hook URL, a curl command and a GitHub Actions step. The token is masked on screen, but clicking the URL or the curl block copies it in full.

    The Deploy hook dialog in Quillly for acme.com, with the deploy hook URL, the curl command and the GitHub Actions step, and the URL block highlighted
  2. Store the token as a secret#

    The token is the part of the URL after token=. Save it in your pipeline's secrets, for example as a GitHub Actions secret named QUILLLY_DEPLOY_TOKEN, rather than in your repository.

  3. Call the hook after your deploy#

    Add the step from the dialog at the end of your deploy job. It looks like this, with your own website ID:

    yaml
    - name: Notify Quillly of deploy
      run: |
        curl -X POST "https://quillly.com/api/ping/pages/<websiteId>?token=${{ secrets.QUILLLY_DEPLOY_TOKEN }}&delay=120"

    Any other pipeline works the same way, as long as it can send a POST. You can pass the token in a header instead of the URL:

    bash
    curl -X POST "https://quillly.com/api/ping/pages/<websiteId>?delay=120" \
      -H "Authorization: Bearer $QUILLLY_DEPLOY_TOKEN"
  4. Check that it ran#

    The call answers 202 at once, and the run happens in the background. In Site pages, new pages appear and changed pages show Submitted again.

    Open Site pages

What a run does#

Each run works like the daily run:

  • It reads your sitemap and adds new pages, which then get a quality score.

  • It sends new pages, and pages whose lastmod date changed, to IndexNow, up to 50 per run.

  • It compares the content of up to 25 pages, starting with those checked longest ago, and sends the changed ones to IndexNow.

  • It marks pages that left your sitemap as Left sitemap.

A run doesn't redo the quality check of a changed page. Click Quality check all in Site pages for that. It also sends nothing to Google, which reads your sitemap on its own schedule.

Flowchart of a Quillly deploy hook call: without a delay the run starts at once, at most every 120 seconds; with a delay it waits; if no pages are found, Quillly tries again 5 and 15 minutes later

Parameters#

Send them in the query string or in a JSON body. When both have one, the query string wins.

Table

Parameter

Values

What it does

token

Your deploy token.

Proves the call comes from you. Or send Authorization: Bearer <token>.

delay

0 to 1800 seconds. The default is 0.

Waits this long before the run, for deploys that take a while to go live. Higher values count as 1800.

recheck

On by default. false, 0, no or off turns it off.

When a run finds no pages in your sitemap, for example because the site is still deploying, Quillly tries again 5 minutes later. If it still finds none, it tries once more 15 minutes after the first run.

Set delay to the time between your pipeline finishing and the new pages being live, including any CDN cache purge. If your pages go live in seconds, leave it out.

Responses and limits#

Table 2

Status

When

202

The run is queued. The body gives runsAt, delaySeconds and recheck.

200

The website has no Site pages section with a sitemap, so queued is 0.

401

The token is wrong. The body says Provide the site deploy token or sign in as the owner.

403

The owner's plan has lapsed, so the website's service is paused.

404

No website has that ID.

429

An immediate run started less than 120 seconds ago.

A call without delay starts a run at once and blocks further immediate calls for 120 seconds. A call with delay has no such limit: it replaces any run still waiting for the website, so ten quick deploys lead to one run.

Warning

Anyone with the token can start a run for your website. A run only re-reads your public sitemap and pages, but keep the token in a secret. The dashboard has no way to change it.

Common questions#

Do I need the deploy hook?#

No. Quillly re-reads your sitemap every day at 05:00 UTC. The hook makes the re-check happen right after a deploy instead.

Is there a button for this in the dashboard?#

Yes. Refresh in Site pages starts the same run without a token. Only the website's owner can use it, once every 2 minutes.

Why did my call get 429?#

Another immediate run started less than 2 minutes before. Wait, or add delay to your call.