Skip to main content

Get Task Details

Retrieves comprehensive details of a specific HDP task, including all metadata, MMRs used, and execution information. This endpoint does not require authentication.

Endpoint

GET /tasks/{task_uuid}/details

Path Parameters

ParameterTypeDescription
task_uuidstringThe unique identifier (UUID) of the task

Example Request

curl -X GET https://staging.hdp.api.herodotus.cloud/tasks/01JPJ03YJT1A93D6NF56G4GVEQ/details \
  -H "Content-Type: application/json"

Response

Success Response (200 OK)

{
  "taskId": "01JPJ03YJT1A93D6NF56G4GVEQ",
  "status": "TaskDecommitmentCompleted",
  "destinationChainId": "11155111",
  "scheduleMode": "onchain",
  "scheduleTxHash": "0xabcd...",
  "dataSourceChains": ["0xaa36a7", "0xaa37dc"],
  "dataDestinationChain": "0xaa36a7",
  "hdpCoreProgramHash": "0x5678...",
  "taskHash": "0x9abc...",
  "programHash": "0xdef0...",
  "programName": "my_module",
  "outputTreeRoot": "0x1234...",
  "outputTreeRootPreimage": ["0x1", "0x2", "0x3"],
  "taskInputs": {
    "param1": "value1"
  },
  "mmrs": [
    {
      "id": "0x30314b345136303433515133424b4d42324e31394d4443595757",
      "root": "0x6e7be7495a7126588df5ce10e090b27ea87357b966cc5b4143d0845ee15af0e",
      "size": "0x2644",
      "chain_id": "0xaa37dc",
      "hashing_function": "poseidon"
    }
  ],
  "createdAt": "2024-03-17T10:24:00Z",
  "updatedAt": "2024-03-17T10:25:00Z"
}

Not Found Response (404)

{
  "error": "Task not found",
  "taskId": "01JPJ03YJT1A93D6NF56G4GVEQ"
}

Response Fields

FieldTypeDescription
taskIdstringThe unique identifier of the task
statusstringCurrent status of the task
destinationChainIdstringChain ID where the task will be proven
scheduleModestring | nullSchedule mode: “onchain” or “offchain”
scheduleTxHashstring | nullTransaction hash if scheduled onchain
dataSourceChainsarray | nullArray of source chain IDs
dataDestinationChainstring | nullDestination chain ID
hdpCoreProgramHashstring | nullHDP core program hash
taskHashstring | nullTask hash
programHashstring | nullProgram hash
programNamestring | nullProgram name
outputTreeRootstring | nullOutput tree root
outputTreeRootPreimagearray | nullOutput tree root preimage
taskInputsobject | nullTask input parameters
mmrsarrayArray of MMR information objects used by the task
createdAtstringISO 8601 timestamp of task creation
updatedAtstringISO 8601 timestamp of last update

MMR Object Fields

FieldTypeDescription
idstringThe MMR identifier (hex string)
rootstringThe MMR root hash (hex string)
sizestringThe size of the MMR (hex string)
chain_idstringThe chain ID where this MMR is located (hex string)
hashing_functionstringThe hashing function used: “poseidon” or “keccak”

Notes

  • No authentication is required for this endpoint
  • This endpoint provides the most comprehensive view of a task
  • MMRs array will be empty if no MMRs were used
  • If task_hash or output_tree_root are not stored in the database, they will be extracted from the task results if available
  • The program_hash will fallback to the HDP core program hash if not specified