@cyanheads/brapi-mcp-server 0.7.12 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (151) hide show
  1. package/AGENTS.md +460 -0
  2. package/CLAUDE.md +21 -8
  3. package/README.md +467 -184
  4. package/changelog/0.7.x/0.7.13.md +38 -0
  5. package/changelog/0.8.x/0.8.0.md +48 -0
  6. package/changelog/template.md +7 -7
  7. package/dist/config/alias-credentials.d.ts +28 -7
  8. package/dist/config/alias-credentials.d.ts.map +1 -1
  9. package/dist/config/alias-credentials.js +91 -24
  10. package/dist/config/alias-credentials.js.map +1 -1
  11. package/dist/config/builtin-aliases.d.ts +11 -6
  12. package/dist/config/builtin-aliases.d.ts.map +1 -1
  13. package/dist/config/builtin-aliases.js +23 -37
  14. package/dist/config/builtin-aliases.js.map +1 -1
  15. package/dist/index.js +8 -1
  16. package/dist/index.js.map +1 -1
  17. package/dist/mcp-server/resources/definitions/brapi-calls.resource.d.ts +1 -0
  18. package/dist/mcp-server/resources/definitions/brapi-calls.resource.d.ts.map +1 -1
  19. package/dist/mcp-server/resources/definitions/brapi-calls.resource.js +1 -0
  20. package/dist/mcp-server/resources/definitions/brapi-calls.resource.js.map +1 -1
  21. package/dist/mcp-server/resources/definitions/brapi-germplasm.resource.d.ts +1 -0
  22. package/dist/mcp-server/resources/definitions/brapi-germplasm.resource.d.ts.map +1 -1
  23. package/dist/mcp-server/resources/definitions/brapi-germplasm.resource.js +1 -0
  24. package/dist/mcp-server/resources/definitions/brapi-germplasm.resource.js.map +1 -1
  25. package/dist/mcp-server/resources/definitions/brapi-server-info.resource.d.ts +1 -0
  26. package/dist/mcp-server/resources/definitions/brapi-server-info.resource.d.ts.map +1 -1
  27. package/dist/mcp-server/resources/definitions/brapi-server-info.resource.js +2 -1
  28. package/dist/mcp-server/resources/definitions/brapi-server-info.resource.js.map +1 -1
  29. package/dist/mcp-server/resources/definitions/brapi-study.resource.d.ts +1 -0
  30. package/dist/mcp-server/resources/definitions/brapi-study.resource.d.ts.map +1 -1
  31. package/dist/mcp-server/resources/definitions/brapi-study.resource.js +1 -0
  32. package/dist/mcp-server/resources/definitions/brapi-study.resource.js.map +1 -1
  33. package/dist/mcp-server/resources/definitions/brapi-variable.resource.d.ts +1 -0
  34. package/dist/mcp-server/resources/definitions/brapi-variable.resource.d.ts.map +1 -1
  35. package/dist/mcp-server/resources/definitions/brapi-variable.resource.js +1 -0
  36. package/dist/mcp-server/resources/definitions/brapi-variable.resource.js.map +1 -1
  37. package/dist/mcp-server/tools/definitions/brapi-build-phenotype-matrix.tool.d.ts +2 -0
  38. package/dist/mcp-server/tools/definitions/brapi-build-phenotype-matrix.tool.d.ts.map +1 -1
  39. package/dist/mcp-server/tools/definitions/brapi-build-phenotype-matrix.tool.js +2 -0
  40. package/dist/mcp-server/tools/definitions/brapi-build-phenotype-matrix.tool.js.map +1 -1
  41. package/dist/mcp-server/tools/definitions/brapi-connect.tool.d.ts +46 -0
  42. package/dist/mcp-server/tools/definitions/brapi-connect.tool.d.ts.map +1 -1
  43. package/dist/mcp-server/tools/definitions/brapi-connect.tool.js +65 -15
  44. package/dist/mcp-server/tools/definitions/brapi-connect.tool.js.map +1 -1
  45. package/dist/mcp-server/tools/definitions/brapi-dataframe-export.tool.d.ts +1 -0
  46. package/dist/mcp-server/tools/definitions/brapi-dataframe-export.tool.d.ts.map +1 -1
  47. package/dist/mcp-server/tools/definitions/brapi-dataframe-export.tool.js +1 -0
  48. package/dist/mcp-server/tools/definitions/brapi-dataframe-export.tool.js.map +1 -1
  49. package/dist/mcp-server/tools/definitions/brapi-describe-filters.tool.d.ts.map +1 -1
  50. package/dist/mcp-server/tools/definitions/brapi-describe-filters.tool.js +7 -2
  51. package/dist/mcp-server/tools/definitions/brapi-describe-filters.tool.js.map +1 -1
  52. package/dist/mcp-server/tools/definitions/brapi-export-genotype-matrix.tool.d.ts +1 -0
  53. package/dist/mcp-server/tools/definitions/brapi-export-genotype-matrix.tool.d.ts.map +1 -1
  54. package/dist/mcp-server/tools/definitions/brapi-export-genotype-matrix.tool.js +1 -0
  55. package/dist/mcp-server/tools/definitions/brapi-export-genotype-matrix.tool.js.map +1 -1
  56. package/dist/mcp-server/tools/definitions/brapi-find-genotype-calls.tool.d.ts +1 -0
  57. package/dist/mcp-server/tools/definitions/brapi-find-genotype-calls.tool.d.ts.map +1 -1
  58. package/dist/mcp-server/tools/definitions/brapi-find-genotype-calls.tool.js +1 -0
  59. package/dist/mcp-server/tools/definitions/brapi-find-genotype-calls.tool.js.map +1 -1
  60. package/dist/mcp-server/tools/definitions/brapi-find-germplasm.tool.d.ts +2 -0
  61. package/dist/mcp-server/tools/definitions/brapi-find-germplasm.tool.d.ts.map +1 -1
  62. package/dist/mcp-server/tools/definitions/brapi-find-germplasm.tool.js +2 -0
  63. package/dist/mcp-server/tools/definitions/brapi-find-germplasm.tool.js.map +1 -1
  64. package/dist/mcp-server/tools/definitions/brapi-find-images.tool.d.ts +2 -0
  65. package/dist/mcp-server/tools/definitions/brapi-find-images.tool.d.ts.map +1 -1
  66. package/dist/mcp-server/tools/definitions/brapi-find-images.tool.js +2 -0
  67. package/dist/mcp-server/tools/definitions/brapi-find-images.tool.js.map +1 -1
  68. package/dist/mcp-server/tools/definitions/brapi-find-locations.tool.d.ts +2 -0
  69. package/dist/mcp-server/tools/definitions/brapi-find-locations.tool.d.ts.map +1 -1
  70. package/dist/mcp-server/tools/definitions/brapi-find-locations.tool.js +2 -0
  71. package/dist/mcp-server/tools/definitions/brapi-find-locations.tool.js.map +1 -1
  72. package/dist/mcp-server/tools/definitions/brapi-find-observations.tool.d.ts +2 -0
  73. package/dist/mcp-server/tools/definitions/brapi-find-observations.tool.d.ts.map +1 -1
  74. package/dist/mcp-server/tools/definitions/brapi-find-observations.tool.js +2 -0
  75. package/dist/mcp-server/tools/definitions/brapi-find-observations.tool.js.map +1 -1
  76. package/dist/mcp-server/tools/definitions/brapi-find-studies.tool.d.ts +2 -0
  77. package/dist/mcp-server/tools/definitions/brapi-find-studies.tool.d.ts.map +1 -1
  78. package/dist/mcp-server/tools/definitions/brapi-find-studies.tool.js +2 -0
  79. package/dist/mcp-server/tools/definitions/brapi-find-studies.tool.js.map +1 -1
  80. package/dist/mcp-server/tools/definitions/brapi-find-variables.tool.d.ts +2 -0
  81. package/dist/mcp-server/tools/definitions/brapi-find-variables.tool.d.ts.map +1 -1
  82. package/dist/mcp-server/tools/definitions/brapi-find-variables.tool.js +2 -0
  83. package/dist/mcp-server/tools/definitions/brapi-find-variables.tool.js.map +1 -1
  84. package/dist/mcp-server/tools/definitions/brapi-find-variants.tool.d.ts +2 -0
  85. package/dist/mcp-server/tools/definitions/brapi-find-variants.tool.d.ts.map +1 -1
  86. package/dist/mcp-server/tools/definitions/brapi-find-variants.tool.js +2 -0
  87. package/dist/mcp-server/tools/definitions/brapi-find-variants.tool.js.map +1 -1
  88. package/dist/mcp-server/tools/definitions/brapi-germplasm-performance.tool.d.ts +1 -0
  89. package/dist/mcp-server/tools/definitions/brapi-germplasm-performance.tool.d.ts.map +1 -1
  90. package/dist/mcp-server/tools/definitions/brapi-germplasm-performance.tool.js +1 -0
  91. package/dist/mcp-server/tools/definitions/brapi-germplasm-performance.tool.js.map +1 -1
  92. package/dist/mcp-server/tools/definitions/brapi-get-germplasm.tool.d.ts +1 -0
  93. package/dist/mcp-server/tools/definitions/brapi-get-germplasm.tool.d.ts.map +1 -1
  94. package/dist/mcp-server/tools/definitions/brapi-get-germplasm.tool.js +1 -0
  95. package/dist/mcp-server/tools/definitions/brapi-get-germplasm.tool.js.map +1 -1
  96. package/dist/mcp-server/tools/definitions/brapi-get-image.tool.d.ts +1 -0
  97. package/dist/mcp-server/tools/definitions/brapi-get-image.tool.d.ts.map +1 -1
  98. package/dist/mcp-server/tools/definitions/brapi-get-image.tool.js +1 -0
  99. package/dist/mcp-server/tools/definitions/brapi-get-image.tool.js.map +1 -1
  100. package/dist/mcp-server/tools/definitions/brapi-get-study.tool.d.ts +1 -0
  101. package/dist/mcp-server/tools/definitions/brapi-get-study.tool.d.ts.map +1 -1
  102. package/dist/mcp-server/tools/definitions/brapi-get-study.tool.js +1 -0
  103. package/dist/mcp-server/tools/definitions/brapi-get-study.tool.js.map +1 -1
  104. package/dist/mcp-server/tools/definitions/brapi-raw-get.tool.d.ts +1 -0
  105. package/dist/mcp-server/tools/definitions/brapi-raw-get.tool.d.ts.map +1 -1
  106. package/dist/mcp-server/tools/definitions/brapi-raw-get.tool.js +1 -0
  107. package/dist/mcp-server/tools/definitions/brapi-raw-get.tool.js.map +1 -1
  108. package/dist/mcp-server/tools/definitions/brapi-raw-search.tool.d.ts +1 -0
  109. package/dist/mcp-server/tools/definitions/brapi-raw-search.tool.d.ts.map +1 -1
  110. package/dist/mcp-server/tools/definitions/brapi-raw-search.tool.js +1 -0
  111. package/dist/mcp-server/tools/definitions/brapi-raw-search.tool.js.map +1 -1
  112. package/dist/mcp-server/tools/definitions/brapi-server-info.tool.d.ts +13 -0
  113. package/dist/mcp-server/tools/definitions/brapi-server-info.tool.d.ts.map +1 -1
  114. package/dist/mcp-server/tools/definitions/brapi-server-info.tool.js +2 -1
  115. package/dist/mcp-server/tools/definitions/brapi-server-info.tool.js.map +1 -1
  116. package/dist/mcp-server/tools/definitions/brapi-submit-observations.tool.d.ts +1 -0
  117. package/dist/mcp-server/tools/definitions/brapi-submit-observations.tool.d.ts.map +1 -1
  118. package/dist/mcp-server/tools/definitions/brapi-submit-observations.tool.js +1 -0
  119. package/dist/mcp-server/tools/definitions/brapi-submit-observations.tool.js.map +1 -1
  120. package/dist/mcp-server/tools/definitions/brapi-walk-pedigree.tool.d.ts +1 -0
  121. package/dist/mcp-server/tools/definitions/brapi-walk-pedigree.tool.d.ts.map +1 -1
  122. package/dist/mcp-server/tools/definitions/brapi-walk-pedigree.tool.js +1 -0
  123. package/dist/mcp-server/tools/definitions/brapi-walk-pedigree.tool.js.map +1 -1
  124. package/dist/mcp-server/tools/definitions/index.d.ts +151 -65
  125. package/dist/mcp-server/tools/definitions/index.d.ts.map +1 -1
  126. package/dist/mcp-server/tools/shared/find-helpers.d.ts +6 -0
  127. package/dist/mcp-server/tools/shared/find-helpers.d.ts.map +1 -1
  128. package/dist/mcp-server/tools/shared/find-helpers.js +17 -5
  129. package/dist/mcp-server/tools/shared/find-helpers.js.map +1 -1
  130. package/dist/mcp-server/tools/shared/orientation-envelope.d.ts +26 -0
  131. package/dist/mcp-server/tools/shared/orientation-envelope.d.ts.map +1 -1
  132. package/dist/mcp-server/tools/shared/orientation-envelope.js +75 -6
  133. package/dist/mcp-server/tools/shared/orientation-envelope.js.map +1 -1
  134. package/dist/services/brapi-client/brapi-client.d.ts +7 -0
  135. package/dist/services/brapi-client/brapi-client.d.ts.map +1 -1
  136. package/dist/services/brapi-client/brapi-client.js +45 -33
  137. package/dist/services/brapi-client/brapi-client.js.map +1 -1
  138. package/dist/services/capability-registry/capability-registry.d.ts +8 -1
  139. package/dist/services/capability-registry/capability-registry.d.ts.map +1 -1
  140. package/dist/services/capability-registry/capability-registry.js +37 -6
  141. package/dist/services/capability-registry/capability-registry.js.map +1 -1
  142. package/dist/services/reference-data-cache/reference-data-cache.d.ts.map +1 -1
  143. package/dist/services/reference-data-cache/reference-data-cache.js +9 -4
  144. package/dist/services/reference-data-cache/reference-data-cache.js.map +1 -1
  145. package/dist/services/server-registry/server-registry.d.ts +17 -3
  146. package/dist/services/server-registry/server-registry.d.ts.map +1 -1
  147. package/dist/services/server-registry/server-registry.js +30 -4
  148. package/dist/services/server-registry/server-registry.js.map +1 -1
  149. package/manifest.json +1 -1
  150. package/package.json +19 -8
  151. package/server.json +9 -3
