Skip to main content

Decommitment Only

This endpoint allows you to submit a decommitment request for an HDP task when you are running HDP and generating PIE locally. You can optionally provide hdp_output and program_hash, and if not provided, they will be automatically fetched from Atlantic storage using the atlantic_query_id.

Endpoint

Authentication

This endpoint requires authentication using an API key:

Request Body

hdp_output Structure

mmr_metas Array Items

Each item in mmr_metas can be either a Poseidon or Keccak MMR: Poseidon MMR:
Keccak MMR:

Example Requests

With hdp_output and program_hash provided

Without hdp_output and program_hash (fetched from Atlantic)

Response

Success Response (202 Accepted)

Error Responses

400 Bad Request - Program hash mismatch:
400 Bad Request - Invalid payload:
401 Unauthorized:
500 Internal Server Error:

Response Fields

Automatic Fetching from Atlantic

If hdp_output or program_hash are not provided, the service will automatically fetch them from Atlantic storage using the atlantic_query_id. The metadata is fetched from:
The service will:
  1. Fetch the metadata JSON from Atlantic storage
  2. Parse the output array according to the Cairo serialization format
  3. Extract hdp_output and program_hash from the metadata
  4. Validate the program_hash against the local compiled program

Notes

  • The destination_chain_id must be a hex-encoded string starting with 0x
  • If both hdp_output and program_hash are provided, they will be used directly
  • If either is missing, both will be fetched from Atlantic storage
  • The program_hash is validated against the local compiled program to prevent mismatches
  • The task will be queued for decommitment processing
  • Webhook notifications work the same way as the main task creation endpoint