π‘ Package Query
GET /document
This service allows you to query document packages in Auco.
Authenticationβ
Include your public key in the Authorization
header.
Authorization: puk_xxx...
Query Parametersβ
Name | Type | Required | Description |
---|---|---|---|
package | String | Optional | ID of the document package. Required if code is not provided. |
β οΈ If you do not send the
code
orpackage
attribute, you will receive a list of automated templates.
info
This same endpoint can also be used to obtain information about a specific document. See more in query processes and templates
π§ͺ Usage Examplesβ
tip
You can copy any of the examples according to your preferred programming language.
πΉ Get General Process Informationβ
- curl
- Python
- Node.js
curl --location 'https://api.auco.ai/v1.5/ext/document?code=ID_PACKAGE' \
--header 'Authorization: puk_yourPublicKey'
import requests
response = requests.get(
"https://api.auco.ai/v1.5/ext/document",
headers={"Authorization": "puk_yourPublicKey"},
params={"package": "ID_PACKAGE"}
)
print(response.json())
const axios = require('axios');
axios
.get('https://api.auco.ai/v1.5/ext/document', {
headers: { Authorization: 'puk_yourPublicKey' },
params: { package: 'ID_PACKAGE' },
})
.then((response) => console.log(response.data));
π₯ Example Responseβ
{
"_id": "ID_PACKAGE",
"codes": ["CODEDOC1", "CODEDOC2"],
"name": "Prueba paquete de documentos",
"signers": [
{
"userId": "AI",
"email": "example1@auco.ai",
"name": "Firmante 1",
"phone": "+573000000000",
"status": "NOTIFICATION"
},
{
"userId": "OR",
"email": "example2@auco.ai",
"name": "Firmante 2",
"phone": "+573000000000",
"status": "NOTIFICATION"
}
],
"signFinish": false,
"createdAt": "2024-10-18T20:20:34.970Z",
"updatedAt": "2024-11-15T02:02:12.775Z",
"status": "CREATED"
}
π Document Status (status
)β
Status | Description |
---|---|
CREATED | When the process has been created. |
REJECTED | Process rejected. |
EXPIRED | Process expired, only if an expiration date was assigned at creation. |
FINISH | Process signed or approved by all parties. |
π Participant Status (status
)β
Status | Description |
---|---|
NOTIFICATION | The participant has been notified to sign. |
REJECT | The participant has rejected the signing or approval of the process. |
FINISH | The participant has signed or approved the process. |
BLOCK | The participant has exceeded the failed attempts when signing or approving. |
PENDING | The participant has not been notified, usually due to a sequential process. |
β οΈ Error Responsesβ
Code | Description |
---|---|
400 | Process not found (DOCUMENT_NOT_FOUND ) |
401 | Invalid or missing authentication |