@@ -107,12 +107,81 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
107
107
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
108
108
  readonly when: 'No connection has been registered under the requested alias';
109
109
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_get_study.';
110
+ readonly thrownBy: 'service';
110
111
  }, {
111
112
  readonly reason: 'study_not_found';
112
113
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
113
114
  readonly when: 'Upstream returned no study record for the requested DbId';
114
115
  readonly recovery: 'Verify the studyDbId on the target server, or run brapi_find_studies to discover valid IDs.';
115
116
  }], undefined> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
117
+ alias: import("zod").ZodOptional<import("zod").ZodString>;
118
+ studies: import("zod").ZodArray<import("zod").ZodString>;
119
+ variables: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
120
+ germplasm: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
121
+ shape: import("zod").ZodDefault<import("zod").ZodEnum<{
122
+ long: "long";
123
+ wide: "wide";
124
+ }>>;
125
+ aggregate: import("zod").ZodDefault<import("zod").ZodEnum<{
126
+ all: "all";
127
+ first: "first";
128
+ mean: "mean";
129
+ median: "median";
130
+ }>>;
131
+ loadLimit: import("zod").ZodOptional<import("zod").ZodNumber>;
132
+ extraFilters: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnknown>>;
133
+ }, import("zod/v4/core").$strip>, import("zod").ZodObject<{
134
+ alias: import("zod").ZodString;
135
+ studies: import("zod").ZodArray<import("zod").ZodString>;
136
+ shape: import("zod").ZodEnum<{
137
+ long: "long";
138
+ wide: "wide";
139
+ }>;
140
+ aggregate: import("zod").ZodEnum<{
141
+ all: "all";
142
+ first: "first";
143
+ mean: "mean";
144
+ median: "median";
145
+ }>;
146
+ observationCount: import("zod").ZodNumber;
147
+ germplasmCount: import("zod").ZodNumber;
148
+ variableCount: import("zod").ZodNumber;
149
+ variableLegend: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>;
150
+ dataframe: import("zod").ZodOptional<import("zod").ZodObject<{
151
+ tableName: import("zod").ZodString;
152
+ rowCount: import("zod").ZodNumber;
153
+ columns: import("zod").ZodArray<import("zod").ZodString>;
154
+ columnLegend: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
155
+ createdAt: import("zod").ZodString;
156
+ expiresAt: import("zod").ZodString;
157
+ truncated: import("zod").ZodOptional<import("zod").ZodBoolean>;
158
+ maxRows: import("zod").ZodOptional<import("zod").ZodNumber>;
159
+ totalCount: import("zod").ZodOptional<import("zod").ZodNumber>;
160
+ }, import("zod/v4/core").$strip>>;
161
+ warnings: import("zod").ZodArray<import("zod").ZodString>;
162
+ }, import("zod/v4/core").$strip>, readonly [{
163
+ readonly reason: 'unknown_alias';
164
+ readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
165
+ readonly when: 'No connection has been registered under the requested alias';
166
+ readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_build_phenotype_matrix.';
167
+ readonly thrownBy: 'service';
168
+ }, {
169
+ readonly reason: 'all_filters_dropped';
170
+ readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
171
+ readonly when: 'The active dialect dropped every filter supplied — the call would silently widen to the unfiltered baseline';
172
+ readonly recovery: 'Drop unsupported filters or use studies / germplasm / variables to scope the query to supported filter paths on the active dialect.';
173
+ readonly thrownBy: 'service';
174
+ }, {
175
+ readonly reason: 'no_observation_path';
176
+ readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ServiceUnavailable;
177
+ readonly when: 'Neither /observations nor /observationunits returned data for any requested study after probing both paths';
178
+ readonly recovery: 'Verify the studyDbIds exist and the BrAPI server exposes /observations or /observationunits. Use brapi_server_info to inspect the capability list.';
179
+ }], {
180
+ readonly truncated: import("zod").ZodOptional<import("zod").ZodBoolean>;
181
+ readonly shown: import("zod").ZodOptional<import("zod").ZodNumber>;
182
+ readonly cap: import("zod").ZodOptional<import("zod").ZodNumber>;
183
+ readonly notice: import("zod").ZodOptional<import("zod").ZodString>;
184
+ }> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
116
185
  alias: import("zod").ZodOptional<import("zod").ZodString>;
