gograph_routes
List a bounded page of HTTP routes with methods, URL patterns, handlers, and source locations in Go code. Use it to inventory a service or find a route before tracing its call chain.
Instructions
List a deterministic bounded page of HTTP routes with methods, URL patterns, handler names, and source locations. Production routes are returned by default; include_tests=true adds *_test.go registrations. Optional term matches method/path, handler, or file. module selects an exact module path/directory, a unique nested-module directory basename, or the repository directory name for a root module. limit defaults to 100 and is restricted to 1-200; next_cursor continues the same filtered census. Each page is also bounded to 64 KiB so the result stays directly consumable instead of spilling to an out-of-band file. Constant nested Gin/Echo/Fiber Group prefixes and Chi Route closure prefixes are composed; Gin/Fiber use the final variadic argument as the terminal handler, while Echo uses the handler immediately after the path. Dynamically computed prefixes remain unresolved. The MCP server refreshes source analysis before this call. Read-only; no side effects. WHEN TO USE: To inventory one service/module or find a route before gograph_endpoint. NOT TO USE: For a handler's downstream call chain (use gograph_endpoint). RETURNS: gograph.routes.v1 JSON with total, returned, truncated, routes[], and next_cursor when more matches exist.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| term | No | Optional case-insensitive substring matched against method/path, handler, or file | |
| limit | No | Maximum rows in this page, 1-200 (default: 100); the 64 KiB byte budget may return fewer | |
| cursor | No | Opaque next_cursor from the previous gograph_routes result; reuse the same filters | |
| module | No | Optional exact module path/directory, unique nested-module directory basename, or repository directory name for a root module (for example identuum-idp) | |
| include_tests | No | Include routes registered in *_test.go files; false by default |