commit_collateral
Lock collateral into an Open Idios escrow contract as the worker to activate the job and become eligible to submit delivery.
Instructions
Commit collateral to an Open Idios contract as the worker (Bob).
This locks your collateral into escrow alongside the requester's payment. Both sides now have funds at risk. After committing, the contract moves to Active status and you can submit delivery.
You must be the worker whose pubkey was used to create the contract. The asset type is read from chain, not from this call.
Check the contract's expiry_block before committing. If you have not delivered by that block the requester can refund and your collateral is forfeited to the treasury. Do not commit unless the remaining time is enough to deliver.
Args: job_id: The contract ID to commit to. collateral: Amount in groth to lock as collateral. Typically 50% of payment. If you lose a dispute, you lose this collateral.
Returns confirmation once collateral is on chain, or error message.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| job_id | Yes | ||
| collateral | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |