Intro
This API helps you in the process of providing the necessary data documents to your workfloo if you want to add physical documents.
Important points
To make the request it is necessary to provide the workfloo Id generated in the workfloo platform or in the Execute a workfloo API.
Path parameter
You must send in the URL as a path parameter, the workfloo identifier that you generated in the initial step of executing a workfloo.
For example:
- Sandbox
https://sandbox.workfloo.kiban.com/api/v1/workfloo/657118e1d511b6e54fe2a969/document
- Production
https://workfloo.kiban.com/api/v1/workfloo/657118e1d511b6e54fe2a969/document
Request Body
To apply the query, the parameters defined in the form must be sent in the body.
If you want to know the required parameters, you can make a query without any parameters in the body by simply sending the empty JSON parentheses {} . The response will indicate the name of parameters that are required to execute the query.
Another way to know the parameters is to enter the edition of your documents step, for each of the fields there will be the following definition and each of them will have a configuration button.
Once you have entered each of the configuration buttons by clicking in the Edit section, you will be able to view the identifier of each field.
We cannot tell you exactly a request, because it will depend entirely on the fields you have defined in your form, but we can give you the following example of a JSON to obtain OCR data from a front and back INE
{
"ine_data_extraction_set": [
{
"ine_back_image": "iVBORw0KGgoAAAANSUhEUgAAAvcAAALWCAYAAADCj...",
"ine_front_image": "iVBORw0KGgoAAAANSUhEUgAAAvoAAAIYCAYAAAAc..."
}
]
}
Successful response
A successful response will only return a 200 http code, you will not get a body.
Listing the possible error responses
Format and required errors (Just as example)
When there is an error in the body sent, this may happen because a required parameter was not sent or the shared format is not appropriate. In any case, the error will be indicated so that it can be solved.
{
"typeError": "REQUIRED_FIELDS",
"errors": {
"idWorkflooDefinition": "required"
},
"errorMessage": ""
}
Required scenarioId
You will get a 400 bad request error when the idWorkflooDefinition is not provided in the request body.
{
"typeError": "ELEMENT_NOT_EXIST_ERROR",
"errors": null,
"errorMessage": "scenarioId not found"
}
Does not exits execution Id
The execution id provided does not exist, the service will return a 404 without a response body.
Unauthorized
It means that the provided API is incorrect and that you are not authorized to access it. You will not receive a body, only a 401 HTTP code.