Query documents
Returns a document attached to the assignment contract (the contract or the manager's declaration) with the URL to download its most recent version.
Available on
| Profile | Host | Required permission |
|---|---|---|
| Manager | manager-api | Read |
| Consultant | consultant-api | View assignment contracts |
Base URL for each host: Environments (Hosts).
Request
ENDPOINT
/assignment_contract/assignment_contract/ASSIGNMENT_CONTRACT_KEY/attached_document/DOCUMENT_KEYMETHOD
GETPath Params
| Parameter | Description |
|---|---|
assignment_contract_key | Assignment contract key |
document_key | Document key |
Response
STATUS
200Response Body
{
"document_key": "8f1b2c3d-4e5f-4a6b-8c7d-9e0f1a2b3c4d",
"document_type": "assignment_contract",
"status": "signed",
"generation_method": "internal",
"signature_validation_method": "internal",
"document_template_key": "2a7c9e1b-3d5f-4b8a-9c0e-6f1a2b3c4d5e",
"required_parties": ["manager", "assignor"],
"upload_document_analyses": [],
"download_url": "document download url"
}
Note
The download_url field provides the signed URL to download the document in its most current version: if the document is already signed, it is the signed version. The URL expires and must not be stored for later queries.
Attached Document Definition
| Field | Type | Description | Characters |
|---|---|---|---|
document_key * | string | Document unique identification key. | 36 |
document_type * | string | Document type. | -- |
status * | string | Document status. | See Attached Document Status. |
document_template_key | string | Unique identification key of the template that generated the document. | 36 |
required_parties | array | List of parties that sign the document in question. | -- |
generation_method | string | How the document is generated: internal (by the platform) or external (submitted by upload). | -- |
signature_validation_method | string | How the signature is validated (for example, internal or external). | -- |
upload_document_analyses | array | Analyses of the documents submitted by upload. Empty when there is no upload. | -- |
download_url | string | PDF download URL. | -- |
Errors
| Status | Code | When it happens |
|---|---|---|
| 404 | ACT000023 | assignment_contract_key not found. |
| 404 | ACT000087 | document_key not found or does not belong to the contract indicated. |
Authentication, permission and host errors: see API errors.