Sample callback server
Cobo provides example callback server implementations in multiple programming languages to help you quickly develop your callback server. You can find these examples in our GitHub repository.How it works
After startup, the TSS Node establishes a persistent connection with the Cobo WaaS service to receive task requests. These tasks fall into three categories:- Key generation (KeyGen): Creating new key shares for your MPC Wallets.
- Key signing (KeySign): Signing transactions or messages.
- Key resharing (KeyReshare): Redistributing key shares among participants.
Callback request types
Each callback request carries arequest_type field that identifies the operation the TSS Node asks your callback server to approve.
For the full payload schema of each request type, and for the HTTP response your callback server must return, see Callback request and response formats.
These callback
request_type values are sent by the TSS Node to your callback server for approval. They are distinct from Cobo webhook event types (such as wallets.transaction.* and wallets.mpc.tss_request.*), which the WaaS service sends to notify your application of status changes. For webhook event types, see Webhook event types.Communication security
The TSS Node and callback server communicate via HTTP, using JSON Web Token (JWT) with RS256 signing algorithm to ensure secure data transmission. This involves:- Key generation: Both the TSS Node and callback server generate their own RSA key pairs.
- Key exchange: Each component configures the otherโs RSA public key in their system.
- Request signing: All requests are signed using the senderโs private key.
- Signature verification: Recipients verify signatures using the senderโs public key.
Implementation steps
To implement the callback mechanism:- Deploy your TSS Node callback server.
- Configure callback keys.
- Start both the TSS Node and callback server.
