validateFile
Changed onValidate an uploaded file against one or more document validation rules (validation-rules-api rules with input_type: document).
The file is referenced either by its file entity id or, for an upload that has not been saved as an entity yet (e.g. a journey upload in the temporary prefix), by its S3 reference. The service collects an observation of the file - deterministic facts such as the sniffed mime type, size, page count, image resolution, blank and password-protection detection - and evaluates every rule against it with the shared validation rules engine.
The response carries one result per rule with a per-condition outcome (pass, fail, uncertain, skipped), plus the observation the results were derived from. status is completed for checks that finish synchronously; pending is reserved for check levels that need asynchronous content extraction.
Request
- Base URLhttps://file.sls.epilot.io
- URLhttps://file.sls.epilot.io/v1/files/validations
- Auth
- HTTP bearer
- or API key in cookie token
Request body
Example request
{
"file": {
"s3ref": {
"bucket": "epilot-prod-user-content",
"key": "123/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf"
}
}
}Response
The validation result
Example response
{
"file": {
"s3ref": {
"bucket": "epilot-prod-user-content",
"key": "123/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf"
}
}
}Changes
- info
endpoint added
- info