SocialHz Engineering · 1 November 2026 · Requested by a customer
Validation that says what to fix
GET /api/v1/search · POST /api/v1/quick-run
What shipped
Every search is now checked before anything is fetched or charged. A mistake gets 400 invalid_request with a message that names the problem and the fix. Anything harmless is let through and reported in filters.ignored.
Why
A customer's search kept failing, and the cause was a missing space between or and a brand name. They asked for errors that point at the problem.
What's checked
- A misspelled parameter: "page_sise" isn't a search parameter. Did you mean "page_size"? This also catches pageSize, startDate, q and limit.
- A value that can't be read: page_size must be a whole number from 1 to 200, and "abc" isn't.
- The same parameter twice with different values: page was sent 2 times, as "1" and "2". Send it once.
- or run into a keyword: "orLumina" looks like "or" run into a keyword. Add a space: "or Lumina".
- A quote opened and never closed, naming the text after it.
- end_date before start_date, naming both dates.
What isn't flagged
Words like Oreo, orbit, ORACLE and Mentor aren't treated as typos, and text in quotes is never checked. A parameter that looks nothing like ours, such as utm_source, is searched with, listed in filters.ignored and explained in filters.notes. The same checks run on Get data runs and as you type on the Search page.
The error body
A request turned back at this stage is never charged.
HTTP/1.1 400 Bad Request
{ "error": { "code": "invalid_request",
"message": "\"page_sise\" isn't a search parameter. Did you mean \"page_size\"?" },
"request_id": "3f9c2a71b8e04d55" }
Request a feature
Tell us what you need on the updates page. The engineering team reads every request.