117
186
  germplasmDbIds: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
118
187
  variantSetDbId: import("zod").ZodString;
@@ -160,6 +229,7 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
160
229
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
161
230
  readonly when: 'No connection has been registered under the requested alias';
162
231
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_export_genotype_matrix.';
232
+ readonly thrownBy: 'service';
163
233
  }, {
164
234
  readonly reason: 'no_filters';
165
235
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
@@ -228,11 +298,13 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
228
298
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
229
299
  readonly when: 'No connection has been registered under the requested alias';
230
300
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_find_locations.';
301
+ readonly thrownBy: 'service';
231
302
  }, {
232
303
  readonly reason: 'all_filters_dropped';
233
304
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
234
305
  readonly when: 'The active dialect dropped every filter the agent supplied — the upstream server does not honor any of the requested scope filters on this endpoint, so the call would silently widen to the unfiltered baseline.';
235
306
  readonly recovery: 'Drop the unsupported filters and rescope by locations, locationNames, countryCodes, locationTypes, abbreviations, or bbox — these filter paths are honored on the active dialect.';
307
+ readonly thrownBy: 'service';
236
308
  }], {
237
309
  readonly totalCount: import("zod").ZodNumber;
238
310
  readonly returnedCount: import("zod").ZodNumber;
@@ -289,11 +361,13 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
289
361
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
290
362
  readonly when: 'No connection has been registered under the requested alias';
291
363
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_find_variants.';
364
+ readonly thrownBy: 'service';
292
365
  }, {
293
366
  readonly reason: 'all_filters_dropped';
294
367
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
295
368
  readonly when: 'The active dialect dropped every filter the agent supplied — the upstream server does not honor any of the requested scope filters on this endpoint, so the call would silently widen to the unfiltered baseline.';
296
369
  readonly recovery: 'Drop the unsupported filters and rescope by variants, variantSets, references, or referenceName + start/end — these filter paths are honored on the active dialect.';
370
+ readonly thrownBy: 'service';
297
371
  }], {
298
372
  readonly totalCount: import("zod").ZodNumber;
299
373
  readonly returnedCount: import("zod").ZodNumber;
@@ -336,6 +410,7 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
336
410
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
337
411
  readonly when: 'No connection has been registered under the requested alias';
338
412
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_raw_get.';
413
+ readonly thrownBy: 'service';
339
414
  }, {
340
415
  readonly reason: 'cross_origin_path';
341
416
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
@@ -419,85 +494,65 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
419
494
  citation: import("zod").ZodString;
420
495
  isDemo: import("zod").ZodOptional<import("zod").ZodBoolean>;
421
496
  }, import("zod/v4/core").$strip>>;
