docs(endpoints): Add documentation for HogQL variable validation#14986
Merged
sarahxsanders merged 4 commits intomasterfrom Feb 13, 2026
Merged
docs(endpoints): Add documentation for HogQL variable validation#14986sarahxsanders merged 4 commits intomasterfrom
sarahxsanders merged 4 commits intomasterfrom
Conversation
… #47622 Add troubleshooting guidance for three new validation errors introduced in PR #47622: - "Query references undefined variable(s)" - when placeholders don't have matching definitions - "Variable ID(s) not valid UUIDs" - when variable IDs aren't valid UUID format - "Variable ID(s) not found" - when variable IDs don't exist in the project
Add documentation about the new validation that occurs when creating or updating endpoints with HogQL variables. This includes: - Explanation that variable placeholders must have matching definitions - Link to data management variables page - List of possible validation error messages and how to fix them - Link to troubleshooting for more details
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
sarahxsanders
approved these changes
Feb 12, 2026
| - Create the variable in [data management variables](https://app.posthog.com/data-management/variables) | ||
| - Verify you're using the correct project | ||
|
|
||
| > **Note:** `filters_override` is deprecated and will be removed in a future release. Use `variables` instead. See the [variables documentation](/docs/endpoints/variables) for migration guidance. |
Contributor
There was a problem hiding this comment.
this needs to be updated to use the right callout component, with proper spacing
Comment on lines
47
to
49
| - **"Query references undefined variable(s)"** - Your query uses a placeholder that doesn't have a matching variable definition. Define the variable with the correct `code_name`. | ||
| - **"Variable ID(s) not valid UUIDs"** - Variable IDs must be valid UUIDs. | ||
| - **"Variable ID(s) not found"** - The variable doesn't exist. Create it in data management first. |
Contributor
There was a problem hiding this comment.
please put error messages in code block: Query references undefined variable(s)
…roubleshooting - Add CalloutBox import - Change error messages from bold to code blocks for consistency - Replace blockquote with CalloutBox component for deprecation notice
Contributor
Author
|
Thanks for the feedback @sarahxsanders! I've made the requested changes:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
This PR updates the endpoints documentation to reflect the new HogQL variable validation behavior introduced in PostHog/posthog#47622.
Updated files
contents/docs/endpoints/variables.mdxcontents/docs/endpoints/troubleshooting.mdx{variables.X}placeholder doesn't have a matching variable definitionContext
PR #47622 adds server-side validation when creating/updating endpoints to ensure:
{variables.X}placeholder has a matching variable withcode_name: "X"The error messages in the code reference
/docs/endpoints/variables, making this documentation update important for users encountering these validation errors.Triggered by PostHog/posthog#47622