source_ip in the report is the address of the client that connected to PlanetScale. This is especially useful for connections routed through a pooler, where Postgres server logs may show a PlanetScale infrastructure address instead of the original client address.
Generating a report is limited to Organization Administrators. Service tokens cannot generate reports.
Generate a report
Use thepscale CLI to generate and download a report. Specify a time window and, optionally, filters:
What’s in the archive
Every archive contains exactly two files:The data
Denials carry one of these reasons:
The manifest
manifest.json records how the report was generated:
[start_at,end_at) semantics: start_at is inclusive and end_at is exclusive.
Example queries
Filter by source IP
Pass a single address or a whole CIDR range:Filter by credential
Use--username to find attempts made with a particular credential. For example, to return only denied attempts:
Export a time window for analysis
Omit filters to export all authentication attempts in a time window. For larger datasets, Parquet can be useful for analysis with tools such as DuckDB:Combining filters
Filters combine with AND across different flags, and OR within a repeated flag. This request means “denied attempts, from either of these two ranges, using either of these two credentials”:Choosing a format
CSV is the default. JSONL is selected by
--format json, and Parquet must be requested with --export-format parquet.

