Get Hedhog updates in your inbox
New releases, fresh recipes, and breaking changes — no spam.
Core Submodule
route
Manages HTTP/MCP route registry and permission associations.
Source path: libraries/core/src/route
Module file: route.module.ts
Introduction
This page documents the route submodule as part of the Core package. Use it as a quick technical reference for implementation scope, exposed APIs and MCP integration points.
HTTP Endpoints
9 endpoints
List all registered routes with pagination.
- Query
- page, pageSize, search
Get a route by ID.
- Params
- routeId (int)
Register a new route.
Body
| Field | Type | Required | Notes |
|---|---|---|---|
| url | string | no | — |
| method | "GET" | "POST" | "PUT" | "DELETE" | "PATCH" | "OPTIONS" | "HEAD" | no | — |
| type | "HTTP" | "MCP" | no | — |
| tool_name | string | no | MCP tool name when type is MCP |
| name | string | no | — |
Update an existing route.
- Params
- routeId (int)
Body
| Field | Type | Required | Notes |
|---|---|---|---|
| url | string | no | — |
| method | "GET" | "POST" | "PUT" | "DELETE" | "PATCH" | "OPTIONS" | "HEAD" | no | — |
| type | "HTTP" | "MCP" | no | — |
| tool_name | string | no | — |
| name | string | no | — |
Delete one or more routes.
Body
| Field | Type | Required | Notes |
|---|---|---|---|
| ids | number[] | yes | IDs to delete |
List roles that have access to a route.
- Params
- routeId (int)
- Query
- page, pageSize
Replace the role permissions for a route.
- Params
- routeId (int)
Body
| Field | Type | Required | Notes |
|---|---|---|---|
| ids | number[] | yes | Replacement set of IDs |
List screens associated with a route.
- Params
- routeId (int)
- Query
- page, pageSize
Replace the screen associations for a route.
- Params
- routeId (int)
Body
| Field | Type | Required | Notes |
|---|---|---|---|
| ids | number[] | yes | Replacement set of IDs |
MCP Tools
Named tools callable by AI models via the Model Context Protocol (MCP).
core.routes.listList all registered routes with pagination
core.routes.getGet a route by ID
core.routes.createRegister a new HTTP or MCP route
core.routes.updateUpdate an existing route
core.routes.deleteDelete one or more routes
core.routes.roles.listList roles that have access to a route
core.routes.roles.updateReplace the role permissions for a route
core.routes.screens.listList screens associated with a route
core.routes.screens.updateReplace the screen associations for a route