497
+ nextToolSuggestions: import("zod").ZodArray<import("zod").ZodObject<{
498
+ toolName: import("zod").ZodEnum<{
499
+ brapi_find_germplasm: "brapi_find_germplasm";
500
+ brapi_find_locations: "brapi_find_locations";
501
+ brapi_find_studies: "brapi_find_studies";
502
+ brapi_find_variables: "brapi_find_variables";
503
+ }>;
504
+ reason: import("zod").ZodString;
505
+ args: import("zod").ZodObject<{
506
+ alias: import("zod").ZodString;
507
+ }, import("zod/v4/core").$strip>;
508
+ }, import("zod/v4/core").$strip>>;
422
509
  notes: import("zod").ZodArray<import("zod").ZodString>;
423
510
  fetchedAt: import("zod").ZodString;
424
511
  }, import("zod/v4/core").$strip>, readonly [{
512
+ readonly reason: 'auth_session_required';
513
+ readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.Forbidden;
514
+ readonly when: 'Caller-supplied credentials on an HTTP deployment without per-user auth, from a request that carries no MCP session';
515
+ readonly recovery: 'Connect from a client that keeps an MCP session (2025-era Streamable HTTP) or over stdio, use a deployment with MCP_AUTH_MODE=jwt or oauth, or omit `auth` to use server-configured credentials or none.';
516
+ readonly retryable: false;
517
+ }, {
518
+ readonly reason: 'auth_base_url_mismatch';
519
+ readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.Forbidden;
520
+ readonly when: 'The alias has server-configured credentials and the supplied baseUrl differs from the server configured for it';
521
+ readonly recovery: "Omit `baseUrl` to connect to the server configured for this alias, or register the other server under a different alias.";
522
+ readonly retryable: false;
523
+ readonly thrownBy: 'service';
524
+ }, {
525
+ readonly reason: 'alias_base_url_unset';
526
+ readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ConfigurationError;
527
+ readonly when: 'The alias has server-configured credentials but no base URL of its own (no BRAPI_<ALIAS>_BASE_URL and no enabled built-in), so they pair with no server';
528
+ readonly recovery: 'Set BRAPI_<ALIAS>_BASE_URL on the server for this alias, or remove its credential variables, before retrying.';
529
+ readonly retryable: false;
530
+ readonly thrownBy: 'service';
531
+ }, {
425
532
  readonly reason: 'auth_token_exchange_failed';
426
533
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.Forbidden;
427
534
  readonly when: 'SGN or OAuth token exchange against the BrAPI /token endpoint failed';
428
535
  readonly recovery: 'Verify the credentials and that the server exposes /token before retrying.';
536
+ readonly thrownBy: 'service';
429
537
  }, {
430
538
  readonly reason: 'auth_no_access_token';
431
539
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.Forbidden;
432
540
  readonly when: 'Token endpoint responded but did not return an access_token';
433
541
  readonly recovery: 'Confirm the credentials are valid and the upstream IdP issues access tokens for this grant.';
434
- }], undefined> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
435
- alias: import("zod").ZodOptional<import("zod").ZodString>;
436
- studies: import("zod").ZodArray<import("zod").ZodString>;
437
- variables: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
438
- germplasm: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
439
- shape: import("zod").ZodDefault<import("zod").ZodEnum<{
440
- long: "long";
441
- wide: "wide";
442
- }>>;
443
- aggregate: import("zod").ZodDefault<import("zod").ZodEnum<{
444
- all: "all";
445
- first: "first";
446
- mean: "mean";
447
- median: "median";
448
- }>>;
449
- loadLimit: import("zod").ZodOptional<import("zod").ZodNumber>;
450
- extraFilters: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnknown>>;
451
- }, import("zod/v4/core").$strip>, import("zod").ZodObject<{
452
- alias: import("zod").ZodString;
453
- studies: import("zod").ZodArray<import("zod").ZodString>;
454
- shape: import("zod").ZodEnum<{
455
- long: "long";
456
- wide: "wide";
457
- }>;
458
- aggregate: import("zod").ZodEnum<{
459
- all: "all";
460
- first: "first";
461
- mean: "mean";
462
- median: "median";
463
- }>;
464
- observationCount: import("zod").ZodNumber;
465
- germplasmCount: import("zod").ZodNumber;
466
- variableCount: import("zod").ZodNumber;
467
- variableLegend: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>;
468
- dataframe: import("zod").ZodOptional<import("zod").ZodObject<{
469
- tableName: import("zod").ZodString;
470
- rowCount: import("zod").ZodNumber;
471
- columns: import("zod").ZodArray<import("zod").ZodString>;
472
- columnLegend: import("zod").ZodOptional<import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>>;
473
- createdAt: import("zod").ZodString;
474
- expiresAt: import("zod").ZodString;
475
- truncated: import("zod").ZodOptional<import("zod").ZodBoolean>;
476
- maxRows: import("zod").ZodOptional<import("zod").ZodNumber>;
477
- totalCount: import("zod").ZodOptional<import("zod").ZodNumber>;
478
- }, import("zod/v4/core").$strip>>;
479
- warnings: import("zod").ZodArray<import("zod").ZodString>;
480
- }, import("zod/v4/core").$strip>, readonly [{
481
- readonly reason: 'unknown_alias';
482
- readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
483
- readonly when: 'No connection has been registered under the requested alias';
484
- readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_build_phenotype_matrix.';
542
+ readonly thrownBy: 'service';
485
543
  }, {
486
- readonly reason: 'all_filters_dropped';
487
- readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
488
- readonly when: 'The active dialect dropped every filter supplied — the call would silently widen to the unfiltered baseline';
489
- readonly recovery: 'Drop unsupported filters or use studies / germplasm / variables to scope the query to supported filter paths on the active dialect.';
544
+ readonly reason: 'upstream_unauthorized';
545
+ readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.Unauthorized;
546
+ readonly when: 'The server answered HTTP 401 on /serverinfo or /calls — it requires login for capability discovery';
547
+ readonly recovery: 'Retry brapi_connect with credentials in `auth` (sgn, bearer, api_key, or oauth2), or ask the operator to configure credentials for this alias server-side.';
548
+ readonly thrownBy: 'service';
490
549
  }, {
491
- readonly reason: 'no_observation_path';
492
- readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ServiceUnavailable;
493
- readonly when: 'Neither /observations nor /observationunits returned data for any requested study after probing both paths';
494
- readonly recovery: 'Verify the studyDbIds exist and the BrAPI server exposes /observations or /observationunits. Use brapi_server_info to inspect the capability list.';
495
- }], {
496
- readonly truncated: import("zod").ZodOptional<import("zod").ZodBoolean>;
497
- readonly shown: import("zod").ZodOptional<import("zod").ZodNumber>;
498
- readonly cap: import("zod").ZodOptional<import("zod").ZodNumber>;
499
- readonly notice: import("zod").ZodOptional<import("zod").ZodString>;
500
- }> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
550
+ readonly reason: 'upstream_forbidden';
551
+ readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.Forbidden;
552
+ readonly when: 'The server answered HTTP 403 on /serverinfo or /calls — the request (anonymous or credentialed) lacks read access';
553
+ readonly recovery: 'Retry brapi_connect with credentials that have read access to this server, or ask the operator to configure such credentials for this alias server-side.';
554
+ readonly thrownBy: 'service';
555
+ }], undefined> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
501
556
  alias: import("zod").ZodOptional<import("zod").ZodString>;
