Log Forwarding: Fastly log-forwarding-fastly

This page explains how to forward CDN logs from Fastly to Adobe’s S3 bucket for agentic traffic data collection. You will use the LLM Optimizer CDN configuration page to onboard to LLM Optimizer. After the onboarding process is complete, follow the steps provided on this page to configure log forwarding in the the Fastly web console.

Step 1: Onboard in LLM Optimizer step-1

On the LLM Optimizer page https://llmo.now/:

  1. Go to Configuration.

    Configuration button

  2. Click the CDN Configuration tab.

    CDN Configuration tab

  3. Click Get Started.

  4. Next to Activate AI Traffic Insights, click Configure.

    Configure

  5. Select Fastly (BYOCDN).

    Select Fastly

  6. Click Onboard.

Step 2: Create an S3 endpoint in Fastly step-2

To create an S3 endpoint, on the Fastly Control Panel:

  1. In the Fastly dashboard, go to CDN services (not Compute services).
  2. In the Amazon Web Services S3 area, click Create endpoint.
  3. Fill out the Create an Amazon S3 endpoint fields:
Field
Description
Name
Human-readable name for the endpoint.
Placement
Default
Log format
Use the log format string shown in the Log format string section below.
Timestamp format
%Y-%m-%dT%H:%M:%S.000
Bucket name
Copy the Bucket Name from the LLM Optimizer configuration page. Bucket name
Domain
Copy the Domain Name from the LLM Optimizer configuration page. Domain name
Access method
User Credentials
User Credentials
Copy the Access Key and the Secret Key from the LLM Optimizer configuration page. Access keys
Period
300

Log format string:

{ "timestamp": "%{strftime(\{"%Y-%m-%dT%H:%M:%S%z"\}, time.start)}V", "host": "%{if(req.http.Fastly-Orig-Host, req.http.Fastly-Orig-Host, req.http.Host)}V", "url": "%{json.escape(req.url)}V", "request_method": "%{json.escape(req.method)}V", "request_referer": "%{json.escape(req.http.referer)}V", "request_user_agent": "%{json.escape(req.http.User-Agent)}V", "response_status": %{resp.status}V, "response_content_type": "%{json.escape(resp.http.Content-Type)}V", "client_country_code": "%{client.geo.country_name}V", "time_to_first_byte": "%{time.to_first_byte}V" }
WARNING
Password managers may auto-fill the Secret Key field with your Fastly password. If the AWS integration fails, enter the Secret Key manually.

After you complete the steps above, click Advanced options and set:

Field
Description
Path
Copy Path from the LLM Optimizer configuration page. Path
Select a log line format
Blank
Compression
Gzip
Redundancy level
Standard
ACL
None
Server side encryption
None
Maximum bytes
0

After setting the advanced options:

  1. Click Create to create the endpoint.
  2. From the Activate menu, select Activate on Production to deploy.
NOTE
Fastly streams logs continuously to S3, the S3 website and API only makes files available after the upload is complete.

Example log entry example

Presented below is an example format string for sending data to Amazon S3:

{
  "timestamp": "2026-02-10T05:05:36+0000",
  "host": "example.com",
  "url": "/my/path",
  "request_method": "GET",
  "request_referer": "https://example.com/my/other/path",
  "request_user_agent": "Mozilla/5.0 (iPhone; CPU iPhone OS 13_2_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/13.0.3 Mobile/15E148 Safari/604.1",
  "response_status": 200,
  "response_content_type": "text/css; charset=utf-8",
  "client_country_code": "argentina",
  "time_to_first_byte": "0.138"
}
recommendation-more-help
e65680c9-2bec-439b-acb0-8209e7c74d0d