curl --request POST \
--url 'https://api.nsr.stateset.com/api/v1/nsr/validate/batch' \
--header 'X-API-Key: YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"cases": [
{
"case_id": "string",
"inquiry": "string",
"response": "string"
}
],
"include_neural_signals": true,
"max_ngram": 1,
"max_phrases": 1,
"persist": true
}'
{
"invalid": 1,
"results": [
{
"case_id": "string",
"index": 1,
"inquiry": "string",
"response": "string",
"result": {
"escalations": null,
"execution_time_ms": null,
"missing_links": null,
"neural": null,
"program_version_id": null,
"response_invalid": null,
"run_id": null,
"topics": null,
"valid": null,
"violations": null
}
}
],
"total": 1,
"valid": 1
}
Batch validate responses using NSR-L rules + text signals.
Required scope: write
POST
/
api
/
v1
/
nsr
/
validate
/
batch
curl --request POST \
--url 'https://api.nsr.stateset.com/api/v1/nsr/validate/batch' \
--header 'X-API-Key: YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"cases": [
{
"case_id": "string",
"inquiry": "string",
"response": "string"
}
],
"include_neural_signals": true,
"max_ngram": 1,
"max_phrases": 1,
"persist": true
}'
{
"invalid": 1,
"results": [
{
"case_id": "string",
"index": 1,
"inquiry": "string",
"response": "string",
"result": {
"escalations": null,
"execution_time_ms": null,
"missing_links": null,
"neural": null,
"program_version_id": null,
"response_invalid": null,
"run_id": null,
"topics": null,
"valid": null,
"violations": null
}
}
],
"total": 1,
"valid": 1
}
Required scope:
write
Request body
NSRValidateBatchRequest
NSRValidateBatchItem[]
required
Items to validate.
boolean
Include NSR Machine neural signals in the response.
integer
Max n-gram length used for contains_text assertions.
integer
Cap on total phrases asserted per text.
boolean
Persist validation runs for history/auditing.
Response
NSRValidateBatchResponse
integer
required
NSRValidateBatchItemResult[]
required
Show NSRValidateBatchItemResult
Show NSRValidateBatchItemResult
string
integer
required
string
required
string
required
NSRValidateResponse
required
Show NSRValidateResponse
Show NSRValidateResponse
string[]
required
Escalation topics detected.
integer (int64)
required
Execution time in milliseconds.
string[]
required
Missing required links.
object
string
Optional NSR-L program version id used for this validation.
boolean
required
Response is explicitly invalid (response_invalid/1).
string
Optional persisted run id when stored.
string[]
required
Topics detected in the inquiry.
boolean
required
Overall validity (no violations/missing links/escalations and not response_invalid).
string[]
required
Prohibited phrases detected.
integer
required
integer
required
Status codes
| Code | Meaning |
|---|---|
200 | Batch validation result |
400 | Invalid request |
401 | Unauthorized — missing or invalid credentials |
403 | Forbidden — the key/token lacks the required scope |
429 | Rate limited — see Retry-After / X-RateLimit-Reset |
curl --request POST \
--url 'https://api.nsr.stateset.com/api/v1/nsr/validate/batch' \
--header 'X-API-Key: YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"cases": [
{
"case_id": "string",
"inquiry": "string",
"response": "string"
}
],
"include_neural_signals": true,
"max_ngram": 1,
"max_phrases": 1,
"persist": true
}'
{
"invalid": 1,
"results": [
{
"case_id": "string",
"index": 1,
"inquiry": "string",
"response": "string",
"result": {
"escalations": null,
"execution_time_ms": null,
"missing_links": null,
"neural": null,
"program_version_id": null,
"response_invalid": null,
"run_id": null,
"topics": null,
"valid": null,
"violations": null
}
}
],
"total": 1,
"valid": 1
}