vcl_deliver, after the response has already gone to the visitor. It makes no network calls, adds no origin fetches, and does not affect caching.
This gives you analytics only — no CAP enforcement. Requests are observed and labelled, never blocked or challenged. Acting on a license needs the SDK in a Compute service; see Connect on Fastly. A VCL service can also serve your RSL license without the SDK — see Serving the license on VCL.
What gets recorded
Per request: timestamp, a Fastly request id, client IP, user agent, path, method,Accept-Language, host, response status, country, network (ASN and operator), the Sec-Fetch-* headers, HTTP Message Signature headers when present, which standard headers were sent, whether a cookie was sent, and three measurements of the query string.
Deliberately not recorded — meaning never written to the log line Supertab receives. Your traffic is served exactly as before, so anything below still reaches your own origin as part of the normal request:
Before you begin
Authentication uses Fastly’s IAM-role access method: your Fastly account writes directly into a bucket provisioned for you, and Fastly proves which account it is writing for. There are no credentials — nothing is sent to you that could leak, nothing to store in Fastly, nothing to rotate. That works because the bucket is bound to your Fastly account, so setup starts with one value from you:- Send Supertab your Fastly customer ID — in the Fastly web interface under Account → Account info. If your organization has more than one Fastly account, it must be the account this service is listed under — an ID from a different account fails silently later (see troubleshooting).
- Supertab provisions your bucket and sends back the two values below.
Set it up
1
Clone the active version
Open the service, click Edit configuration, and clone the active version. Everything below happens on that draft and goes live only when you activate it.
2
Create the VCL snippet
Go to VCL Snippets → Create snippet:
3
Paste the snippet
Paste the code below into the snippet’s VCL field.
4
Create the logging endpoint
Go to Resources → Log streaming → Create endpoint → Amazon S3:
Under Advanced options, set Log line format to
Blank and leave compression off.Four of these are easy to get wrong, and none of them raise an error:- Log format replaces the prefilled JSON template entirely — delete it. The snippet already builds the JSON; this field only emits it.
- Log line format must be
Blank. TheClassicdefault prepends a syslog header and corrupts every line. - Compression must be off. Supertab reads the
*.logobjects as plain newline-delimited JSON. - Path must be exactly
bot-events/, trailing slash included — not a subfolder, not your company name.
Period 60 is the recommended steady-state value: one file per minute per cache node, and your dashboard stays about a minute behind real time. A longer period only delays your own data.5
Attach a condition to the endpoint
Still on the
bot_events endpoint, choose Attach a condition → Create a new response condition:This makes the endpoint log only when the snippet actually built an event. Without it, legs where the snippet correctly skips — most commonly the shield leg on a shielded service — log a literal
(null) line, and one such line makes the entire file unparseable on our side: every valid event in it is silently lost, with no error anywhere.6
Activate
Activate the version. The snippet, the condition, and the logging endpoint go live together.
Confirm it’s working
Send some traffic, then allow 15 minutes before checking. Logging configuration takes a few minutes to reach every POP, Fastly writes one file perPeriod, and it buffers per cache node — so events arrive as a trickle rather than all at once. Requests served before the log endpoint reaches a POP are lost rather than delayed.
Then open your dashboard. Crawlers that hit your site in that window appear there, classified by operator. If it’s still empty, work through the table below.
Troubleshooting
Misconfigurations here fail quietly rather than erroring, so work down the list in order.Every request is logged, including cache hits. With shielding enabled the line is built only at the edge POP — that’s what the snippet’s
visits_this_service guard is for — so requests are not counted twice, and the response condition keeps those shield legs from logging at all.Related Docs
Connect on Fastly
Serve your RSL license and enforce CAP on Fastly, with Compute or by chaining VCL to a validator.
Deploy at the Edge
CDN-agnostic guide covering RSL serving, CAP enforcement, and robots.txt.