Skip to main content

Assignment Documents

Three queries about the Assignment Term: the term link of a batch, the listing of the terms of a fund class, and the electronic signature link.

Retrieves the download links for the Assignment Term — both the original version and the signed version. The endpoint responds from the moment the Term is generated; before that it returns TRC000099.

Available on
ProfileHostRequired permission
Managermanager-apiRead
Consultantconsultant-apiView Assignments
Assignorassignor-apiRead

Base URL for each host: Environments (Hosts).

When to use

After receiving the webhook with status pending_assignment_term_signature, use this endpoint to get the Assignment Term link and track whether the signature has been completed.

Request​

ENDPOINT
/trade_receivables/fund_class/{fund_class_key}/assignment_configuration/{assignment_configuration_key}/assignment/{assignment_external_id}/assignment_term_link
METHOD
GET

Path params​

ParameterTypeDescription
fund_class_keystringUnique fund key (UUID).
assignment_configuration_keystringAssignment configuration key (UUID).
assignment_external_idstringThe external_id provided when the batch was created.

Response​

STATUS
200
Response Body
{
"assignment_term_url": "https://storage.example.com/term/abc123.pdf",
"signed_assignment_term_url": "https://storage.example.com/term/abc123_signed.pdf"
}

Response attributes​

FieldTypeDescription
assignment_term_urlstringURL that leads to the term download.
signed_assignment_term_urlstringPre-signed URL to download the signed Assignment Term. The file is only available after all parties have signed.
Note

Both URLs are pre-signed and expire in 1 hour. Generate a new link by calling the endpoint again.

The signed_assignment_term_url field is always returned, but the file only exists after the Assignment Term has been signed by all parties involved. Before that, accessing the URL returns an error. Once the signature is complete, the batch moves to pending_payment, with a webhook, or to pending_custody, without a webhook, according to the assignment configuration. In the second case, track it through Batch Retrieval.


Assignment Term Listing​

Paginated query endpoint that returns the Assignment Terms of the batches of a fund class, with the pre-signed links to download the original term and the signed term. Use the filters to search terms by assignment date, period, status or a specific batch.

Available on
ProfileHostRequired permission
Managermanager-apiRead
Consultantconsultant-apiView Assignments

Base URL for each host: Environments (Hosts).

Fund class endpoint

Like the Batch Listing, this endpoint uses only the fund_class_key in the URL — there is no need to provide the assignment_configuration_key. To get the term of a specific batch, pass the batch external_id as a filter.

Only batches that already have a generated Assignment Term and that belong to the authenticated agent (manager or consultant linked to the fund class) are returned.

Request​

ENDPOINT
/trade_receivables/fund_class/{fund_class_key}/assignment_terms
METHOD
GET

Path params​

ParameterTypeDescription
fund_class_keystringUnique fund key (UUID).

Query params​

ParameterTypeRequiredDescription
assignment_datestringoptionalFilters by assignment date in YYYY-MM-DD format.
start_datestringoptionalReturns batches with an assignment date on or after the given date, in YYYY-MM-DD format.
end_datestringoptionalReturns batches with an assignment date on or before the given date, in YYYY-MM-DD format.
external_idstringoptionalFilters by the external_id provided when the batch was created.
assignment_keystringoptionalFilters by the batch key (UUID).
assignment_statusstringoptionalFilters by a specific batch status.
in_statusstringoptionalComma-separated list of statuses. Returns only batches in one of the given statuses.
not_in_statusstringoptionalComma-separated list of statuses. Excludes the batches in these statuses.
assignor_document_numberstringoptionalFilters by the assignor's document number (CPF/CNPJ). Must be sent with punctuation (e.g., 11.222.333/0001-81 or 969.698.790-03).
origin_typestringoptionalFilters by batch origin (e.g., client).
pageintegeroptionalPage number (starts at 0). Default: 0.
limitintegeroptionalNumber of records per page. Default: 25. Maximum: 155.
Example call — terms of a date
GET /trade_receivables/fund_class/{fund_class_key}/assignment_terms?assignment_date=2024-04-01&page=0&limit=25
Example call — term of a batch by external_id
GET /trade_receivables/fund_class/{fund_class_key}/assignment_terms?external_id=931e9437-d025-41ab-bb53-6b94e10fd361

