> ## Documentation Index
> Fetch the complete documentation index at: https://docs.trusset.org/llms.txt
> Use this file to discover all available pages before exploring further.

# List Hooks

> List all hooks configured for an external securities lending market

Returns every hook attached to the market, newest first. Hooks cover three stages: scheduled risk monitoring, pre-liquidation checks, and post-liquidation actions.

## Path Parameters

<ParamField path="marketId" type="string" required>Market ID.</ParamField>

## Response Fields

<ResponseField name="data" type="object">
  <Expandable>
    <ResponseField name="hooks" type="array">
      Hook records ordered by `createdAt` descending. Each contains `id`, `marketId`, `hookType`, `name`, `riskUri`, `riskFields`, `riskThreshold`, `checkFrequency`, `parameterChecks`, `triggerHookIds`, `actionType`, `maxBuyPrice`, `webhookUrl`, `webhookPayload`, `signerAddress`, `active`, `lastResult`, `lastExecutedAt`, `executionCount`, and `createdAt`.
    </ResponseField>
  </Expandable>
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl "https://api.trusset.org/lending-external-securities/api/hooks/{marketId}" \
    -H "X-API-Key: trusset_your_key_here"
  ```

  ```typescript TypeScript theme={null}
  const res = await fetch(
    `https://api.trusset.org/lending-external-securities/api/hooks/${marketId}`,
    { headers: { 'X-API-Key': 'trusset_your_key_here' } }
  );
  const { data } = await res.json();
  ```
</RequestExample>

<ResponseExample>
  ```json Response theme={null}
  {
    "success": true,
    "data": {
      "hooks": [
        {
          "id": "hook_001",
          "marketId": "clx_secmarket_001",
          "hookType": "monitorRisk",
          "name": "NAV Publication Monitor",
          "riskUri": "https://nav.example.com/funds/NYF1",
          "riskFields": [{ "path": "ageHours", "operator": "<", "threshold": 36 }],
          "checkFrequency": "6h",
          "parameterChecks": [],
          "triggerHookIds": [],
          "actionType": null,
          "webhookUrl": null,
          "signerAddress": "0x123...456",
          "active": true,
          "lastResult": true,
          "lastExecutedAt": "2025-06-15T06:00:00.000Z",
          "executionCount": 142,
          "createdAt": "2025-06-01T09:00:00.000Z"
        }
      ]
    },
    "metadata": {
      "timestamp": "2025-06-15T12:00:00.000Z",
      "requestId": "a1b2c3d4-...",
      "instanceId": "inst_abc123"
    }
  }
  ```
</ResponseExample>
