Skip to main content

Webhook

All notifications related to the batch group will be sent to the address registered at the event creation. In every webhook call, the payload will include data from batch_group, batches, related_parties, signer_groups, and signer.

The notification will be sent whenever one of the following stages is completed: related parties, start of ZIP file creation, or completion of the batch group.

In this case, the signature_status field of the related party, the signer group, and the signers will have the value signed. Meanwhile, the internal_status field will have the value pending.

Webhook Examples​

Response Body
{
"batch_group_key": "uuid",
"name": "Contrato de exemplo",
"main_related_party": "aaa",
"number_of_documents": 1,
"total_value": 0,
"all_files_url": "",
"send_to_fund_administrator": 0,
"signature_expiration_date": null,
"webhook_key": "uuid",
"client_key": "uuid",
"requester_key": null,
"signature_status": "pending",
"internal_status": "pending",
"attached_document_number": "71029579000163",
"current_signature_position": "1",
"control_number": null,
"internal_webhook_key": null,
"created_at": "2023-05-18 00:02:49",
"batch_group_type": "icp_signature",
"requester_identifier": null,
"send_emails": true,
"batches": [
{
"document_batch_key": "uuid",
"name": "Outros",
"document_type": "other",
"signature_type": "cades",
"signature_status": "pending",
"created_at": "2023-05-18 00:02:49",
"related_parties": [
{
"related_party_key": "uuid",
"name": "Signatário Exemplo",
"role": "assignor",
"signature_status": "signed",
"signature_position": "1",
"created_at": "2023-05-18 00:02:49",
"auto_signature": 0,
"notify_to": [],
"signer_groups": [
{
"id": 38598,
"expiration": null,
"minimum_required_signers": 1,
"signable_limit": null,
"signature_status": "signed",
"created_at": "2023-05-18 00:02:49",
"signers": [
{
"id": 65095,
"signer_control_number": "1",
"signature_timestamp": "2023-05-18 00:06:08",
"signature_status": "signed",
"name": "Signatário Exemplo",
"is_group_mandatory": true,
"email": "signatario@example.com",
"document_number": "69397891111",
"created_at": "2023-05-18 00:02:49"
}
]
}
]
},
{
"related_party_key": "uuid",
"name": "Turing",
"role": "guarantor",
"signature_status": "pending",
"signature_position": "1",
"created_at": "2023-05-18 00:02:49",
"auto_signature": 0,
"notify_to": [],
"signer_groups": [
{
"id": 38599,
"expiration": null,
"minimum_required_signers": 1,
"signable_limit": null,
"signature_status": "pending",
"created_at": "2023-05-18 00:02:49",
"signers": [
{
"id": 65096,
"signer_control_number": "1",
"signature_timestamp": null,
"signature_status": "pending",
"name": "Turing",
"is_group_mandatory": true,
"email": "testemunha@example.com",
"document_number": "58014216296",
"created_at": "2023-05-18 00:02:49"
}
]
}
]
}
],
"documents": [
{
"document_key": "uuid",
"control_number": "uuid",
"file_size": 1669,
"file_url": "https://qi.example.com/arquivos/uuid/documento_exemplo_original.pdf",
"name": "documento_exemplo.pdf",
"original_file_url": "https://qi.example.com/arquivos/uuid/documento_exemplo_original.pdf",
"status": "pending",
"signed_file_url": null,
"created_at": "2023-05-18 00:02:49",
"signatures": [
{
"signer": {
"id": 65095,
"signer_control_number": "1",
"signature_timestamp": "2023-05-18 00:06:08",
"signature_status": "signed",
"name": "Signatário Exemplo",
"is_group_mandatory": true,
"email": "signatario@example.com",
"document_number": "69397891111",
"created_at": "2023-05-18 00:02:49"
},
"signed_hash": "EjBUEGsOkny9SXaZbmLQLy+IRjvTtYnc73V8Hbb02uMktDn3/PJ24Gj7xQMj3jdOuRLVNzi1Fz02QYc2FEUdPxjOPQoycyQmI8ppPFwNsADym79EGRYqHlCGu9CccolZgA8FbgQgQ8FJAboQV9uSAPsS6zui1CHdmy4/3xink33KFpR9k42rI3iZgzi42gkrACJ1hhLPecc4HdTBQS6h+fsMNk/hsdKR3OLlXC+Ri3k8I/fJmNp2BBqILOhSxPeD4RpeyCtDFDbiKKA3pYgQqPqtEdfRdVFWY9uNGcoF1oIzGQg32Fh9o2UCqu58f+VqaElRGuCK6DZQ5nTZp2bbEg==",
"signature_timestamp": "2023-05-18 00:06:08",
"signature_status": "signed",
"role": "assignor",
"created_at": "2023-05-18 00:06:13"
}
]
}
]
}
],
"watcher_clients": [],
"zip_file_keys_list": []
}