Response​

STATUS
200
Response Body
{
"data": [
{
"assignment_key": "41d6ff41-1dac-4df7-9e50-d15210ec57f3",
"external_id": "931e9437-d025-41ab-bb53-6b94e10fd361",
"name": "CESSÃO #12345",
"assignment_configuration_key": "3571e292-3a83-4011-904d-20ee963022ef",
"assignment_number": "00012345",
"assignment_date": "2024-04-01",
"status": "completed",
"assignment_term_key": "b1c2d3e4-f5a6-7890-abcd-ef1234567890",
"assignment_term_url": "https://storage.example.com/term/abc123.pdf",
"signed_assignment_term_url": "https://storage.example.com/term/abc123_signed.pdf"
}
],
"limit": 25,
"page": 0,
"is_last_page": true
}

Response attributes​

FieldTypeDescription
dataarrayList of Assignment Terms. See table below.
pageintegerCurrent page number.
limitintegerNumber of records per page.
is_last_pagebooleanIndicates whether this is the last page of results.

Attributes of each term (objects within data)

FieldTypeDescription
assignment_keystringUnique batch identifier (UUID).
external_idstringExternal key provided by the partner.
namestringAssignment identifier name.
assignment_configuration_keystringKey of the batch's assignment configuration (UUID).
assignment_numberstringAssignment batch number.
assignment_datestringAssignment date in YYYY-MM-DD format.
statusstringCurrent batch status. See the batch status enumerators.
assignment_term_keystringAssignment Term key (UUID).
assignment_term_urlstringPre-signed URL to download the original Assignment Term.
signed_assignment_term_urlstringPre-signed URL to download the signed Assignment Term. The file is only available after all parties have signed.
Note

The URLs are pre-signed and expire in 1 hour. To get new links, call the endpoint again.

Batches are sorted from the most recent to the oldest. Batches whose Assignment Term has not yet been generated do not appear in the listing.


Retrieves the link to the CertifiQI signature interface for the Assignment Term, along with information about the batches and the document download link. The endpoint responds from the moment the Term is generated. It is not available when the signature is made through QCertifica or when the assignment configuration waives the signature (TRC000131).

Available on
ProfileHostRequired permission
Consultantconsultant-apiView Assignments

Base URL for each host: Environments (Hosts).

Request​

ENDPOINT
/trade_receivables/fund_class/{fund_class_key}/assignment_configuration/{assignment_configuration_key}/assignment/{assignment_external_id}/assignment_signature_url
METHOD
GET

Path params​

ParameterTypeDescription
fund_class_keystringUnique fund key (UUID).
assignment_configuration_keystringAssignment configuration key (UUID).
assignment_external_idstringThe external_id provided when the batch was created.

Response​

STATUS
200
Response Body
{
"batches": [
{
"name": "Termo de Cessão - Lote 001",
"document_type": "assignment_term",
"status": "pending",
"document_key": "doc-uuid-example",
"related_parties": []
}
],
"signature_url": "https://certifiqi.com/events/{external_batch_group_key}",
"download_url": "https://storage.example.com/term/abc123.pdf"
}

Response attributes​

FieldTypeDescription
batchesarrayList of batches linked to the Assignment Term.
batches[].namestringBatch name.
batches[].document_typestringDocument type (e.g., assignment_term, duplicata).
batches[].statusstringCurrent signature status of the batch.
batches[].document_keystringDocument identifier key.
batches[].related_partiesarrayParties involved in signing the batch.
signature_urlstringURL to access the CertifiQI signature interface.
download_urlstringPre-signed URL to download the Assignment Term.
Note

The download_url field points to the original (unsigned) document while the batch is in pending_send_to_signature or pending_assignment_term_signature. After all parties have signed, it points to the signed Assignment Term. The URL is pre-signed and expires in 1 hour.

Errors​

StatusCodeEndpointWhen it happens
400TRC000099Term link, signature linkThe batch's Assignment Term has not been generated yet.
400TRC000131Signature linkThe assignment configuration does not use electronic signature with a link (for example, signature through QCertifica or no signature), or the link is not available yet.
400—Term listinglimit above 155 or negative page (parameter validation).
404TRC000018Term link, signature linkNo batch with this external_id in this assignment configuration.

Authentication, permission and host errors: see API Errors.