502
557
  forceRefresh: import("zod").ZodDefault<import("zod").ZodBoolean>;
503
558
  }, import("zod/v4/core").$strip>, import("zod").ZodObject<{
@@ -556,6 +611,18 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
556
611
  citation: import("zod").ZodString;
557
612
  isDemo: import("zod").ZodOptional<import("zod").ZodBoolean>;
558
613
  }, import("zod/v4/core").$strip>>;
614
+ nextToolSuggestions: import("zod").ZodArray<import("zod").ZodObject<{
615
+ toolName: import("zod").ZodEnum<{
616
+ brapi_find_germplasm: "brapi_find_germplasm";
617
+ brapi_find_locations: "brapi_find_locations";
618
+ brapi_find_studies: "brapi_find_studies";
619
+ brapi_find_variables: "brapi_find_variables";
620
+ }>;
621
+ reason: import("zod").ZodString;
622
+ args: import("zod").ZodObject<{
623
+ alias: import("zod").ZodString;
624
+ }, import("zod/v4/core").$strip>;
625
+ }, import("zod/v4/core").$strip>>;
559
626
  notes: import("zod").ZodArray<import("zod").ZodString>;
560
627
  fetchedAt: import("zod").ZodString;
561
628
  }, import("zod/v4/core").$strip>, readonly [{
@@ -563,6 +630,7 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
563
630
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
564
631
  readonly when: 'No connection has been registered under the requested alias';
565
632
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_server_info.';
633
+ readonly thrownBy: 'service';
566
634
  }], undefined> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
