Skip to content

Commit a216e5f

Browse files
leggetterclaude
andcommitted
docs(gateway): drop the notes that include carries x-docs-hide
The API now documents include on GET /events, GET /requests and GET /requests/{id}/events, so the comments that called it a hidden parameter are out of date. The body_format notes stay: that field is still hidden in the spec. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 parent 7b0ce49 commit a216e5f

3 files changed

Lines changed: 10 additions & 13 deletions

File tree

‎pkg/cmd/gateway_list_filters_test.go‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,8 +138,8 @@ func TestListFiltersAreOmittedWhenUnset(t *testing.T) {
138138
// intentional. The MCP side is pinned by
139139
// TestPluralToolsOmitParametersHiddenFromTheAPIDocs.
140140
//
141-
// include is the exception. It carries x-docs-hide too, but Hookdeck's API team
142-
// has confirmed it can be exposed; see TestListIncludeData.
141+
// include is not in this list: the API documents it on these endpoints, and
142+
// the CLI offers it as --include; see TestListIncludeData.
143143
func TestListCommandsOmitFlagsHiddenFromTheAPIDocs(t *testing.T) {
144144
root := &cobra.Command{Use: "hookdeck"}
145145
root.AddCommand(newGatewayCmd().cmd)

‎pkg/gateway/mcp/server_test.go‎

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -345,10 +345,9 @@ func TestReadOnlyModeHidesWriteOnlyPropsAndProse(t *testing.T) {
345345
// like filters we simply forgot, which is exactly how they would get added —
346346
// this pins the omission as intentional.
347347
//
348-
// include is the exception. It carries x-docs-hide too, but Hookdeck's API
349-
// team has confirmed it can be exposed, and without it an agent that needs
350-
// payloads fetches every event by ID, one call each. It is pinned the other
351-
// way round by TestListToolsOfferIncludeData.
348+
// include is not in this list: the API documents it on these endpoints, and
349+
// without it an agent that needs payloads fetches every event by ID, one call
350+
// each. It is pinned the other way round by TestListToolsOfferIncludeData.
352351
func TestPluralToolsOmitParametersHiddenFromTheAPIDocs(t *testing.T) {
353352
session := connectInMemory(t, newTestClient("https://api.hookdeck.com", "test-key"))
354353
tools := listTools(t, session)

‎pkg/gateway/mcp/tools.go‎

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -170,13 +170,11 @@ const (
170170

171171
// descIncludeData describes include on the events and requests list tools.
172172
//
173-
// The API declares include on GET /events, GET /requests and
174-
// GET /requests/{id}/events. It carries x-docs-hide, which is why the MCP
175-
// omitted it until now. Hookdeck's API team has since confirmed it can be
176-
// documented and exposed, with the caveat that it can return a lot of data.
177-
// Without it, an agent that needs payloads has to fetch each event by ID, one
178-
// call per event, and a fast agent can hit the rate limit doing so. The size
179-
// warning is that caveat, stated where the agent chooses the argument.
173+
// The API documents include on GET /events, GET /requests and
174+
// GET /requests/{id}/events. It can return a lot of data, so the description
175+
// warns about size where the agent chooses the argument. Without it, an agent
176+
// that needs payloads has to fetch each event by ID, one call per event, and
177+
// a fast agent can hit the rate limit doing so.
180178
func descIncludeData(resource, singularTool string) string {
181179
return "Set to \"data\" to return each " + resource + "'s payload (headers, body, path, parsed_query) as a data object on every result, " +
182180
"instead of fetching each one with " + singularTool + ". " +

0 commit comments

Comments
 (0)