exploring-endpoint-execution-logs
What it does
This skill reads the log entry written for each endpoint run and explains what happened, such as an error or an empty result. It is for people who need to know why an endpoint behaved a certain way.
When to use it
- βWhen an endpoint is failing and you want the error message from its runs.
- βWhen an endpoint returned no rows and you want to know why.
- βWhen you want to check the last few runs of an endpoint, including whether they used the cache.
Skill link
https://github.com/PostHog/posthog/blob/master/products/endpoints/skills/exploring-endpoint-execution-logs/SKILL.mdCopy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.
How to use
The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.
Ready-to-paste message
For Claude Code, Codex or Cursor: run it in your project folder and the skill gets installed.
Download the SKILL.md and drop it into your agentβs skills folder.
Example of what to ask your AI
βShow me the logs for my customer endpoint and tell me why the last three runs failed.β
5 new skills a week. 1 minute to read.
How it works
Every run writes one log entry with its result, duration and row count. The skill searches those entries for the specific endpoint and summarizes them.
Technical content (original SKILL.md)
Original text by the author, straight from GitHub.
Exploring endpoint execution logs
Every endpoint run emits one execution log entry to PostHog's log_entries store. This skill
reads those entries for a specific endpoint to answer "what happened when it ran?". It is the
log-level counterpart to diagnosing-endpoint-performance (which reasons about cache/materialisation
strategy from config and query_log).
When to use this skill
- "Why is my endpoint failing / erroring?"
- "Show me the logs / recent runs for endpoint X"
- "Did the last run hit cache? How many rows did it return?"
- "What happened the last time endpoint Y ran?"
If the question is "this endpoint is slow, what should I change?", use
diagnosing-endpoint-performance. If it's project-wide ("what can I clean up?"), use
auditing-endpoints.
What an execution log entry looks like
Each run produces exactly one entry. The level is INFO on success and ERROR on failure, and the
message carries the extra data as searchable key=value tokens:
Endpoint executed Β· path=materialized cache=hit duration_ms=142 rows=1024 version=3
Endpoint execution failed Β· path=inline error=ResolutionError version=3
Token meanings:
| Token | Values | Meaning |
|---|---|---|
path |
materialized / inline / ducklake / ducklake_fallback |
Which execution path ran |
cache |
hit / miss |
Whether the query result cache was used (omitted for ducklake) |
duration_ms |
integer | Wall-clock execution time |
rows |
integer | Number of result rows returned |
version |
integer | Which endpoint version ran |
error |
e.g. ResolutionError, HogVMException |
Error class / HogQL code name (failures only) |
Each run gets a distinct instance_id, so logs group one-per-execution in the viewer.
Available tools
| Tool | Purpose |
|---|---|
endpoint-logs |
Primary. Execution log entries for one endpoint by name. Filter by level, search, time range, instance_id; limit up to 500. |
endpoint-get |
Endpoint config for context (current version, materialisation, query kind) |
execute-sql |
Fallback / aggregation directly against log_entries (log_source='endpoints') |
Filtering
endpoint-logs exposes the standard log filters:
- level β comma-separated, e.g.
ERRORto see only failed runs, orINFO,ERRORfor all. - search β case-insensitive substring over the message. Because the extra data is in
key=valuetokens, you can searchcache=miss,path=inline,error=ResolutionError, or a specificversion=3. - after / before β ISO timestamps to bound the time range.
- instance_id β pin a single execution.
- limit β 1β500 (default 50).
Workflow
Identify the endpoint by name. If given a URL, parse it from
/api/projects/{team_id}/endpoints/{name}/run.Start broad:
endpoint-logsfor the endpoint with a recent time range. Skim levels and tokens.Narrow to the symptom:
- Failures β
level=ERROR; read theerror=token andpath=to see where it broke. - Cache concerns β
search=cache=missto see how often runs miss cache. - Wrong results β compare
rows=across runs, andversion=to spot a regression after a version bump.
- Failures β
For counts/trends across many runs (e.g. error rate over a week), drop to
execute-sqlagainstlog_entries:SELECT toDate(timestamp) AS day, upper(level) AS level, count() AS runs FROM log_entries WHERE log_source = 'endpoints' AND log_sou
FAQ
Does each run create a log?
Yes. Each endpoint run adds one log entry, marked as info on success and error on failure.
Can I see slow runs?
Yes. The duration is recorded in each log entry, so slow runs can be found and compared.
How is this different from the performance skill?
This skill reads what happened in each run, while the performance skill reasons about caching and configuration.
Details
Original description by the author
Explore and diagnose a PostHog endpoint's execution logs β error messages, failed runs, cache misses, slow runs, or unexpected row counts during endpoint invocations. Use when the user says "my endpoint is failing", "show me the logs for endpoint X", "what error did endpoint Y produce", "why did endpoint Z return no rows", "is this endpoint hitting cache", or "check the last N runs". Focused on a single named endpoint's runtime log entries, not project-wide auditing or query performance profiling.
repo: PostHog/posthog
Popularity
- GitHub stars
- 41k
- Ranking position
- #6862
- License
- β
- Updated
- 11/2/2026
Comments
- β¦
More skills from this repository
depot-ci
41kHelps your agent set up and run Depot CI workflows, a GitHub Actions alternative, including migrating existing workflows and reading run logs.
depot-container-builds
41kHelps your agent build Docker images on Depot's remote builders, including multi-platform images, pushing to registries, and fixing build failures.
depot-github-runners
41kHelps your agent move GitHub Actions jobs to Depot-managed runners, choosing runner sizes and labels, and troubleshooting runner setup issues.
editing-agents-md
41kHelps your agent decide whether a rule belongs in an AGENTS.md or CLAUDE.md file, and write it so it sticks without bloating the file.
Similar skills
openclaw-update
394kHelps your agent update an existing OpenClaw Gateway, choosing the update method that fits how it was installed and keeping your session working.
diagnose-gateway
394kHelps your agent find out why your OpenClaw Gateway is failing by checking settings, channels, and ports without changing anything.
crabbox-apps
394kHelps your agent open and run an app on a temporary cloud machine, then show its view in your chat side panel.