@inkeep/agents-core 0.1.3 → 0.1.6

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 (285) hide show
  1. package/SUPPLEMENTAL_TERMS.md +40 -0
  2. package/dist/chunk-H2F72PDA.js +15 -0
  3. package/dist/chunk-M4JXMAG7.js +822 -0
  4. package/dist/chunk-MKBO26DX.js +9 -0
  5. package/dist/chunk-RZPLS4MU.js +676 -0
  6. package/dist/chunk-SVGQSPW4.js +24 -0
  7. package/dist/client-exports.cjs +246 -0
  8. package/dist/client-exports.d.cts +315 -0
  9. package/dist/client-exports.d.ts +64 -49
  10. package/dist/client-exports.js +201 -246
  11. package/dist/db/schema.cjs +819 -0
  12. package/dist/db/schema.d.cts +8 -0
  13. package/dist/db/schema.d.ts +8 -4337
  14. package/dist/db/schema.js +1 -696
  15. package/dist/entities-CNJaf-rG.d.cts +7849 -0
  16. package/dist/entities-CNJaf-rG.d.ts +7849 -0
  17. package/dist/index.cjs +9647 -0
  18. package/dist/index.d.cts +3991 -0
  19. package/dist/index.d.ts +3991 -12
  20. package/dist/index.js +7646 -13
  21. package/dist/schema-DFDqtBpV.d.ts +4401 -0
  22. package/dist/schema-Dbc3UMpd.d.cts +4401 -0
  23. package/dist/types/index.cjs +45 -0
  24. package/dist/types/index.d.cts +125 -0
  25. package/dist/types/index.d.ts +125 -5
  26. package/dist/types/index.js +2 -6
  27. package/dist/validation/index.cjs +1642 -0
  28. package/dist/validation/index.d.cts +64 -0
  29. package/dist/validation/index.d.ts +64 -4
  30. package/dist/validation/index.js +1 -5
  31. package/package.json +6 -4
  32. package/dist/__tests__/integration/helpers.d.ts +0 -5
  33. package/dist/__tests__/integration/helpers.d.ts.map +0 -1
  34. package/dist/__tests__/integration/helpers.js +0 -37
  35. package/dist/__tests__/integration/helpers.js.map +0 -1
  36. package/dist/__tests__/setup.d.ts +0 -3
  37. package/dist/__tests__/setup.d.ts.map +0 -1
  38. package/dist/__tests__/setup.js +0 -29
  39. package/dist/__tests__/setup.js.map +0 -1
  40. package/dist/client-exports.d.ts.map +0 -1
  41. package/dist/client-exports.js.map +0 -1
  42. package/dist/context/ContextConfig.d.ts +0 -54
  43. package/dist/context/ContextConfig.d.ts.map +0 -1
  44. package/dist/context/ContextConfig.js +0 -302
  45. package/dist/context/ContextConfig.js.map +0 -1
  46. package/dist/context/ContextFetcher.d.ts +0 -64
  47. package/dist/context/ContextFetcher.d.ts.map +0 -1
  48. package/dist/context/ContextFetcher.js +0 -325
  49. package/dist/context/ContextFetcher.js.map +0 -1
  50. package/dist/context/ContextResolver.d.ts +0 -52
  51. package/dist/context/ContextResolver.d.ts.map +0 -1
  52. package/dist/context/ContextResolver.js +0 -298
  53. package/dist/context/ContextResolver.js.map +0 -1
  54. package/dist/context/TemplateEngine.d.ts +0 -46
  55. package/dist/context/TemplateEngine.d.ts.map +0 -1
  56. package/dist/context/TemplateEngine.js +0 -175
  57. package/dist/context/TemplateEngine.js.map +0 -1
  58. package/dist/context/context.d.ts +0 -8
  59. package/dist/context/context.d.ts.map +0 -1
  60. package/dist/context/context.js +0 -157
  61. package/dist/context/context.js.map +0 -1
  62. package/dist/context/contextCache.d.ts +0 -50
  63. package/dist/context/contextCache.d.ts.map +0 -1
  64. package/dist/context/contextCache.js +0 -175
  65. package/dist/context/contextCache.js.map +0 -1
  66. package/dist/context/index.d.ts +0 -11
  67. package/dist/context/index.d.ts.map +0 -1
  68. package/dist/context/index.js +0 -8
  69. package/dist/context/index.js.map +0 -1
  70. package/dist/credential-stores/CredentialStoreRegistry.d.ts +0 -39
  71. package/dist/credential-stores/CredentialStoreRegistry.d.ts.map +0 -1
  72. package/dist/credential-stores/CredentialStoreRegistry.js +0 -65
  73. package/dist/credential-stores/CredentialStoreRegistry.js.map +0 -1
  74. package/dist/credential-stores/defaults.d.ts +0 -6
  75. package/dist/credential-stores/defaults.d.ts.map +0 -1
  76. package/dist/credential-stores/defaults.js +0 -22
  77. package/dist/credential-stores/defaults.js.map +0 -1
  78. package/dist/credential-stores/index.d.ts +0 -6
  79. package/dist/credential-stores/index.d.ts.map +0 -1
  80. package/dist/credential-stores/index.js +0 -6
  81. package/dist/credential-stores/index.js.map +0 -1
  82. package/dist/credential-stores/keychain-store.d.ts +0 -100
  83. package/dist/credential-stores/keychain-store.d.ts.map +0 -1
  84. package/dist/credential-stores/keychain-store.js +0 -225
  85. package/dist/credential-stores/keychain-store.js.map +0 -1
  86. package/dist/credential-stores/memory-store.d.ts +0 -39
  87. package/dist/credential-stores/memory-store.d.ts.map +0 -1
  88. package/dist/credential-stores/memory-store.js +0 -58
  89. package/dist/credential-stores/memory-store.js.map +0 -1
  90. package/dist/credential-stores/nango-store.d.ts +0 -59
  91. package/dist/credential-stores/nango-store.d.ts.map +0 -1
  92. package/dist/credential-stores/nango-store.js +0 -264
  93. package/dist/credential-stores/nango-store.js.map +0 -1
  94. package/dist/credential-stuffer/CredentialStuffer.d.ts +0 -80
  95. package/dist/credential-stuffer/CredentialStuffer.d.ts.map +0 -1
  96. package/dist/credential-stuffer/CredentialStuffer.js +0 -186
  97. package/dist/credential-stuffer/CredentialStuffer.js.map +0 -1
  98. package/dist/credential-stuffer/index.d.ts +0 -2
  99. package/dist/credential-stuffer/index.d.ts.map +0 -1
  100. package/dist/credential-stuffer/index.js +0 -2
  101. package/dist/credential-stuffer/index.js.map +0 -1
  102. package/dist/data-access/agentDataComponents.d.ts +0 -1
  103. package/dist/data-access/agentDataComponents.d.ts.map +0 -1
  104. package/dist/data-access/agentDataComponents.js +0 -2
  105. package/dist/data-access/agentDataComponents.js.map +0 -1
  106. package/dist/data-access/agentGraphs.d.ts +0 -406
  107. package/dist/data-access/agentGraphs.d.ts.map +0 -1
  108. package/dist/data-access/agentGraphs.js +0 -551
  109. package/dist/data-access/agentGraphs.js.map +0 -1
  110. package/dist/data-access/agentRelations.d.ts +0 -456
  111. package/dist/data-access/agentRelations.d.ts.map +0 -1
  112. package/dist/data-access/agentRelations.js +0 -471
  113. package/dist/data-access/agentRelations.js.map +0 -1
  114. package/dist/data-access/agents.d.ts +0 -218
  115. package/dist/data-access/agents.d.ts.map +0 -1
  116. package/dist/data-access/agents.js +0 -130
  117. package/dist/data-access/agents.js.map +0 -1
  118. package/dist/data-access/apiKeys.d.ts +0 -114
  119. package/dist/data-access/apiKeys.d.ts.map +0 -1
  120. package/dist/data-access/apiKeys.js +0 -185
  121. package/dist/data-access/apiKeys.js.map +0 -1
  122. package/dist/data-access/artifactComponents.d.ts +0 -152
  123. package/dist/data-access/artifactComponents.d.ts.map +0 -1
  124. package/dist/data-access/artifactComponents.js +0 -214
  125. package/dist/data-access/artifactComponents.js.map +0 -1
  126. package/dist/data-access/contextCache.d.ts +0 -68
  127. package/dist/data-access/contextCache.d.ts.map +0 -1
  128. package/dist/data-access/contextCache.js +0 -160
  129. package/dist/data-access/contextCache.js.map +0 -1
  130. package/dist/data-access/contextConfigs.d.ts +0 -110
  131. package/dist/data-access/contextConfigs.d.ts.map +0 -1
  132. package/dist/data-access/contextConfigs.js +0 -156
  133. package/dist/data-access/contextConfigs.js.map +0 -1
  134. package/dist/data-access/conversations.d.ts +0 -125
  135. package/dist/data-access/conversations.d.ts.map +0 -1
  136. package/dist/data-access/conversations.js +0 -244
  137. package/dist/data-access/conversations.js.map +0 -1
  138. package/dist/data-access/credentialReferences.d.ts +0 -86
  139. package/dist/data-access/credentialReferences.d.ts.map +0 -1
  140. package/dist/data-access/credentialReferences.js +0 -175
  141. package/dist/data-access/credentialReferences.js.map +0 -1
  142. package/dist/data-access/dataComponents.d.ts +0 -129
  143. package/dist/data-access/dataComponents.d.ts.map +0 -1
  144. package/dist/data-access/dataComponents.js +0 -213
  145. package/dist/data-access/dataComponents.js.map +0 -1
  146. package/dist/data-access/externalAgents.d.ts +0 -83
  147. package/dist/data-access/externalAgents.d.ts.map +0 -1
  148. package/dist/data-access/externalAgents.js +0 -163
  149. package/dist/data-access/externalAgents.js.map +0 -1
  150. package/dist/data-access/graphFull.d.ts +0 -32
  151. package/dist/data-access/graphFull.d.ts.map +0 -1
  152. package/dist/data-access/graphFull.js +0 -996
  153. package/dist/data-access/graphFull.js.map +0 -1
  154. package/dist/data-access/index.d.ts +0 -21
  155. package/dist/data-access/index.d.ts.map +0 -1
  156. package/dist/data-access/index.js +0 -22
  157. package/dist/data-access/index.js.map +0 -1
  158. package/dist/data-access/ledgerArtifacts.d.ts +0 -49
  159. package/dist/data-access/ledgerArtifacts.d.ts.map +0 -1
  160. package/dist/data-access/ledgerArtifacts.js +0 -112
  161. package/dist/data-access/ledgerArtifacts.js.map +0 -1
  162. package/dist/data-access/messages.d.ts +0 -209
  163. package/dist/data-access/messages.d.ts.map +0 -1
  164. package/dist/data-access/messages.js +0 -100
  165. package/dist/data-access/messages.js.map +0 -1
  166. package/dist/data-access/projects.d.ts +0 -67
  167. package/dist/data-access/projects.d.ts.map +0 -1
  168. package/dist/data-access/projects.js +0 -337
  169. package/dist/data-access/projects.js.map +0 -1
  170. package/dist/data-access/tasks.d.ts +0 -37
  171. package/dist/data-access/tasks.d.ts.map +0 -1
  172. package/dist/data-access/tasks.js +0 -40
  173. package/dist/data-access/tasks.js.map +0 -1
  174. package/dist/data-access/tools.d.ts +0 -277
  175. package/dist/data-access/tools.d.ts.map +0 -1
  176. package/dist/data-access/tools.js +0 -183
  177. package/dist/data-access/tools.js.map +0 -1
  178. package/dist/data-access/validation.d.ts +0 -17
  179. package/dist/data-access/validation.d.ts.map +0 -1
  180. package/dist/data-access/validation.js +0 -52
  181. package/dist/data-access/validation.js.map +0 -1
  182. package/dist/db/clean.d.ts +0 -6
  183. package/dist/db/clean.d.ts.map +0 -1
  184. package/dist/db/clean.js +0 -81
  185. package/dist/db/clean.js.map +0 -1
  186. package/dist/db/client.d.ts +0 -19
  187. package/dist/db/client.d.ts.map +0 -1
  188. package/dist/db/client.js +0 -24
  189. package/dist/db/client.js.map +0 -1
  190. package/dist/db/schema.d.ts.map +0 -1
  191. package/dist/db/schema.js.map +0 -1
  192. package/dist/db/test-client.d.ts +0 -25
  193. package/dist/db/test-client.d.ts.map +0 -1
  194. package/dist/db/test-client.js +0 -136
  195. package/dist/db/test-client.js.map +0 -1
  196. package/dist/env.d.ts +0 -19
  197. package/dist/env.d.ts.map +0 -1
  198. package/dist/env.js +0 -49
  199. package/dist/env.js.map +0 -1
  200. package/dist/index.d.ts.map +0 -1
  201. package/dist/index.js.map +0 -1
  202. package/dist/middleware/contextValidation.d.ts +0 -49
  203. package/dist/middleware/contextValidation.d.ts.map +0 -1
  204. package/dist/middleware/contextValidation.js +0 -473
  205. package/dist/middleware/contextValidation.js.map +0 -1
  206. package/dist/middleware/index.d.ts +0 -2
  207. package/dist/middleware/index.d.ts.map +0 -1
  208. package/dist/middleware/index.js +0 -2
  209. package/dist/middleware/index.js.map +0 -1
  210. package/dist/server/BaseServer.d.ts +0 -83
  211. package/dist/server/BaseServer.d.ts.map +0 -1
  212. package/dist/server/BaseServer.js +0 -218
  213. package/dist/server/BaseServer.js.map +0 -1
  214. package/dist/types/a2a.d.ts +0 -373
  215. package/dist/types/a2a.d.ts.map +0 -1
  216. package/dist/types/a2a.js +0 -14
  217. package/dist/types/a2a.js.map +0 -1
  218. package/dist/types/entities.d.ts +0 -147
  219. package/dist/types/entities.d.ts.map +0 -1
  220. package/dist/types/entities.js +0 -2
  221. package/dist/types/entities.js.map +0 -1
  222. package/dist/types/index.d.ts.map +0 -1
  223. package/dist/types/index.js.map +0 -1
  224. package/dist/types/server.d.ts +0 -116
  225. package/dist/types/server.d.ts.map +0 -1
  226. package/dist/types/server.js +0 -2
  227. package/dist/types/server.js.map +0 -1
  228. package/dist/types/utility.d.ts +0 -213
  229. package/dist/types/utility.d.ts.map +0 -1
  230. package/dist/types/utility.js +0 -9
  231. package/dist/types/utility.js.map +0 -1
  232. package/dist/utils/apiKeys.d.ts +0 -32
  233. package/dist/utils/apiKeys.d.ts.map +0 -1
  234. package/dist/utils/apiKeys.js +0 -117
  235. package/dist/utils/apiKeys.js.map +0 -1
  236. package/dist/utils/auth-detection.d.ts +0 -23
  237. package/dist/utils/auth-detection.d.ts.map +0 -1
  238. package/dist/utils/auth-detection.js +0 -148
  239. package/dist/utils/auth-detection.js.map +0 -1
  240. package/dist/utils/credential-store-utils.d.ts +0 -11
  241. package/dist/utils/credential-store-utils.d.ts.map +0 -1
  242. package/dist/utils/credential-store-utils.js +0 -19
  243. package/dist/utils/credential-store-utils.js.map +0 -1
  244. package/dist/utils/error.d.ts +0 -526
  245. package/dist/utils/error.d.ts.map +0 -1
  246. package/dist/utils/error.js +0 -282
  247. package/dist/utils/error.js.map +0 -1
  248. package/dist/utils/execution.d.ts +0 -18
  249. package/dist/utils/execution.d.ts.map +0 -1
  250. package/dist/utils/execution.js +0 -25
  251. package/dist/utils/execution.js.map +0 -1
  252. package/dist/utils/index.d.ts +0 -9
  253. package/dist/utils/index.d.ts.map +0 -1
  254. package/dist/utils/index.js +0 -9
  255. package/dist/utils/index.js.map +0 -1
  256. package/dist/utils/logger.d.ts +0 -79
  257. package/dist/utils/logger.d.ts.map +0 -1
  258. package/dist/utils/logger.js +0 -102
  259. package/dist/utils/logger.js.map +0 -1
  260. package/dist/utils/logging.d.ts +0 -11
  261. package/dist/utils/logging.d.ts.map +0 -1
  262. package/dist/utils/logging.js +0 -6
  263. package/dist/utils/logging.js.map +0 -1
  264. package/dist/utils/mcp-client.d.ts +0 -48
  265. package/dist/utils/mcp-client.d.ts.map +0 -1
  266. package/dist/utils/mcp-client.js +0 -171
  267. package/dist/utils/mcp-client.js.map +0 -1
  268. package/dist/utils/tracer.d.ts +0 -24
  269. package/dist/utils/tracer.d.ts.map +0 -1
  270. package/dist/utils/tracer.js +0 -110
  271. package/dist/utils/tracer.js.map +0 -1
  272. package/dist/validation/graphFull.d.ts +0 -36
  273. package/dist/validation/graphFull.d.ts.map +0 -1
  274. package/dist/validation/graphFull.js +0 -128
  275. package/dist/validation/graphFull.js.map +0 -1
  276. package/dist/validation/id-validation.d.ts +0 -38
  277. package/dist/validation/id-validation.d.ts.map +0 -1
  278. package/dist/validation/id-validation.js +0 -60
  279. package/dist/validation/id-validation.js.map +0 -1
  280. package/dist/validation/index.d.ts.map +0 -1
  281. package/dist/validation/index.js.map +0 -1
  282. package/dist/validation/schemas.d.ts +0 -7238
  283. package/dist/validation/schemas.d.ts.map +0 -1
  284. package/dist/validation/schemas.js +0 -575
  285. package/dist/validation/schemas.js.map +0 -1