Event Completion​

To finalize the event, a webhook will first be sent indicating that all related parties have signed. At this moment, the internal_status field will have the value waiting_zip_files_creation. The link to the signed documents will already be available.

After the webhook mentioned above, a new webhook will be sent indicating the complete finalization of the event. At this point, the internal_status field will have the value finished, and the event will be supplemented with the ZIP file, which can be retrieved using the keys contained in zip_file_keys_list. The ZIP file contains all documents and the signature file.

To learn how to retrieve the ZIP file, refer to section 4.5. Retrieve URL.

Webhook Examples Waiting for ZIP Generation​

Response Body
{
"batch_group_key": "uuid",
"name": "Contrato de exemplo",
"main_related_party": "aaa",
"number_of_documents": 1,
"total_value": 0,
"all_files_url": null,
"send_to_fund_administrator": 0,
"signature_expiration_date": null,
"webhook_key": "uuid",
"client_key": "uuid",
"requester_key": null,
"signature_status": "signed",
"internal_status": "waiting_zip_files_creation",
"attached_document_number": "71029579000163",
"current_signature_position": "1",
"control_number": null,
"internal_webhook_key": null,
"created_at": "2023-05-18 00:02:49",
"batch_group_type": "icp_signature",
"requester_identifier": null,
"send_emails": true,
"batches": [
{
"document_batch_key": "uuid",
"name": "Outros",
"document_type": "other",
"signature_type": "cades",
"signature_status": "signed",
"created_at": "2023-05-18 00:02:49",
"related_parties": [
{
"related_party_key": "uuid",
"name": "Signatário Exemplo",
"role": "assignor",
"signature_status": "signed",
"signature_position": "1",
"created_at": "2023-05-18 00:02:49",
"auto_signature": 0,
"notify_to": [],
"signer_groups": [
{
"expiration": null,
"minimum_required_signers": 1,
"signable_limit": null,
"signature_status": "signed",
"created_at": "2023-05-18 00:02:49",
"signers": [
{
"signer_control_number": "1",
"signature_timestamp": "2023-05-18 00:06:08",
"signature_status": "signed",
"name": "Signatário Exemplo",
"is_group_mandatory": true,
"email": "signatario@example.com",
"document_number": "69397891111",
"created_at": "2023-05-18 00:02:49"
}
]
}
]
},
{
"related_party_key": "uuid",
"name": "Turing",
"role": "guarantor",
"signature_status": "signed",
"signature_position": "1",
"created_at": "2023-05-18 00:02:49",
"auto_signature": 0,
"notify_to": [],
"signer_groups": [
{
"expiration": null,
"minimum_required_signers": 1,
"signable_limit": null,
"signature_status": "signed",
"created_at": "2023-05-18 00:02:49",
"signers": [
{
"signer_control_number": "1",
"signature_timestamp": "2023-05-18 00:09:44",
"signature_status": "signed",
"name": "Turing",
"is_group_mandatory": true,
"email": "testemunha@example.com",
"document_number": "58014216296",
"created_at": "2023-05-18 00:02:49"
}
]
}
]
}
],
"documents": [
{
"document_key": "uuid",
"control_number": "uuid",
"file_size": 1669,
"file_url": "https://qi.example.com/arquivos/uuid/documento_exemplo_assinado.p7s",
"name": "documento_exemplo.pdf",
"original_file_url": "https://qi.example.com/arquivos/uuid/documento_exemplo_original.pdf",
"status": "signed",
"signed_file_url": "https://qi.example.com/arquivos/uuid/documento_exemplo_assinado.pdf",
"created_at": "2023-05-18 00:02:49",
"signatures": [
{
"signer": {
"signer_control_number": "1",
"signature_timestamp": "2023-05-18 00:06:08",
"signature_status": "signed",
"name": "Signatário Exemplo",
"is_group_mandatory": true,
"email": "signatario@example.com",
"document_number": "69397891111",
"created_at": "2023-05-18 00:02:49"
},
"signed_hash": "EjBUEGsOkny9SXaZbmLQLy+IRjvTtYnc73V8Hbb02uMktDn3/PJ24Gj7xQMj3jdOuRLVNzi1Fz02QYc2FEUdPxjOPQoycyQmI8ppPFwNsADym79EGRYqHlCGu9CccolZgA8FbgQgQ8FJAboQV9uSAPsS6zui1CHdmy4/3xink33KFpR9k42rI3iZgzi42gkrACJ1hhLPecc4HdTBQS6h+fsMNk/hsdKR3OLlXC+Ri3k8I/fJmNp2BBqILOhSxPeD4RpeyCtDFDbiKKA3pYgQqPqtEdfRdVFWY9uNGcoF1oIzGQg32Fh9o2UCqu58f+VqaElRGuCK6DZQ5nTZp2bbEg==",
"signature_timestamp": "2023-05-18 00:06:08",
"signature_status": "signed",
"role": "assignor",
"created_at": "2023-05-18 00:06:13"
},
{
"signer": {
"signer_control_number": "1",
"signature_timestamp": "2023-05-18 00:09:44",
"signature_status": "signed",
"name": "Turing",
"is_group_mandatory": true,
"email": "testemunha@example.com",
"document_number": "58014216296",
"created_at": "2023-05-18 00:02:49"
},
"signed_hash": "z7M0ozYCDGKWjkV4a1U5fK8tl0OcNqJGQXyJmreX16KjvQduv9qFevEc3tWej+1kpXm7jvhUuawSgSA7LJWQ/Flp+TRVyrfOgeBM3Xd+6uJA/c3zA9ASVlaEgwFw8/nD/dXE4EmLVOPhq9Mg3WeIDtq+c93TGhZtvdBpEuGu4q5/wfSTUhYYDPvljbjUvDXEOSTrvYboW1wDJyACCeeYLyPVaqTdOZ9ovXcVOZIpO8+fuIeNKGkuc6m7bXTvE5pD4FSxx5oNPj4N13E4TQN5wcNX+F0svVeVqA+2zrLU2mKGczVsgWO7qte1vct4eREs4dONStPvZ7+JQDSg+OotpQ==",
"signature_timestamp": "2023-05-18 00:09:44",
"signature_status": "signed",
"role": "guarantor",
"created_at": "2023-05-18 00:09:45"
}
]
}
]
}
],
"watcher_clients": [],
"zip_file_keys_list": []
}

