Validate Cypher against the schema without executing it
const url = 'http://localhost:11044/api/v1/kg/studio/validate';const options = { method: 'POST', headers: {'X-Embabel-Api-Key': '<X-Embabel-Api-Key>', 'Content-Type': 'application/json'}, body: '{"args":{"additionalProperty":"example"},"captureAs":"example","cypher":"example","params":{"additionalProperty":{"choices":["example"],"default":"example","description":"example","required":true,"type":"string"}},"surface":"studio"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url http://localhost:11044/api/v1/kg/studio/validate \ --header 'Content-Type: application/json' \ --header 'X-Embabel-Api-Key: <X-Embabel-Api-Key>' \ --data '{ "args": { "additionalProperty": "example" }, "captureAs": "example", "cypher": "example", "params": { "additionalProperty": { "choices": [ "example" ], "default": "example", "description": "example", "required": true, "type": "string" } }, "surface": "studio" }'Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”The Cypher to check, in cypher, preflighted against the caller’s schema exactly as strict execution would; only cypher is read, so params/args are not substituted and captureAs is ignored
Cypher to run through the virtual-cypher engine — the body of /execute, and of /validate, which reads only cypher.
object
Arguments for params. A blank value means not supplied, so the default applies.
object
Capture the result set as this named scope; reference it later as (x:$name). The statement must RETURN one labelled node variable. Synchronous mode only.
The statement, run verbatim — or, when params is given, a view body whose $name references are substituted first.
Declared parameters for the cypher, as a view declares them. Each $name is substituted from args merged over its default, exactly as when a saved view runs.
object
A declared bind variable of a saved view, referenced as $name in its Cypher and supplied per invocation, keyed by that name wherever a view’s params are declared or listed
object
The fixed set of values this param accepts — rendered as a select, enforced at invocation. Absent = any value of the declared type.
Used when an invocation omits this param. Absent = required on invocation, unless required: false.
What the argument means — rendered verbatim as the field’s hint.
False lets an invocation omit a param that has no default; it is then bound to null.
The coercion applied to supplied values, and the form control a UI renders (int/number a number field, boolean a checkbox, date a date picker). float and double are aliases of number.
Where the statement was written, recorded in the query log: studio for a query written in Query Studio’s editor. Omitted, it is logged as query. Any other value is a 400.
Responses
Section titled “Responses”The verdict; message is present even when null
The result of validating cypher against the schema without executing it.
object
A single human-readable summary, or null when there is nothing to say.
True when the cypher passes the strict preflight — the same check strict execution applies.
What the schema contradicts, one entry per defect.
Example generated
{ "message": "example", "ok": true, "violations": [ "example" ]}Not authenticated
A refusal carrying only a human-readable reason.
object
What went wrong, in the terms the caller can act on.
Example generated
{ "error": "example"}
