Validate Blocked Words File
Validate a blocked_words YAML file content.
Args: request: Dictionary with 'file_content' key containing the YAML string
Returns: Dictionary with 'valid' boolean and either 'message'/'errors' depending on result
Example Request:
{
"file_content": "blocked_words:\n - keyword: \"test\"\n action: \"BLOCK\""
}
Example Success Response:
{
"valid": true,
"message": "Valid YAML file with 2 blocked words"
}
Example Error Response:
{
"valid": false,
"errors": ["Entry 0: missing 'action' field"]
}
Request body
Response
Successful Response
Changes
Changed in 3 of the 15 revisions of this API.6
- ○
api tag
Guardrailsaddedapi-tag-added
- ○
api tag
guardrailsremovedapi-tag-removed
This revision also has 2 changes that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog
- ○
- ○
api tag
guardrailsaddedapi-tag-added
- ○
api tag
Guardrailsremovedapi-tag-removed
This revision also has 19 changes that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog
- ○
- ○
api tag
Guardrailsaddedapi-tag-added
- ○
api tag
guardrailsremovedapi-tag-removed
- ○