Exemplos de Webhook Evento finalizado​

Response Body
{
"batch_group_key": "uuid",
"name": "Contrato de exemplo",
"main_related_party": "aaa",
"number_of_documents": 1,
"total_value": 0,
"all_files_url": "https://qi.example.com/arquivos/uuid/uuid.zip",
"send_to_fund_administrator": 0,
"signature_expiration_date": null,
"webhook_key": "uuid",
"client_key": "uuid",
"requester_key": null,
"signature_status": "signed",
"internal_status": "finished",
"attached_document_number": "71029579000163",
"current_signature_position": "1",
"control_number": null,
"internal_webhook_key": null,
"created_at": "2023-05-18 00:02:49",
"batch_group_type": "icp_signature",
"requester_identifier": null,
"send_emails": true,
"batches": [
{
"document_batch_key": "uuid",
"name": "Outros",
"document_type": "other",
"signature_type": "cades",
"signature_status": "signed",
"created_at": "2023-05-18 00:02:49",
"related_parties": [
{
"related_party_key": "uuid",
"name": "Signatário Exemplo",
"role": "assignor",
"signature_status": "signed",
"signature_position": "1",
"created_at": "2023-05-18 00:02:49",
"auto_signature": 0,
"notify_to": [],
"signer_groups": [
{
"expiration": null,
"minimum_required_signers": 1,
"signable_limit": null,
"signature_status": "signed",
"created_at": "2023-05-18 00:02:49",
"signers": [
{
"signer_control_number": "1",
"signature_timestamp": "2023-05-18 00:06:08",
"signature_status": "signed",
"name": "Signatário Exemplo",
"is_group_mandatory": true,
"email": "signatario@example.com",
"document_number": "69397891111",
"created_at": "2023-05-18 00:02:49"
}
]
}
]
},
{
"related_party_key": "uuid",
"name": "Turing",
"role": "guarantor",
"signature_status": "signed",
"signature_position": "1",
"created_at": "2023-05-18 00:02:49",
"auto_signature": 0,
"notify_to": [],
"signer_groups": [
{
"expiration": null,
"minimum_required_signers": 1,
"signable_limit": null,
"signature_status": "signed",
"created_at": "2023-05-18 00:02:49",
"signers": [
{
"signer_control_number": "1",
"signature_timestamp": "2023-05-18 00:09:44",
"signature_status": "signed",
"name": "Turing",
"is_group_mandatory": true,
"email": "testemunha@example.com",
"document_number": "58014216296",
"created_at": "2023-05-18 00:02:49"
}
]
}
]
}
],
"documents": [
{
"document_key": "uuid",
"control_number": "uuid",
"file_size": 1669,
"file_url": "https://qi.example.com/arquivos/uuid/documento_exemplo_assinado.p7s",
"name": "documento_exemplo.pdf",
"original_file_url": "https://qi.example.com/arquivos/uuid/documento_exemplo_original.pdf",
"status": "signed",
"signed_file_url": "https://qi.example.com/arquivos/uuid/documento_exemplo_assinado.pdf",
"created_at": "2023-05-18 00:02:49",
"signatures": [
{
"signer": {
"signer_control_number": "1",
"signature_timestamp": "2023-05-18 00:06:08",
"signature_status": "signed",
"name": "Signatário Exemplo",
"is_group_mandatory": true,
"email": "signatario@example.com",
"document_number": "69397891111",
"created_at": "2023-05-18 00:02:49"
},
"signed_hash": "EjBUEGsOkny9SXaZbmLQLy+IRjvTtYnc73V8Hbb02uMktDn3/PJ24Gj7xQMj3jdOuRLVNzi1Fz02QYc2FEUdPxjOPQoycyQmI8ppPFwNsADym79EGRYqHlCGu9CccolZgA8FbgQgQ8FJAboQV9uSAPsS6zui1CHdmy4/3xink33KFpR9k42rI3iZgzi42gkrACJ1hhLPecc4HdTBQS6h+fsMNk/hsdKR3OLlXC+Ri3k8I/fJmNp2BBqILOhSxPeD4RpeyCtDFDbiKKA3pYgQqPqtEdfRdVFWY9uNGcoF1oIzGQg32Fh9o2UCqu58f+VqaElRGuCK6DZQ5nTZp2bbEg==",
"signature_timestamp": "2023-05-18 00:06:08",
"signature_status": "signed",
"role": "assignor",
"created_at": "2023-05-18 00:06:13"
},
{
"signer": {
"signer_control_number": "1",
"signature_timestamp": "2023-05-18 00:09:44",
"signature_status": "signed",
"name": "Turing",
"is_group_mandatory": true,
"email": "testemunha@example.com",
"document_number": "58014216296",
"created_at": "2023-05-18 00:02:49"
},
"signed_hash": "z7M0ozYCDGKWjkV4a1U5fK8tl0OcNqJGQXyJmreX16KjvQduv9qFevEc3tWej+1kpXm7jvhUuawSgSA7LJWQ/Flp+TRVyrfOgeBM3Xd+6uJA/c3zA9ASVlaEgwFw8/nD/dXE4EmLVOPhq9Mg3WeIDtq+c93TGhZtvdBpEuGu4q5/wfSTUhYYDPvljbjUvDXEOSTrvYboW1wDJyACCeeYLyPVaqTdOZ9ovXcVOZIpO8+fuIeNKGkuc6m7bXTvE5pD4FSxx5oNPj4N13E4TQN5wcNX+F0svVeVqA+2zrLU2mKGczVsgWO7qte1vct4eREs4dONStPvZ7+JQDSg+OotpQ==",
"signature_timestamp": "2023-05-18 00:09:44",
"signature_status": "signed",
"role": "guarantor",
"created_at": "2023-05-18 00:09:45"
}
]
}
]
}
],
"watcher_clients": [],
"zip_file_keys_list": [
"uuid",
"uuid"
]
}