Download a signed document
Latest update: Abril 29, 2021
The following use case is assumed:
- Owner of the request: API
Response body:
{
"link": "string",
"fileName": "string",
"expires": 0
}
Example:
{
"link": "https://sandbox.viafirma.com/documents/download/eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJkb3dubG9hZFR5cGUiOiJTSUdORUQiLCJkb3dubG9hZE5hbWUiOiIxNTYyNTc4ODE2OTU2UjQ3My5wZGYiLCJkb3dubG9hZENvZGUiOiIxNTYyNTc4ODE2OTU2UjQ3MyIsImRvd25sb2FkRXhwaXJlcyI6MTU2MU5MTU5NDgzNX0.4mfzLbf8xZLECEc66H8N-u7bGQF-QXIUh9J993IZYHU",
"fileName": "1562578816956R473.pdf",
"expires": 1562591594835
}
Answer params:
- Link: Unique and temporary URL where the PDF can be downloaded.
- FileName: PDF name.
- Expires: timestamp in milliseconds that shows the expiry date of the link where you can download the PDF. Once this time has elapsed, the GET service must be requested again to obtain a new download link.
Alternative responses in case of error: HTTP status codes other than 200/OK will be returned. In that case a JSON describing the problem will always be returned:
{
"code": "string",
"type": "string",
"message": "string",
"trace" : "string"
}
Example:
the document hasn't been signed yet, current status "WAITING"
{
"code": 243,
"type": "Error",
"message": "El estado de la solicitud no es válido."
}
the API that consumes it does not own the request.
{
"code": 91,
"type": "Error",
"message": "Sorry, this application is not allowed."
}
Document removed
{
"code": 313,
"type": "Error",
"message": "Documento no encontrado."
}
results matching ""
No results matching ""