fix(ai): allow public audience queries - #654
Conversation
|
@sanskritisingh245 is attempting to deploy a commit to the Databuddy OSS Team on Vercel. A member of the Team first needs to authorize it. |
|
The latest updates on your projects. Learn more about Vercel for GitHub. 2 Skipped Deployments
|
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Greptile SummaryThis PR fixes unauthenticated Audience queries for public websites by adding four existing query types to the public allowlist.
Confidence Score: 5/5The PR appears safe to merge, with no actionable correctness or security issues identified. Public access remains restricted to websites marked public, every query in a batch must be allowlisted, and the newly enabled builders retain mandatory website-level query scoping. Important Files Changed
Reviews (1): Last reviewed commit: "fix(ai): allow public audience queries" | Re-trigger Greptile |
Description
Fixes the public demo Audience tab failing with a 401 error.
The Audience tab requests
timezone,language,browser_versions, andscreen_resolutiontogether with other public query types. These query types were missing fromPUBLIC_QUERY_TYPES, causing the entire unauthenticated query batch to be rejected.This change adds those query types to the public allowlist and adds test coverage for the public Audience queries.
Slice
Checklist
mainand does not include another unmerged PR unless it is named above./demo/<website-id>/audienceflow in the browser.Summary by cubic
Allows unauthenticated Audience queries in the public demo by allowlisting missing types. Previously, batching Audience queries with timezone, language, browser_versions, and screen_resolution triggered a 401; these types are now public-readable so /demo//audience loads as expected. Addresses #650.
packages/ai/src/query/builders/index.ts.packages/ai/src/query/builders/public-access.test.ts.Written for commit 79f2d1e. Summary will update on new commits.