Only requests that reach the forwarding stage are logged. Requests rejected earlier (malformed proxy auth, an invalid
CONNECT target, TLS failures) never reach it and aren’t logged. A request whose identity can’t be resolved at forwarding is still logged as an error, just with an empty agent.What’s in a record
Each request is logged with these fields (plus the standardtime, level, and message):
Written out, two records look like this:
Log levels
Each decision is logged at a level, so--log-level controls how much you see: the default info hides passthrough and canceled requests, debug shows everything, warn shows only blocked and errors.
canceled means the agent hung up before the request finished, which happens when you interrupt a prompt or the agent exits mid-request. Nothing failed and there was nobody left to answer, so these stay at debug and off your terminal. A request that really failed, an unreachable upstream or permissions that could not be resolved, is still an error.
Where the records go
Local proxy
Nothing is written unless you pass--log-file, since the agent owns the terminal and a file you did not ask for is one you cannot find. With it, records go to that path and you can tail -f them:
logrotate (copytruncate) if you keep one around. Without the flag, warnings and errors still print to your terminal; only the per-request trail is dropped.
Standalone proxy
Records go to stderr, so whatever supervises the proxy collects them.--log-format sets their shape, and --log-file additionally writes json to a file, which lets you watch a readable stream while persisting machine-readable records for a collector:
json, the same record looks like this:
--log-file, use logrotate with copytruncate.
Next steps
agent-proxy CLI reference
Every flag for
start and connect, including the logging options.Audit Logs
Configuration changes to your proxied services are recorded in Infisical’s own audit trail.