> For the complete documentation index, see [llms.txt](https://docs.ironblocks.com/platform/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ironblocks.com/platform/threat-detection/api-and-web-hook/protocols.md). Agents can also search and read this documentation through its [MCP server](https://docs.ironblocks.com/platform/~gitbook/mcp).

# Protocols

### Get all protocols and the assets associated with your api key. <a href="#get-all-protocols-and-the-assets-associated-with-your-api-key" id="get-all-protocols-and-the-assets-associated-with-your-api-key"></a>

`GET` `https://api.ironblocks.com/protocols`

**Query Parameters**

| Name       | Type    | Description                                     |
| ---------- | ------- | ----------------------------------------------- |
| pageNumber | integer | Specify page number for pagination.             |
| hideAssets | boolean | Should the assets be omitted from the response. |
| pageSize   | integer | Specify page size for pagination.               |

200: OK Paginated list of protocols.401: Unauthorized Unauthorized.403: Forbidden Bad api-key.500: Internal Server Error Unexpected error.\[{"page": \[{"protocols": {"protocolId": "600000000000000000000000","descriptor": "dummy","setttings": {"triggers": {"critical": {"detectionsGroup": \[\["detector1","detector2"],\["detector1","detector3"],\["detector3","detector4"]],"actions": \["notification"]}},"notificationChannels": \[],"tracking": true,"detectors": \[{"name": "detector1","config": {"threshold": 250000},"external": false},{"name": "detector2","config": null,"external": falsecurlcurl -X 'GET' \\'<https://api.ironblocks.com/protocols>' \\-H 'accept: application/json' \\-H 'Authorization: Bearer ${YOUR-API-KEY}'

### Create a new protocol and associate it with your api key. <a href="#create-a-new-protocol-and-associate-it-with-your-api-key" id="create-a-new-protocol-and-associate-it-with-your-api-key"></a>

`POST` `https://api.ironblocks.com/protocols/create`

**Request Body**

| Name                 | Type                    | Description                                                                                                                                                                                                  |
| -------------------- | ----------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| protocolName\*       | string                  | The name of your protocol.                                                                                                                                                                                   |
| assets               | Asset\[]                | An array of assets to associate with the protocol. [Type reference](https://app.gitbook.com/o/UGzLTXScYHVJXuC4qsgZ/s/2LTEzda5qKUJkrRUxLah/products/api-and-web-hook/api-reference/protocols#type-reference)​ |
| notificationChannels | NotificationChannels\[] | An array of notification channels for alerts. [Type reference](https://app.gitbook.com/o/UGzLTXScYHVJXuC4qsgZ/s/2LTEzda5qKUJkrRUxLah/products/api-and-web-hook/api-reference/protocols#type-reference)​      |

200: OK Protocol created successfully.401: Unauthorized Unauthorized.403: Forbidden Bad api-key.500: Internal Server Error Unexpected error.{"protocolId": "600000000000000000000000","message": "Protocol created succesfully"}Add assets to a given protocol id.PUT <https://api.ironblocks.com/protocols/assets/addRequest> Body​protocolId\*stringThe protocol Id to add assets to. You can obtain it using the/protocolsendpoint.assets\*Asset\[]An array of assets to associate with the protocol.Type referenceChange protocol's notification channels.PATCH <https://api.ironblocks.com/protocols/notification-channels/replaceRequest> Body​protocolId\*stringThe protocol Id to replace the notification channels for.You can obtain it using the/protocolsendpoint.notificationChannels\*NotificationChannels\[]An array of notification channels for alerts.Type referenceType reference<br>