567
635
  alias: import("zod").ZodOptional<import("zod").ZodString>;
568
636
  crop: import("zod").ZodOptional<import("zod").ZodString>;
@@ -620,11 +688,13 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
620
688
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
621
689
  readonly when: 'No connection has been registered under the requested alias';
622
690
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_find_studies.';
691
+ readonly thrownBy: 'service';
623
692
  }, {
624
693
  readonly reason: 'all_filters_dropped';
625
694
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
626
695
  readonly when: 'The active dialect dropped every filter the agent supplied — the upstream server does not honor any of the requested scope filters on this endpoint, so the call would silently widen to the unfiltered baseline.';
627
696
  readonly recovery: 'Drop the unsupported filters and rescope by crop, trialTypes, seasons, programs, trials, studyNames, or active — these filter paths are honored on the active dialect.';
697
+ readonly thrownBy: 'service';
628
698
  }], {
629
699
  readonly totalCount: import("zod").ZodNumber;
630
700
  readonly returnedCount: import("zod").ZodNumber;
@@ -694,11 +764,13 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
694
764
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
695
765
  readonly when: 'No connection has been registered under the requested alias';
696
766
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_find_germplasm.';
767
+ readonly thrownBy: 'service';
697
768
  }, {
698
769
  readonly reason: 'all_filters_dropped';
699
770
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
700
771
  readonly when: 'The active dialect dropped every filter the agent supplied — the upstream server does not honor any of the requested scope filters on this endpoint, so the call would silently widen to the unfiltered baseline.';
701
772
  readonly recovery: 'Drop the unsupported filters and rescope by names, germplasmDbIds, germplasmPUIs, accessionNumbers, crops, synonyms, genus, or species — these filter paths are honored on the active dialect.';
773
+ readonly thrownBy: 'service';
702
774
  }], {
703
775
  readonly totalCount: import("zod").ZodNumber;
704
776
  readonly returnedCount: import("zod").ZodNumber;
@@ -753,6 +825,7 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
753
825
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
754
826
  readonly when: 'No connection has been registered under the requested alias';
755
827
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_get_germplasm.';
828
+ readonly thrownBy: 'service';
756
829
  }, {
757
830
  readonly reason: 'germplasm_not_found';
758
831
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
@@ -831,6 +904,7 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
831
904
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
832
905
  readonly when: 'No connection has been registered under the requested alias';
833
906
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_walk_pedigree.';
907
+ readonly thrownBy: 'service';
834
908
  }], undefined> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
835
909
  alias: import("zod").ZodOptional<import("zod").ZodString>;
836
910
  germplasmDbId: import("zod").ZodString;
@@ -861,6 +935,7 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
861
935
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
862
936
  readonly when: 'No connection has been registered under the requested alias';
