Test the inference hook
⚠️
Preview — this feature is being built; the design below is the spec.
POST https://app.syntic.ai/v1/organizations/inference_hook/testSend a signed sample payload to the hook and report what came back, without running a model. Use it after deploying a new version of your policy service.
For how this fits into a full workflow, see Inference hooks.
Headers
| Header | Required | Value |
|---|---|---|
Authorization | Yes | Bearer <admin key>: an Admin API key (sk_admin_...). Inference keys are refused with 403 admin_key_required. See Admin API keys. |
syntic-beta | Yes, while in preview | admin-2026-11-01. Without it the call fails with 400 beta_required. See Versioning. |
Content-Type | Yes | application/json |
Idempotency-Key | No | Up to 255 characters. Retrying with the same key within 24 hours returns the first result instead of acting twice. See Idempotency. |
Body parameters
| Parameter | Type | Required | Notes |
|---|---|---|---|
sample | string | No | benign (default) or should_deny: a prompt your policy is expected to refuse. |
Response
200 OK, Content-Type: application/json
{
"type": "inference_hook_test",
"status_code": 200,
"verdict": "deny",
"reason": "policy:pii-export",
"latency_ms": 143,
"signature_valid_example": true
}| Field | Type | Description |
|---|---|---|
verdict | string | allow, deny or invalid (the body was not a valid verdict). |
latency_ms | integer | Round trip, compared with the configured timeout. |
Examples
curl -sS "https://app.syntic.ai/v1/organizations/inference_hook/test" \
-H "Authorization: Bearer $SYNTIC_ADMIN_KEY" \
-H "syntic-beta: admin-2026-11-01" \
-H "Idempotency-Key: 8d6f0c1e-4b2a-4a57-9f0e-2f1d3c4b5a69" \
-H "Content-Type: application/json" \
-d '{
"sample": "should_deny"
}'Errors
Errors use the error envelope and carry a request_id. Codes specific to this operation:
| Status | type | code | When |
|---|---|---|---|
| 400 | invalid_request_error | beta_required | The syntic-beta header is missing. |
| 404 | not_found_error | inference_hook_not_set | No hook is configured. |
| 401 | authentication_error | invalid_api_key | The admin key is missing, unknown, revoked or expired. |
| 403 | permission_error | admin_key_required | An inference key was used. |
| 429 | rate_limit_error | rate_limited | Too many requests; wait for Retry-After. See Rate-limit headers. |
Was this page helpful?