Working with Large Cases

Our API enforces a maximum payload size limit of 1722 signatures. To efficiently handle large cases requiring aggregation, we recommend adopting our three-step workflow.

This workflow consists of three steps:

Initiate an aggregation task

Begin by initiating a task specifically for aggregation purposes. This step sets the foundation for the subsequent processes.

POST /v1/pqscale/aggsign/task

Headers

Request Body

POST /v1/pqscale/aggsign/task

Headers

Request Body

Response example

{
   "process_id": 12345,
   "url": "https://example.com/12345.json"
}

Upload Task File

Once the aggregation task is initiated and you have acquired the process_id and url from the first step, proceed to upload the task file. Ensure that the file adheres to the format outlined below.

Task file format

[
   {
      "digest": "0x123..abcd",
      "public_key": "0x123..abcd",
      "signature": "0x123..abcd"
   },
   {
      "digest": "0x123..abcd",
      "public_key": "0x123..abcd",
      "signature": "0x123..abcd"
   },
   // ...
   {
      "digest": "0x123..abcd",
      "public_key": "0x123..abcd",
      "signature": "0x123..abcd"
   }
]

Upload task file to the provided URL

You can use curl command to upload such file to the url provided in the response

curl -X PUT -H 'Content-Type: application/json' -d @input.json https://example.com/12345.json

Notify PQScale to start processing the aggregation task

After successfully uploading the task file, inform PQScale to commence processing. This notification triggers the aggregation process, utilizing the data provided in the task file.

POST /v1/pqscale/aggsign/notify/:process_id

Path Parameters

Headers

POST /v1/pqscale/aggsign/notify/:process_id

Path Parameters

Headers

Last updated

Logo

Copyright © 2023 BTQ