863
937
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_germplasm_performance.';
938
+ readonly thrownBy: 'service';
864
939
  }, {
865
940
  readonly reason: 'germplasm_not_found';
866
941
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
@@ -942,11 +1017,13 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
942
1017
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
943
1018
  readonly when: 'No connection has been registered under the requested alias';
944
1019
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_find_variables.';
1020
+ readonly thrownBy: 'service';
945
1021
  }, {
946
1022
  readonly reason: 'all_filters_dropped';
947
1023
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
948
1024
  readonly when: 'The active dialect dropped every filter the agent supplied — the upstream server does not honor any of the requested scope filters on this endpoint, so the call would silently widen to the unfiltered baseline.';
949
1025
  readonly recovery: 'Drop the unsupported filters and rescope by variables, traitClasses, ontologyDbIds, methodDbIds, scaleDbIds, or text — these filter paths are honored on the active dialect.';
1026
+ readonly thrownBy: 'service';
950
1027
  }], {
951
1028
  readonly totalCount: import("zod").ZodNumber;
952
1029
  readonly returnedCount: import("zod").ZodNumber;
@@ -1012,11 +1089,13 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
1012
1089
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
1013
1090
  readonly when: 'No connection has been registered under the requested alias';
1014
1091
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_find_observations.';
1092
+ readonly thrownBy: 'service';
1015
1093
  }, {
1016
1094
  readonly reason: 'all_filters_dropped';
1017
1095
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
1018
1096
  readonly when: 'The active dialect dropped every filter the agent supplied — the upstream server does not honor any of the requested scope filters on this endpoint, so the call would silently widen to the unfiltered baseline.';
1019
1097
  readonly recovery: 'Drop the unsupported filters and rescope by germplasm, variables, observationUnits, observations, seasons, programs, or trials — these filter paths are honored on the active dialect.';
1098
+ readonly thrownBy: 'service';
1020
1099
  }], {
1021
1100
  readonly totalCount: import("zod").ZodNumber;
1022
1101
  readonly returnedCount: import("zod").ZodNumber;
@@ -1079,11 +1158,13 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
1079
1158
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
1080
1159
  readonly when: 'No connection has been registered under the requested alias';
1081
1160
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_find_images.';
1161
+ readonly thrownBy: 'service';
1082
1162
  }, {
1083
1163
  readonly reason: 'all_filters_dropped';
1084
1164
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
1085
1165
  readonly when: 'The active dialect dropped every filter the agent supplied — the upstream server does not honor any of the requested scope filters on this endpoint, so the call would silently widen to the unfiltered baseline.';
1086
1166
  readonly recovery: 'Drop the unsupported filters and rescope by images, observationUnits, observations, studies, descriptiveOntologyTerms, imageFileNames, or mimeTypes — these filter paths are honored on the active dialect.';
1167
+ readonly thrownBy: 'service';
1087
1168
  }], {
1088
1169
  readonly totalCount: import("zod").ZodNumber;
1089
1170
  readonly returnedCount: import("zod").ZodNumber;
@@ -1135,6 +1216,7 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
1135
1216
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
1136
1217
  readonly when: 'No connection has been registered under the requested alias';
1137
1218
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_get_image.';
1219
+ readonly thrownBy: 'service';
1138
1220
  }, {
1139
1221
  readonly reason: 'images_unsupported';
1140
1222
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
@@ -1197,6 +1279,7 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
1197
1279
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
1198
1280
  readonly when: 'No connection has been registered under the requested alias';
1199
1281
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_find_genotype_calls.';
1282
+ readonly thrownBy: 'service';
1200
1283
  }, {
1201
1284
  readonly reason: 'no_filters';
1202
1285
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
@@ -1300,6 +1383,7 @@ export declare const readOnlyToolDefinitions: (import("@cyanheads/mcp-ts-core").
1300
1383
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
1301
1384
  readonly when: 'No connection has been registered under the requested alias';
1302
1385
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_raw_search.';
1386
+ readonly thrownBy: 'service';
1303
1387
  }, {
1304
1388
  readonly reason: 'search_endpoint_disabled';
1305
1389
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
@@ -1364,6 +1448,7 @@ export declare const exportToolDefinitions: import("@cyanheads/mcp-ts-core").Too
1364
1448
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
1365
1449
  readonly when: 'filename contains path separators or traversal segments';
1366
1450
  readonly recovery: 'Provide a filename without "/", "\\", or ".." — leave it unset to use the default.';
1451
+ readonly thrownBy: 'service';
1367
1452
  }, {
1368
1453
  readonly reason: 'mutually_exclusive_projection';
1369
1454
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
@@ -1449,6 +1534,7 @@ export declare const writeToolDefinitions: import("@cyanheads/mcp-ts-core").Tool
1449
1534
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
1450
1535
  readonly when: 'No connection has been registered under the requested alias';
1451
1536
  readonly recovery: 'Run brapi_connect with this alias (or omit `alias` to use the default connection) before calling brapi_submit_observations.';
1537
+ readonly thrownBy: 'service';
1452
1538
  }, {
1453
1539
  readonly reason: 'observations_unsupported';
1454
1540
  readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.ValidationError;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AA4BH;;;;GAIG;AACH,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAuBnC,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,mBAAmB;;;;;yDAAuB,CAAC;AAExD;;;;GAIG;AACH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gBAAyB,CAAC;AAE5D,qEAAqE;AACrE,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gBAA4B,CAAC"}
@@ -99,6 +99,12 @@ export interface ResolveFindRouteInput {
99
99
  * preserves the multi-value semantics the GET wire shape would have lost.
100
100
  */
101
101
  export declare function resolveFindRoute(input: ResolveFindRouteInput): FindRoute;
102
+ /**
103
+ * True when {@link resolveFindRoute} picks a route for `noun` on this server
104
+ * instead of throwing: GET `/{noun}` is advertised, or POST `/search/{noun}`
105
+ * is advertised and the active dialect does not mark it known-dead.
106
+ */
107
+ export declare function hasFindRoute(profile: CapabilityProfile, dialect: Pick<BrapiDialect, 'disabledSearchEndpoints'>, noun: string): boolean;
102
108
  /** Build request options with optional auth. */
103
109
  export declare function buildRequestOptions(connection: RegisteredServer, params?: BrapiRequestOptions['params'], overrides?: BrapiRequestOptions): BrapiRequestOptions;
104
110
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"find-helpers.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/shared/find-helpers.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,cAAc,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AAE9E,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAE9D,OAAO,KAAK,EACV,WAAW,EACX,aAAa,EACb,eAAe,EACf,mBAAmB,EACnB,YAAY,EACb,MAAM,kCAAkC,CAAC;AAC1C,OAAO,KAAK,EAAE,YAAY,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AACzF,OAAO,KAAK,EACV,YAAY,EAEZ,uBAAuB,EACxB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,yCAAyC,CAAC;AACjF,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAC;AAG5E,kFAAkF;AAClF,wBAAgB,kBAAkB,CAAC,GAAG,EAAE,OAAO,GAAG,OAAO,CAExD;AAED;;;;;;;;;;GAUG;AACH,wBAAsB,2BAA2B,CAC/C,GAAG,EAAE,cAAc,CAAC,eAAe,CAAC,EACpC,KAAK,EAAE,MAAM,GAAG,SAAS,GACxB,OAAO,CAAC,gBAAgB,CAAC,CAY3B;AAED,qFAAqF;AACrF,eAAO,MAAM,kBAAkB,QAAS,CAAC;AAEzC,iFAAiF;AACjF,eAAO,MAAM,mBAAmB,KAAK,CAAC;AAEtC,eAAO,MAAM,UAAU,4BAMpB,CAAC;AAEJ,eAAO,MAAM,cAAc,4BAOxB,CAAC;AAEJ,eAAO,MAAM,iBAAiB,uDAK3B,CAAC;AAEJ;;;GAGG;AACH,wBAAgB,YAAY,CAC1B,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO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C,gBAAgB,CAOlB;AAED;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,sBAAsB,CACpC,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,EACjD,IAAI,EAAE,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,EACxC,QAAQ,EAAE,MAAM,EAAE,GACjB,gBAAgB,EAAE,CA4BpB;AAoBD,MAAM,WAAW,qBAAqB;IACpC;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;CACtC;AAED;;;;;;GAMG;AACH,wBAAgB,mBAAmB,CACjC,UAAU,EAAE,MAAM,EAClB,SAAS,EAAE,MAAM,EACjB,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,EACrD,OAAO,GAAE,qBAA0B,GAClC,MAAM,GAAG,SAAS,CAqBpB;AA0CD;;;;;;;;;;;;GAYG;AACH,wBAAgB,uBAAuB,CACrC,GAAG,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC5B,YAAY,EAAE,WAAW,CAAC,MAAM,CAAC,EACjC,SAAS,CAAC,EAAE,eAAe,GAC1B,MAAM,EAAE,CAOV;AAED;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,sBAAsB,CACpC,KAAK,EAAE,MAAM,EAAE,EACf,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC/B,YAAY,EAAE,WAAW,CAAC,MAAM,CAAC,GAChC,IAAI,CAKN;AAED,YAAY,EAAE,aAAa,EAAE,eAAe,EAAE,YAAY,EAAE,YAAY,EAAE,CAAC"}
@@ -121,11 +121,7 @@ export function resolveFindRoute(input) {
121
121
  const path = `/${input.endpoint}`;
122
122
  const searchNoun = input.searchNoun ?? input.endpoint;
123
123
  const searchService = `search/${searchNoun}`;
124
- const getDescriptor = input.profile.supported[service];
125
- const searchDescriptor = input.profile.supported[searchService];
126
- const getSupported = supportsMethod(getDescriptor, 'GET');
127
- const searchSupported = supportsMethod(searchDescriptor, 'POST');
128
- const searchDisabled = Boolean(input.dialect.disabledSearchEndpoints?.has(searchNoun));
124
+ const { getSupported, searchSupported, searchDisabled } = findRouteSupport(input.profile, input.dialect, service, searchNoun);
129
125
  const escalate = input.requiresEscalation === true && searchSupported && !searchDisabled;
130
126
  if (getSupported && !escalate) {
131
127
  return { kind: 'get', service, path, filters: input.filters };
@@ -159,6 +155,22 @@ export function resolveFindRoute(input) {
159
155
  reason: 'missing_find_route',
160
156
  });
161
157
  }
158
+ /**
159
+ * True when {@link resolveFindRoute} picks a route for `noun` on this server
160
+ * instead of throwing: GET `/{noun}` is advertised, or POST `/search/{noun}`
161
+ * is advertised and the active dialect does not mark it known-dead.
162
+ */
163
+ export function hasFindRoute(profile, dialect, noun) {
164
+ const { getSupported, searchSupported, searchDisabled } = findRouteSupport(profile, dialect, noun, noun);
165
+ return getSupported || (searchSupported && !searchDisabled);
166
+ }
167
+ function findRouteSupport(profile, dialect, service, searchNoun) {
168
+ return {
169
+ getSupported: supportsMethod(profile.supported[service], 'GET'),
170
+ searchSupported: supportsMethod(profile.supported[`search/${searchNoun}`], 'POST'),
171
+ searchDisabled: Boolean(dialect.disabledSearchEndpoints?.has(searchNoun)),
172
+ };
173
+ }
162
174
  function supportsMethod(descriptor, method) {
163
175
  if (!descriptor)
164
176
  return false;