@@ -1,282 +0,0 @@
1
- import { z } from '@hono/zod-openapi';
2
- import { HTTPException } from 'hono/http-exception';
3
- import { getLogger } from './logger';
4
- export const ErrorCode = z.enum([
5
- 'bad_request',
6
- 'unauthorized',
7
- 'forbidden',
8
- 'not_found',
9
- 'conflict',
10
- 'internal_server_error',
11
- 'unprocessable_entity',
12
- ]);
13
- const errorCodeToHttpStatus = {
14
- bad_request: 400,
15
- unauthorized: 401,
16
- forbidden: 403,
17
- not_found: 404,
18
- conflict: 409,
19
- unprocessable_entity: 422,
20
- internal_server_error: 500,
21
- };
22
- // Base URL for error documentation
23
- export const ERROR_DOCS_BASE_URL = 'https://docs.inkeep.com/agents-api/errors';
24
- // Problem Details schema (RFC 7807)
25
- export const problemDetailsSchema = z
26
- .object({
27
- // type: z.string().url().openapi({
28
- // description: "A URI reference that identifies the problem type.",
29
- // example: `${ERROR_DOCS_BASE_URL}#not-found`,
30
- // }),
31
- title: z.string().openapi({
32
- description: 'A short, human-readable summary of the problem type.',
33
- example: 'Resource Not Found',
34
- }),
35
- status: z.number().int().openapi({
36
- description: 'The HTTP status code.',
37
- example: 404,
38
- }),
39
- detail: z.string().openapi({
40
- description: 'A human-readable explanation specific to this occurrence of the problem.',
41
- example: 'The requested resource was not found.',
42
- }),
43
- instance: z.string().optional().openapi({
44
- description: 'A URI reference that identifies the specific occurrence of the problem.',
45
- example: '/conversations/123',
46
- }),
47
- requestId: z.string().optional().openapi({
48
- description: 'A unique identifier for the request, useful for troubleshooting.',
49
- example: 'req_1234567890',
50
- }),
51
- code: ErrorCode.openapi({
52
- description: 'A short code indicating the error code returned.',
53
- example: 'not_found',
54
- }),
55
- })
56
- .openapi('ProblemDetails');
57
- // Legacy error response schema for backward compatibility
58
- export const errorResponseSchema = z
59
- .object({
60
- error: z.object({
61
- code: ErrorCode.openapi({
62
- description: 'A short code indicating the error code returned.',
63
- example: 'not_found',
64
- }),
65
- message: z.string().openapi({
66
- description: 'A human readable error message.',
67
- example: 'The requested resource was not found.',
68
- }),
69
- }),
70
- })
71
- .openapi('ErrorResponse');
72
- export function createApiError({ code, message, instance, requestId, }) {
73
- const status = errorCodeToHttpStatus[code];
74
- const title = getTitleFromCode(code);
75
- const type = `${ERROR_DOCS_BASE_URL}#${code}`;
76
- // Create Problem Details object
77
- const problemDetails = {
78
- // type,
79
- title,
80
- status,
81
- detail: message,
82
- code,
83
- ...(instance && { instance }),
84
- ...(requestId && { requestId }),
85
- };
86
- // For backward compatibility, also include the legacy error format
87
- // Make error.message more concise if the detail is long
88
- const errorMessage = message.length > 100 ? `${message.substring(0, 97)}...` : message;
89
- const responseBody = {
90
- ...problemDetails,
91
- error: { code, message: errorMessage },
92
- };
93
- // Create a Response object with the problem details
94
- const res = new Response(JSON.stringify(responseBody), {
95
- status,
96
- headers: {
97
- 'Content-Type': 'application/problem+json',
98
- 'X-Content-Type-Options': 'nosniff',
99
- ...(requestId && { 'X-Request-ID': requestId }),
100
- },
101
- });
102
- // @ts-expect-error - The HTTPException constructor expects a ContentfulStatusCode, but we're using a number
103
- // This is safe because we're only using valid HTTP status codes
104
- return new HTTPException(status, { message, res });
105
- }
106
- export async function handleApiError(error, requestId) {
107
- if (error instanceof HTTPException) {
108
- const errorData = error.getResponse();
109
- const responseText = await errorData.text();
110
- let responseJson;
111
- try {
112
- responseJson = JSON.parse(responseText);
113
- // Add requestId if it's provided and not already in the response
114
- if (requestId && !responseJson.requestId) {
115
- responseJson.requestId = requestId;
116
- }
117
- }
118
- catch (e) {
119
- // If not JSON, create a default problem details
120
- responseJson = {
121
- // type: `${ERROR_DOCS_BASE_URL}#internal_server_error`,
122
- title: 'Internal Server Error',
123
- status: error.status,
124
- detail: `Error processing request: ${responseText || 'Unknown error'}`,
125
- code: 'internal_server_error',
126
- ...(requestId && { requestId }),
127
- error: {
128
- code: 'internal_server_error',
129
- message: 'An internal server error occurred',
130
- },
131
- };
132
- }
133
- // Only log at error level for 500 series errors
134
- if (error.status >= 500) {
135
- getLogger('core').error({
136
- error,
137
- status: error.status,
138
- message: responseJson.detail || responseJson.error.message,
139
- requestId: responseJson.requestId || requestId || 'unknown',
140
- }, 'API server error occurred');
141
- }
142
- else {
143
- getLogger('core').info({
144
- error,
145
- status: error.status,
146
- code: responseJson.code,
147
- message: responseJson.detail || responseJson.error.message,
148
- requestId: responseJson.requestId || requestId || 'unknown',
149
- }, 'API client error occurred');
150
- }
151
- return responseJson;
152
- }
153
- // Fallback for unhandled errors - these are always 500 series
154
- // Extract useful information from the error for logging
155
- const errorMessage = error instanceof Error ? error.message : String(error);
156
- const errorStack = error instanceof Error ? error.stack : undefined;
157
- getLogger('core').error({
158
- error,
159
- message: errorMessage,
160
- stack: errorStack,
161
- status: 500,
162
- requestId: requestId || 'unknown',
163
- }, 'Unhandled API error occurred');
164
- // Create a more specific detail message that includes some error information
165
- // but sanitize it to avoid exposing sensitive details
166
- const sanitizedErrorMessage = error instanceof Error
167
- ? error.message.replace(/\b(password|token|key|secret|auth)\b/gi, '[REDACTED]')
168
- : 'Unknown error';
169
- const problemDetails = {
170
- // type: `${ERROR_DOCS_BASE_URL}#internal_server_error`,
171
- title: 'Internal Server Error',
172
- status: 500,
173
- detail: `Server error occurred: ${sanitizedErrorMessage}`,
174
- code: 'internal_server_error',
175
- ...(requestId && { requestId }),
176
- error: {
177
- code: 'internal_server_error',
178
- message: 'An internal server error occurred. Please try again later.',
179
- },
180
- };
181
- return problemDetails;
182
- }
183
- // Helper function to get title from error code
184
- function getTitleFromCode(code) {
185
- switch (code) {
186
- case 'bad_request':
187
- return 'Bad Request';
188
- case 'unauthorized':
189
- return 'Unauthorized';
190
- case 'forbidden':
191
- return 'Forbidden';
192
- case 'not_found':
193
- return 'Not Found';
194
- case 'unprocessable_entity':
195
- return 'Unprocessable Entity';
196
- case 'internal_server_error':
197
- return 'Internal Server Error';
198
- default:
199
- return 'Error';
200
- }
201
- }
202
- const toTitleCase = (str) => str
203
- ?.replace(/\w+/g, (word) => word.charAt(0).toUpperCase() + word.slice(1).toLowerCase())
204
- .replace(/\s+/g, '') ?? '';
205
- // Updated error schema factory to use Problem Details
206
- export const errorSchemaFactory = (code, description) => ({
207
- description,
208
- content: {
209
- 'application/problem+json': {
210
- schema: problemDetailsSchema
211
- .extend({
212
- code: z.literal(code).openapi({
213
- description: 'A short code indicating the error code returned.',
214
- example: code,
215
- }),
216
- detail: z.string().openapi({
217
- description: 'A detailed explanation specific to this occurrence of the problem, providing context and specifics about what went wrong.',
218
- example: description,
219
- }),
220
- title: z.string().openapi({
221
- description: 'A short, human-readable summary of the problem type.',
222
- example: getTitleFromCode(code),
223
- }),
224
- // type: z.string().url().openapi({
225
- // description: "A URI reference that identifies the problem type.",
226
- // example: `${ERROR_DOCS_BASE_URL}#${code}`,
227
- // }),
228
- status: z.literal(errorCodeToHttpStatus[code]).openapi({
229
- description: 'The HTTP status code.',
230
- example: errorCodeToHttpStatus[code],
231
- }),
232
- error: z
233
- .object({
234
- code: z.literal(code).openapi({
235
- description: 'A short code indicating the error code returned.',
236
- example: code,
237
- }),
238
- message: z.string().openapi({
239
- description: 'A concise error message suitable for display to end users. May be truncated if the full detail is long.',
240
- example: description.length > 100 ? `${description.substring(0, 97)}...` : description,
241
- }),
242
- })
243
- .openapi({
244
- description: 'Legacy error format for backward compatibility.',
245
- }),
246
- })
247
- .openapi(toTitleCase(description)),
248
- },
249
- },
250
- });
251
- export const commonCreateErrorResponses = {
252
- 400: errorSchemaFactory('bad_request', 'Bad Request'),
253
- 401: errorSchemaFactory('unauthorized', 'Unauthorized'),
254
- 403: errorSchemaFactory('forbidden', 'Forbidden'),
255
- 422: errorSchemaFactory('unprocessable_entity', 'Unprocessable Entity'),
256
- 500: errorSchemaFactory('internal_server_error', 'Internal Server Error'),
257
- };
258
- export const commonUpdateErrorResponses = {
259
- 400: errorSchemaFactory('bad_request', 'Bad Request'),
260
- 401: errorSchemaFactory('unauthorized', 'Unauthorized'),
261
- 403: errorSchemaFactory('forbidden', 'Forbidden'),
262
- 404: errorSchemaFactory('not_found', 'Not Found'),
263
- 422: errorSchemaFactory('unprocessable_entity', 'Unprocessable Entity'),
264
- 500: errorSchemaFactory('internal_server_error', 'Internal Server Error'),
265
- };
266
- export const commonGetErrorResponses = {
267
- 400: errorSchemaFactory('bad_request', 'Bad Request'),
268
- 401: errorSchemaFactory('unauthorized', 'Unauthorized'),
269
- 403: errorSchemaFactory('forbidden', 'Forbidden'),
270
- 404: errorSchemaFactory('not_found', 'Not Found'),
271
- 422: errorSchemaFactory('unprocessable_entity', 'Unprocessable Entity'),
272
- 500: errorSchemaFactory('internal_server_error', 'Internal Server Error'),
273
- };
274
- export const commonDeleteErrorResponses = {
275
- 400: errorSchemaFactory('bad_request', 'Bad Request'),
276
- 401: errorSchemaFactory('unauthorized', 'Unauthorized'),
277
- 403: errorSchemaFactory('forbidden', 'Forbidden'),
278
- 404: errorSchemaFactory('not_found', 'Not Found'),
279
- 422: errorSchemaFactory('unprocessable_entity', 'Unprocessable Entity'),
280
- 500: errorSchemaFactory('internal_server_error', 'Internal Server Error'),
281
- };
282
- //# sourceMappingURL=error.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"error.js","sourceRoot":"","sources":["../../src/utils/error.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,mBAAmB,CAAC;AACtC,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAErC,MAAM,CAAC,MAAM,SAAS,GAAG,CAAC,CAAC,IAAI,CAAC;IAC9B,aAAa;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AC;IACjD,GAAG,EAAE,kBAAkB,CAAC,sBAAsB,EAAE,sBAAsB,CAAC;IACvE,GAAG,EAAE,kBAAkB,CAAC,uBAAuB,EAAE,uBAAuB,CAAC;CACjE,CAAC;AAEX,MAAM,CAAC,MAAM,0BAA0B,GAAG;IACxC,GAAG,EAAE,kBAAkB,CAAC,aAAa,EAAE,aAAa,CAAC;IACrD,GAAG,EAAE,kBAAkB,CAAC,cAAc,EAAE,cAAc,CAAC;IACvD,GAAG,EAAE,kBAAkB,CAAC,WAAW,EAAE,WAAW,CAAC;IACjD,GAAG,EAAE,kBAAkB,CAAC,WAAW,EAAE,WAAW,CAAC;IACjD,GAAG,EAAE,kBAAkB,CAAC,sBAAsB,EAAE,sBAAsB,CAAC;IACvE,GAAG,EAAE,kBAAkB,CAAC,uBAAuB,EAAE,uBAAuB,CAAC;CACjE,CAAC"}
@@ -1,18 +0,0 @@
1
- import type { Context } from 'hono';
2
- import type { ExecutionContext } from '../types/utility';
3
- /**
4
- * Create execution context from middleware values
5
- */
6
- export declare function createExecutionContext(params: {
7
- apiKey: string;
8
- tenantId: string;
9
- projectId: string;
10
- graphId: string;
11
- apiKeyId: string;
12
- baseUrl?: string;
13
- }): ExecutionContext;
14
- /**
15
- * Get execution context from API key authentication
16
- */
17
- export declare function getRequestExecutionContext(c: Context): ExecutionContext;
18
- //# sourceMappingURL=execution.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"execution.d.ts","sourceRoot":"","sources":["../../src/utils/execution.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AACpC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAEzD;;GAEG;AACH,wBAAgB,sBAAsB,CAAC,MAAM,EAAE;IAC7C,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,GAAG,gBAAgB,CASnB;AAED;;GAEG;AACH,wBAAgB,0BAA0B,CAAC,CAAC,EAAE,OAAO,GAAG,gBAAgB,CASvE"}
@@ -1,25 +0,0 @@
1
- /**
2
- * Create execution context from middleware values
3
- */
4
- export function createExecutionContext(params) {
5
- return {
6
- apiKey: params.apiKey,
7
- tenantId: params.tenantId,
8
- projectId: params.projectId,
9
- graphId: params.graphId,
10
- baseUrl: params.baseUrl || process.env.API_URL || 'http://localhost:3003',
11
- apiKeyId: params.apiKeyId,
12
- };
13
- }
14
- /**
15
- * Get execution context from API key authentication
16
- */
17
- export function getRequestExecutionContext(c) {
18
- // Get execution context from API key authentication
19
- const executionContext = c.get('executionContext');
20
- if (!executionContext) {
21
- throw new Error('No execution context available. API key authentication is required.');
22
- }
23
- return executionContext;
24
- }
25
- //# sourceMappingURL=execution.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"execution.js","sourceRoot":"","sources":["../../src/utils/execution.ts"],"names":[],"mappings":"AAGA;;GAEG;AACH,MAAM,UAAU,sBAAsB,CAAC,MAOtC;IACC,OAAO;QACL,MAAM,EAAE,MAAM,CAAC,MAAM;QACrB,QAAQ,EAAE,MAAM,CAAC,QAAQ;QACzB,SAAS,EAAE,MAAM,CAAC,SAAS;QAC3B,OAAO,EAAE,MAAM,CAAC,OAAO;QACvB,OAAO,EAAE,MAAM,CAAC,OAAO,IAAI,OAAO,CAAC,GAAG,CAAC,OAAO,IAAI,uBAAuB;QACzE,QAAQ,EAAE,MAAM,CAAC,QAAQ;KAC1B,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,0BAA0B,CAAC,CAAU;IACnD,oDAAoD;IACpD,MAAM,gBAAgB,GAAG,CAAC,CAAC,GAAG,CAAC,kBAAkB,CAAC,CAAC;IAEnD,IAAI,CAAC,gBAAgB,EAAE,CAAC;QACtB,MAAM,IAAI,KAAK,CAAC,qEAAqE,CAAC,CAAC;IACzF,CAAC;IAED,OAAO,gBAAgB,CAAC;AAC1B,CAAC"}
@@ -1,9 +0,0 @@
1
- export * from './apiKeys';
2
- export * from './auth-detection';
3
- export * from './credential-store-utils';
4
- export * from './error';
5
- export * from './execution';
6
- export * from './logger';
7
- export * from './mcp-client';
8
- export * from './tracer';
9
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,WAAW,CAAC;AAC1B,cAAc,kBAAkB,CAAC;AACjC,cAAc,0BAA0B,CAAC;AACzC,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC"}
@@ -1,9 +0,0 @@
1
- export * from './apiKeys';
2
- export * from './auth-detection';
3
- export * from './credential-store-utils';
4
- export * from './error';
5
- export * from './execution';
6
- export * from './logger';
7
- export * from './mcp-client';
8
- export * from './tracer';
9
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,WAAW,CAAC;AAC1B,cAAc,kBAAkB,CAAC;AACjC,cAAc,0BAA0B,CAAC;AACzC,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC"}
@@ -1,79 +0,0 @@
1
- /**
2
- * Logger interface for core package components
3
- * Allows services to inject their own logger implementation
4
- */
5
- export interface Logger {
6
- error(data: any, message: string): void;
7
- warn(data: any, message: string): void;
8
- info(data: any, message: string): void;
9
- debug(data: any, message: string): void;
10
- }
11
- /**
12
- * Default console logger implementation
13
- */
14
- export declare class ConsoleLogger implements Logger {
15
- private name;
16
- constructor(name: string);
17
- error(data: any, message: string): void;
18
- warn(data: any, message: string): void;
19
- info(data: any, message: string): void;
20
- debug(data: any, message: string): void;
21
- }
22
- /**
23
- * No-op logger that silently ignores all log calls
24
- */
25
- export declare class NoOpLogger implements Logger {
26
- error(_data: any, _message: string): void;
27
- warn(_data: any, _message: string): void;
28
- info(_data: any, _message: string): void;
29
- debug(_data: any, _message: string): void;
30
- }
31
- /**
32
- * Logger factory configuration
33
- */
34
- export interface LoggerFactoryConfig {
35
- defaultLogger?: Logger;
36
- loggerFactory?: (name: string) => Logger;
37
- }
38
- /**
39
- * Global logger factory singleton
40
- */
41
- declare class LoggerFactory {
42
- private config;
43
- private loggers;
44
- /**
45
- * Configure the logger factory
46
- */
47
- configure(config: LoggerFactoryConfig): void;
48
- /**
49
- * Get or create a logger instance
50
- */
51
- getLogger(name: string): Logger;
52
- /**
53
- * Reset factory to default state
54
- */
55
- reset(): void;
56
- }
57
- export declare const loggerFactory: LoggerFactory;
58
- /**
59
- * Convenience function to get a logger
60
- */
61
- export declare function getLogger(name: string): Logger;
62
- /**
63
- * Configure the global logger factory
64
- * This should be called once at application startup
65
- *
66
- * Example usage:
67
- * ```typescript
68
- * // In your service initialization
69
- * import { configureLogging } from '@inkeep/agents-core';
70
- * import { getLogger as getPinoLogger } from './logger.j';
71
- *
72
- * configureLogging({
73
- * loggerFactory: (name) => getPinoLogger(name)
74
- * });
75
- * ```
76
- */
77
- export declare function configureLogging(config: LoggerFactoryConfig): void;
78
- export {};
79
- //# sourceMappingURL=logger.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"logger.d.ts","sourceRoot":"","sources":["../../src/utils/logger.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,WAAW,MAAM;IACrB,KAAK,CAAC,IAAI,EAAE,GAAG,EAAE,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACxC,IAAI,CAAC,IAAI,EAAE,GAAG,EAAE,OAAO,EAAE,MAAM,G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ACH,SAAS,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM;IAqB/B;;OAEG;IACH,KAAK,IAAI,IAAI;CAId;AAGD,eAAO,MAAM,aAAa,eAAsB,CAAC;AAEjD;;GAEG;AACH,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAE9C;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,mBAAmB,GAAG,IAAI,CAElE"}
@@ -1,102 +0,0 @@
1
- /**
2
- * Default console logger implementation
3
- */
4
- export class ConsoleLogger {
5
- name;
6
- constructor(name) {
7
- this.name = name;
8
- }
9
- error(data, message) {
10
- console.error(`[${this.name}] ${message}`, data);
11
- }
12
- warn(data, message) {
13
- console.warn(`[${this.name}] ${message}`, data);
14
- }
15
- info(data, message) {
16
- console.info(`[${this.name}] ${message}`, data);
17
- }
18
- debug(data, message) {
19
- console.debug(`[${this.name}] ${message}`, data);
20
- }
21
- }
22
- /**
23
- * No-op logger that silently ignores all log calls
24
- */
25
- export class NoOpLogger {
26
- error(_data, _message) { }
27
- warn(_data, _message) { }
28
- info(_data, _message) { }
29
- debug(_data, _message) { }
30
- }
31
- /**
32
- * Global logger factory singleton
33
- */
34
- class LoggerFactory {
35
- config = {};
36
- loggers = new Map();
37
- /**
38
- * Configure the logger factory
39
- */
40
- configure(config) {
41
- this.config = config;
42
- // Clear cached loggers when reconfigured
43
- this.loggers.clear();
44
- }
45
- /**
46
- * Get or create a logger instance
47
- */
48
- getLogger(name) {
49
- // Check cache first
50
- if (this.loggers.has(name)) {
51
- return this.loggers.get(name);
52
- }
53
- // Create logger using factory or default
54
- let logger;
55
- if (this.config.loggerFactory) {
56
- logger = this.config.loggerFactory(name);
57
- }
58
- else if (this.config.defaultLogger) {
59
- logger = this.config.defaultLogger;
60
- }
61
- else {
62
- logger = new ConsoleLogger(name);
63
- }
64
- // Cache and return
65
- this.loggers.set(name, logger);
66
- return logger;
67
- }
68
- /**
69
- * Reset factory to default state
70
- */
71
- reset() {
72
- this.config = {};
73
- this.loggers.clear();
74
- }
75
- }
76
- // Export singleton instance
77
- export const loggerFactory = new LoggerFactory();
78
- /**
79
- * Convenience function to get a logger
80
- */
81
- export function getLogger(name) {
82
- return loggerFactory.getLogger(name);
83
- }
84
- /**
85
- * Configure the global logger factory
86
- * This should be called once at application startup
87
- *
88
- * Example usage:
89
- * ```typescript
90
- * // In your service initialization
91
- * import { configureLogging } from '@inkeep/agents-core';
92
- * import { getLogger as getPinoLogger } from './logger.j';
93
- *
94
- * configureLogging({
95
- * loggerFactory: (name) => getPinoLogger(name)
96
- * });
97
- * ```
98
- */
99
- export function configureLogging(config) {
100
- loggerFactory.configure(config);
101
- }
102
- //# sourceMappingURL=logger.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"logger.js","sourceRoot":"","sources":["../../src/utils/logger.ts"],"names":[],"mappings":"AAWA;;GAEG;AACH,MAAM,OAAO,aAAa;IACJ;IAApB,YAAoB,IAAY;QAAZ,SAAI,GAAJ,IAAI,CAAQ;IAAG,CAAC;IAEpC,KAAK,CAAC,IAAS,EAAE,OAAe;QAC9B,OAAO,CAAC,KAAK,CAAC,IAAI,IAAI,CAAC,IAAI,KAAK,OAAO,EAAE,EAAE,IAAI,CAAC,CAAC;IACnD,CAAC;IAED,IAAI,CAAC,IAAS,EAAE,OAAe;QAC7B,OAAO,CAAC,IAAI,CAAC,IAAI,IAAI,CAAC,IAAI,KAAK,OAAO,EAAE,EAAE,IAAI,CAAC,CAAC;IAClD,CAAC;IAED,IAAI,CAAC,IAAS,EAAE,OAAe;QAC7B,OAAO,CAAC,IAAI,CAAC,IAAI,IAAI,CAAC,IAAI,KAAK,OAAO,EAAE,EAAE,IAAI,CAAC,CAAC;IAClD,CAAC;IAED,KAAK,CAAC,IAAS,EAAE,OAAe;QAC9B,OAAO,CAAC,KAAK,CAAC,IAAI,IAAI,CAAC,IAAI,KAAK,OAAO,EAAE,EAAE,IAAI,CAAC,CAAC;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H,KAAK;QACH,IAAI,CAAC,MAAM,GAAG,EAAE,CAAC;QACjB,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,CAAC;IACvB,CAAC;CACF;AAED,4BAA4B;AAC5B,MAAM,CAAC,MAAM,aAAa,GAAG,IAAI,aAAa,EAAE,CAAC;AAEjD;;GAEG;AACH,MAAM,UAAU,SAAS,CAAC,IAAY;IACpC,OAAO,aAAa,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC;AACvC,CAAC;AAED;;;;;;;;;;;;;;GAcG;AACH,MAAM,UAAU,gBAAgB,CAAC,MAA2B;IAC1D,aAAa,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;AAClC,CAAC"}
@@ -1,11 +0,0 @@
1
- /**
2
- * Logger factory for core utilities package
3
- * Designed to work with Pino-style loggers and request context
4
- */
5
- export interface Logger {
6
- debug: (obj: any, msg?: string) => void;
7
- info: (obj: any, msg?: string) => void;
8
- warn: (obj: any, msg?: string) => void;
9
- error: (obj: any, msg?: string) => void;
10
- }
11
- //# sourceMappingURL=logging.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"logging.d.ts","sourceRoot":"","sources":["../../src/utils/logging.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,WAAW,MAAM;IACrB,KAAK,EAAE,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,IAAI,EAAE,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IACvC,IAAI,EAAE,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IACvC,KAAK,EAAE,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;CACzC"}
@@ -1,6 +0,0 @@
1
- /**
2
- * Logger factory for core utilities package
3
- * Designed to work with Pino-style loggers and request context
4
- */
5
- export {};
6
- //# sourceMappingURL=logging.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"logging.js","sourceRoot":"","sources":["../../src/utils/logging.ts"],"names":[],"mappings":"AAAA;;;GAGG"}
@@ -1,48 +0,0 @@
1
- import type { SSEClientTransportOptions } from '@modelcontextprotocol/sdk/client/sse.js';
2
- import type { StreamableHTTPClientTransportOptions } from '@modelcontextprotocol/sdk/client/streamableHttp.js';
3
- import { type ClientCapabilities } from '@modelcontextprotocol/sdk/types.js';
4
- interface SharedServerConfig {
5
- timeout?: number;
6
- activeTools?: string[];
7
- }
8
- export interface McpStreamableHttpConfig extends SharedServerConfig {
9
- type: 'streamable_http';
10
- url: string | URL;
11
- headers?: Record<string, string>;
12
- requestInit?: StreamableHTTPClientTransportOptions['requestInit'];
13
- eventSourceInit?: SSEClientTransportOptions['eventSourceInit'];
14
- reconnectionOptions?: StreamableHTTPClientTransportOptions['reconnectionOptions'];
15
- sessionId?: StreamableHTTPClientTransportOptions['sessionId'];
16
- }
17
- export interface McpSSEConfig extends SharedServerConfig {
18
- type: 'sse';
19
- url: string | URL;
20
- headers?: Record<string, string>;
21
- eventSourceInit?: SSEClientTransportOptions['eventSourceInit'];
22
- }
23
- export type McpServerConfig = McpStreamableHttpConfig | McpSSEConfig;
24
- export interface McpClientOptions {
25
- name: string;
26
- version?: string;
27
- server: McpServerConfig;
28
- capabilities?: ClientCapabilities;
29
- timeout?: number;
30
- }
31
- export declare class McpClient {
32
- name: string;
33
- private client;
34
- private readonly timeout;
35
- private transport?;
36
- private serverConfig;
37
- private connected;
38
- constructor(opts: McpClientOptions);
39
- connect(): Promise<void>;
40
- private connectSSE;
41
- private connectHttp;
42
- disconnect(): Promise<void>;
43
- private validateSelectedTools;
44
- private selectTools;
45
- tools(): Promise<Record<string, any>>;
46
- }
47
- export {};
48
- //# sourceMappingURL=mcp-client.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"mcp-client.d.ts","sourceRoot":"","sources":["../../src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