Inbox rules
Validate an inbox rule
Changed onRuns every check that creating (mode: new) or updating (mode: edit) an inbox rule runs, limits included, and saves nothing.
Unlike dry_run=true on create and update, an invalid definition isn't an error: it answers 200 with valid: false and every problem found.
post/communications/inbox_rule/validate
Request
- Base URLhttps://api.nullplatform.com
- URLhttps://api.nullplatform.com/communications/inbox_rule/validate
- AuthHTTP bearer
Request body
Example request
{
"definition": {
"id": "acme.security_finding",
"status": "active",
"context_schema": {
"type": "object",
"required": [
"id",
"service",
"owner_id"
],
"properties": {
"id": {
"type": "string"
},
"service": {
"type": "string"
},
"summary": {
"type": "string"
},
"owner_id": {
"type": "integer"
}
}
},
"category": {
"group": "security",
"label": "Security findings",
"description": "Vulnerabilities your CI scanners report.",
"configurable": true,
"allows_all": true,
"default_mode": "involved"
},
"severity": "degraded",
"audience": [
{
"as": "owner",
"who": {
"user": "${{ context.owner_id }}"
},
"action": "acme.security_finding",
"content": {
"title": "Security finding on ${{ context.service }}",
"body": "${{ context.summary }}"
}
}
],
"visible_to": [
"organization=1:account=2"
]
},
"mode": "new",
"type_id": "acme.security_finding"
}Response
The verdict, for a valid or an invalid definition alike.
Example response
{
"problems": [
{
"path": "/category/default_mode",
"message": "must be equal to one of the allowed values"
}
]
}Changes
- info
endpoint added
- info