@frontmcp/sdk 0.9.0 → 0.11.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 (248) hide show
  1. package/adapter/adapter.instance.d.ts +10 -3
  2. package/adapter/adapter.instance.d.ts.map +1 -1
  3. package/adapter/{adapter.regsitry.d.ts → adapter.registry.d.ts} +2 -1
  4. package/adapter/adapter.registry.d.ts.map +1 -0
  5. package/adapter/adapter.utils.d.ts.map +1 -1
  6. package/agent/agent.instance.d.ts.map +1 -1
  7. package/agent/agent.scope.d.ts +9 -9
  8. package/agent/agent.scope.d.ts.map +1 -1
  9. package/agent/agent.utils.d.ts.map +1 -1
  10. package/app/app.registry.d.ts.map +1 -1
  11. package/app/app.utils.d.ts.map +1 -1
  12. package/app/instances/app.local.instance.d.ts +1 -1
  13. package/auth/auth.registry.d.ts +1 -1
  14. package/auth/auth.registry.d.ts.map +1 -1
  15. package/auth/auth.utils.d.ts.map +1 -1
  16. package/auth/authorization/index.d.ts +0 -6
  17. package/auth/authorization/index.d.ts.map +1 -1
  18. package/auth/authorization/orchestrated.context-extension.d.ts +1 -1
  19. package/auth/authorization/orchestrated.context-extension.d.ts.map +1 -1
  20. package/auth/flows/auth.verify.flow.d.ts +1 -1
  21. package/auth/flows/auth.verify.flow.d.ts.map +1 -1
  22. package/auth/flows/oauth.authorize.flow.d.ts.map +1 -1
  23. package/auth/flows/oauth.callback.flow.d.ts.map +1 -1
  24. package/auth/flows/oauth.provider-callback.flow.d.ts.map +1 -1
  25. package/auth/flows/session.verify.flow.d.ts +2 -2
  26. package/auth/flows/session.verify.flow.d.ts.map +1 -1
  27. package/auth/flows/well-known.jwks.flow.d.ts.map +1 -1
  28. package/auth/flows/well-known.oauth-authorization-server.flow.d.ts.map +1 -1
  29. package/auth/flows/well-known.prm.flow.d.ts.map +1 -1
  30. package/auth/instances/instance.local-primary-auth.d.ts +2 -2
  31. package/auth/instances/instance.local-primary-auth.d.ts.map +1 -1
  32. package/auth/session/index.d.ts +7 -11
  33. package/auth/session/index.d.ts.map +1 -1
  34. package/auth/session/record/session.base.d.ts +1 -1
  35. package/auth/session/record/session.base.d.ts.map +1 -1
  36. package/auth/session/session-store.factory.d.ts +19 -3
  37. package/auth/session/session-store.factory.d.ts.map +1 -1
  38. package/auth/session/session.service.d.ts +1 -1
  39. package/auth/session/session.service.d.ts.map +1 -1
  40. package/auth/session/transport-session.manager.d.ts +1 -1
  41. package/auth/session/transport-session.manager.d.ts.map +1 -1
  42. package/auth/session/utils/session-id.utils.d.ts +1 -2
  43. package/auth/session/utils/session-id.utils.d.ts.map +1 -1
  44. package/auth/vault/auth-providers.context-extension.d.ts +2 -2
  45. package/auth/vault/auth-providers.context-extension.d.ts.map +1 -1
  46. package/auth/vault/auth-providers.providers.d.ts +1 -1
  47. package/auth/vault/auth-providers.providers.d.ts.map +1 -1
  48. package/auth/vault/index.d.ts +0 -52
  49. package/auth/vault/index.d.ts.map +1 -1
  50. package/builtin/config/config-resolver.d.ts.map +1 -1
  51. package/common/decorators/app.decorator.d.ts +1 -1
  52. package/common/decorators/app.decorator.d.ts.map +1 -1
  53. package/common/decorators/front-mcp.decorator.d.ts.map +1 -1
  54. package/common/decorators/plugin.decorator.d.ts.map +1 -1
  55. package/common/dynamic/dynamic.adapter.d.ts.map +1 -1
  56. package/common/dynamic/dynamic.plugin.d.ts.map +1 -1
  57. package/common/interfaces/agent.interface.d.ts.map +1 -1
  58. package/common/interfaces/internal/flow.utils.d.ts.map +1 -1
  59. package/common/interfaces/server.interface.d.ts +4 -2
  60. package/common/interfaces/server.interface.d.ts.map +1 -1
  61. package/common/metadata/app.metadata.d.ts +16 -16
  62. package/common/metadata/front-mcp.metadata.d.ts +184 -52
  63. package/common/metadata/front-mcp.metadata.d.ts.map +1 -1
  64. package/common/providers/base-config.provider.d.ts.map +1 -1
  65. package/common/tokens/front-mcp.tokens.d.ts.map +1 -1
  66. package/common/types/auth/jwt.types.d.ts +2 -86
  67. package/common/types/auth/jwt.types.d.ts.map +1 -1
  68. package/common/types/auth/session.types.d.ts +5 -101
  69. package/common/types/auth/session.types.d.ts.map +1 -1
  70. package/common/types/options/auth/app-auth.schema.d.ts +8 -8
  71. package/common/types/options/auth/index.d.ts +14 -14
  72. package/common/types/options/auth/index.d.ts.map +1 -1
  73. package/common/types/options/auth/interfaces.d.ts +1 -1
  74. package/common/types/options/auth/interfaces.d.ts.map +1 -1
  75. package/common/types/options/auth/orchestrated.schema.d.ts +10 -10
  76. package/common/types/options/auth/public.schema.d.ts +2 -2
  77. package/common/types/options/auth/schema.d.ts +8 -8
  78. package/common/types/options/auth/shared.schemas.d.ts +2 -132
  79. package/common/types/options/auth/shared.schemas.d.ts.map +1 -1
  80. package/common/types/options/auth/transparent.schema.d.ts +1 -1
  81. package/common/types/options/http/index.d.ts +1 -1
  82. package/common/types/options/http/index.d.ts.map +1 -1
  83. package/common/types/options/http/interfaces.d.ts +36 -0
  84. package/common/types/options/http/interfaces.d.ts.map +1 -1
  85. package/common/types/options/http/schema.d.ts +6 -0
  86. package/common/types/options/http/schema.d.ts.map +1 -1
  87. package/common/types/options/index.d.ts +1 -0
  88. package/common/types/options/index.d.ts.map +1 -1
  89. package/common/types/options/session/schema.d.ts +3 -3
  90. package/common/types/options/sqlite/index.d.ts +3 -0
  91. package/common/types/options/sqlite/index.d.ts.map +1 -0
  92. package/common/types/options/sqlite/schema.d.ts +26 -0
  93. package/common/types/options/sqlite/schema.d.ts.map +1 -0
  94. package/common/types/options/transport/schema.d.ts +1 -1
  95. package/elicitation/store/elicitation-encryption.d.ts +1 -1
  96. package/elicitation/store/elicitation-encryption.d.ts.map +1 -1
  97. package/elicitation/store/elicitation-store.factory.d.ts +21 -1
  98. package/elicitation/store/elicitation-store.factory.d.ts.map +1 -1
  99. package/errors/auth-internal.errors.d.ts +2 -0
  100. package/errors/auth-internal.errors.d.ts.map +1 -0
  101. package/errors/decorator.errors.d.ts +14 -0
  102. package/errors/decorator.errors.d.ts.map +1 -0
  103. package/errors/index.d.ts +8 -1
  104. package/errors/index.d.ts.map +1 -1
  105. package/errors/normalization.errors.d.ts +32 -0
  106. package/errors/normalization.errors.d.ts.map +1 -0
  107. package/errors/provider.errors.d.ts +63 -0
  108. package/errors/provider.errors.d.ts.map +1 -0
  109. package/errors/registry.errors.d.ts +50 -0
  110. package/errors/registry.errors.d.ts.map +1 -0
  111. package/errors/remote.errors.d.ts +8 -0
  112. package/errors/remote.errors.d.ts.map +1 -1
  113. package/errors/sdk.errors.d.ts +139 -0
  114. package/errors/sdk.errors.d.ts.map +1 -0
  115. package/errors/transport.errors.d.ts +46 -0
  116. package/errors/transport.errors.d.ts.map +1 -0
  117. package/esm/index.mjs +7422 -8497
  118. package/esm/package.json +11 -7
  119. package/flows/flow.instance.d.ts.map +1 -1
  120. package/flows/flow.registry.d.ts.map +1 -1
  121. package/flows/flow.utils.d.ts.map +1 -1
  122. package/front-mcp/front-mcp.d.ts +30 -1
  123. package/front-mcp/front-mcp.d.ts.map +1 -1
  124. package/front-mcp/front-mcp.providers.d.ts +76 -20
  125. package/front-mcp/front-mcp.providers.d.ts.map +1 -1
  126. package/front-mcp/serverless-handler.d.ts +0 -4
  127. package/front-mcp/serverless-handler.d.ts.map +1 -1
  128. package/hooks/hook.instance.d.ts.map +1 -1
  129. package/hooks/hook.registry.d.ts.map +1 -1
  130. package/index.d.ts +1 -1
  131. package/index.js +19714 -20739
  132. package/logger/logger.registry.d.ts.map +1 -1
  133. package/logger/logger.utils.d.ts.map +1 -1
  134. package/package.json +11 -7
  135. package/plugin/plugin.utils.d.ts.map +1 -1
  136. package/prompt/prompt.instance.d.ts.map +1 -1
  137. package/prompt/prompt.registry.d.ts.map +1 -1
  138. package/prompt/prompt.utils.d.ts.map +1 -1
  139. package/provider/provider.registry.d.ts.map +1 -1
  140. package/provider/provider.utils.d.ts.map +1 -1
  141. package/regsitry/registry.base.d.ts.map +1 -1
  142. package/remote-mcp/mcp-client.service.d.ts.map +1 -1
  143. package/remote-mcp/resilience/retry.d.ts.map +1 -1
  144. package/resource/resource.instance.d.ts.map +1 -1
  145. package/resource/resource.registry.d.ts.map +1 -1
  146. package/resource/resource.utils.d.ts.map +1 -1
  147. package/scope/flows/http.request.flow.d.ts +1 -1
  148. package/scope/flows/http.request.flow.d.ts.map +1 -1
  149. package/scope/scope.instance.d.ts.map +1 -1
  150. package/scope/scope.registry.d.ts.map +1 -1
  151. package/scope/scope.utils.d.ts.map +1 -1
  152. package/server/adapters/base.host.adapter.d.ts +4 -2
  153. package/server/adapters/base.host.adapter.d.ts.map +1 -1
  154. package/server/adapters/express.host.adapter.d.ts +6 -32
  155. package/server/adapters/express.host.adapter.d.ts.map +1 -1
  156. package/server/server.instance.d.ts +1 -1
  157. package/server/server.instance.d.ts.map +1 -1
  158. package/skill/flows/search-skills.flow.d.ts +2 -2
  159. package/skill/session/skill-session.manager.d.ts.map +1 -1
  160. package/skill/skill.utils.d.ts.map +1 -1
  161. package/skill/tools/search-skills.tool.d.ts +1 -1
  162. package/tool/tool.instance.d.ts.map +1 -1
  163. package/tool/tool.registry.d.ts.map +1 -1
  164. package/tool/tool.utils.d.ts.map +1 -1
  165. package/transport/adapters/streamable-http-transport.d.ts +9 -3
  166. package/transport/adapters/streamable-http-transport.d.ts.map +1 -1
  167. package/transport/event-stores/event-store.factory.d.ts +8 -3
  168. package/transport/event-stores/event-store.factory.d.ts.map +1 -1
  169. package/transport/event-stores/redis.event-store.d.ts.map +1 -1
  170. package/transport/flows/handle.sse.flow.d.ts +1 -1
  171. package/transport/flows/handle.streamable-http.flow.d.ts +1 -1
  172. package/transport/legacy/legacy.sse.tranporter.d.ts.map +1 -1
  173. package/transport/mcp-handlers/skills-mcp.types.d.ts +1 -1
  174. package/transport/transport.local.d.ts.map +1 -1
  175. package/transport/transport.registry.d.ts +1 -1
  176. package/transport/transport.registry.d.ts.map +1 -1
  177. package/transport/transport.remote.d.ts.map +1 -1
  178. package/adapter/adapter.regsitry.d.ts.map +0 -1
  179. package/auth/authorization/authorization.class.d.ts +0 -123
  180. package/auth/authorization/authorization.class.d.ts.map +0 -1
  181. package/auth/authorization/authorization.types.d.ts +0 -128
  182. package/auth/authorization/authorization.types.d.ts.map +0 -1
  183. package/auth/authorization/orchestrated.accessor.d.ts +0 -161
  184. package/auth/authorization/orchestrated.accessor.d.ts.map +0 -1
  185. package/auth/authorization/orchestrated.authorization.d.ts +0 -258
  186. package/auth/authorization/orchestrated.authorization.d.ts.map +0 -1
  187. package/auth/authorization/public.authorization.d.ts +0 -92
  188. package/auth/authorization/public.authorization.d.ts.map +0 -1
  189. package/auth/authorization/transparent.authorization.d.ts +0 -131
  190. package/auth/authorization/transparent.authorization.d.ts.map +0 -1
  191. package/auth/consent/consent.types.d.ts +0 -112
  192. package/auth/consent/consent.types.d.ts.map +0 -1
  193. package/auth/consent/index.d.ts +0 -2
  194. package/auth/consent/index.d.ts.map +0 -1
  195. package/auth/detection/auth-provider-detection.d.ts +0 -85
  196. package/auth/detection/auth-provider-detection.d.ts.map +0 -1
  197. package/auth/detection/index.d.ts +0 -2
  198. package/auth/detection/index.d.ts.map +0 -1
  199. package/auth/machine-id.d.ts +0 -28
  200. package/auth/machine-id.d.ts.map +0 -1
  201. package/auth/session/encrypted-authorization-vault.d.ts +0 -181
  202. package/auth/session/encrypted-authorization-vault.d.ts.map +0 -1
  203. package/auth/session/federated-auth.session.d.ts +0 -252
  204. package/auth/session/federated-auth.session.d.ts.map +0 -1
  205. package/auth/session/orchestrated-token.store.d.ts +0 -155
  206. package/auth/session/orchestrated-token.store.d.ts.map +0 -1
  207. package/auth/session/redis-session.store.d.ts +0 -93
  208. package/auth/session/redis-session.store.d.ts.map +0 -1
  209. package/auth/session/session-crypto.d.ts +0 -84
  210. package/auth/session/session-crypto.d.ts.map +0 -1
  211. package/auth/session/session-rate-limiter.d.ts +0 -114
  212. package/auth/session/session-rate-limiter.d.ts.map +0 -1
  213. package/auth/session/session.transport.d.ts +0 -11
  214. package/auth/session/session.transport.d.ts.map +0 -1
  215. package/auth/session/session.types.d.ts +0 -66
  216. package/auth/session/session.types.d.ts.map +0 -1
  217. package/auth/session/token.refresh.d.ts +0 -60
  218. package/auth/session/token.refresh.d.ts.map +0 -1
  219. package/auth/session/transport-session.types.d.ts +0 -479
  220. package/auth/session/transport-session.types.d.ts.map +0 -1
  221. package/auth/session/utils/auth-token.utils.d.ts +0 -12
  222. package/auth/session/utils/auth-token.utils.d.ts.map +0 -1
  223. package/auth/session/vercel-kv-session.store.d.ts +0 -117
  224. package/auth/session/vercel-kv-session.store.d.ts.map +0 -1
  225. package/auth/ui/base-layout.d.ts +0 -181
  226. package/auth/ui/base-layout.d.ts.map +0 -1
  227. package/auth/ui/index.d.ts +0 -11
  228. package/auth/ui/index.d.ts.map +0 -1
  229. package/auth/ui/templates.d.ts +0 -135
  230. package/auth/ui/templates.d.ts.map +0 -1
  231. package/auth/utils/authorization-id.utils.d.ts +0 -12
  232. package/auth/utils/authorization-id.utils.d.ts.map +0 -1
  233. package/auth/utils/index.d.ts +0 -2
  234. package/auth/utils/index.d.ts.map +0 -1
  235. package/auth/vault/auth-providers.accessor.d.ts +0 -153
  236. package/auth/vault/auth-providers.accessor.d.ts.map +0 -1
  237. package/auth/vault/auth-providers.accessor.impl.d.ts +0 -52
  238. package/auth/vault/auth-providers.accessor.impl.d.ts.map +0 -1
  239. package/auth/vault/auth-providers.registry.d.ts +0 -110
  240. package/auth/vault/auth-providers.registry.d.ts.map +0 -1
  241. package/auth/vault/auth-providers.vault.d.ts +0 -93
  242. package/auth/vault/auth-providers.vault.d.ts.map +0 -1
  243. package/auth/vault/credential-loaders/eager-loader.d.ts +0 -46
  244. package/auth/vault/credential-loaders/eager-loader.d.ts.map +0 -1
  245. package/auth/vault/credential-loaders/index.d.ts +0 -7
  246. package/auth/vault/credential-loaders/index.d.ts.map +0 -1
  247. package/auth/vault/credential-loaders/lazy-loader.d.ts +0 -53
  248. package/auth/vault/credential-loaders/lazy-loader.d.ts.map +0 -1
@@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itry.d.ts","sourceRoot":"","sources":["../../src/adapter/adapter.regsitry.ts"],"names":[],"mappings":"AAAA,OAAO,kBAAkB,CAAC;AAE1B,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,wBAAwB,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAE/F,OAAO,gBAAgB,MAAM,+BAA+B,CAAC;AAC7D,OAAO,EAAE,gBAAgB,EAAE,sBAAsB,EAAE,MAAM,aAAa,CAAC;AACvE,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD,MAAM,CAAC,OAAO,OAAO,eACnB,SAAQ,gBAAgB,CAAC,eAAe,EAAE,aAAa,EAAE,WAAW,EAAE,CACtE,YAAW,wBAAwB;gBAEvB,SAAS,EAAE,gBAAgB,EAAE,IAAI,EAAE,WAAW,EAAE;cAIzC,QAAQ,CAAC,IAAI,EAAE,WAAW,EAAE,GAAG,sBAAsB,CAAC,aAAa,CAAC;IAgBvF,SAAS,CAAC,UAAU;IAcpB,0EAA0E;cAC1D,UAAU,IAAI,OAAO,CAAC,IAAI,CAAC;IAc3C,WAAW,IAAI,YAAY,EAAE;CAG9B"}
@@ -1,123 +0,0 @@
1
- import { Authorization, AuthorizationCreateCtx, AuthorizedPrompt, AuthorizedTool, AuthUser, LLMSafeAuthContext } from './authorization.types';
2
- import { TransportSession, TransportProtocol } from '../session';
3
- import { ProviderSnapshot } from '../session/session.types';
4
- import { AuthMode } from '../../common';
5
- export { getMachineId } from '../machine-id';
6
- /**
7
- * Base Authorization class - represents authenticated user context
8
- * Subclasses implement mode-specific behavior (Public, Transparent, Orchestrated)
9
- */
10
- export declare abstract class AuthorizationBase implements Authorization {
11
- #private;
12
- readonly id: string;
13
- abstract readonly mode: AuthMode;
14
- readonly isAnonymous: boolean;
15
- readonly user: AuthUser;
16
- readonly claims?: Record<string, unknown>;
17
- readonly expiresAt?: number;
18
- readonly scopes: string[];
19
- readonly authorizedProviders: Record<string, ProviderSnapshot>;
20
- readonly authorizedProviderIds: string[];
21
- readonly authorizedApps: Record<string, {
22
- id: string;
23
- toolIds: string[];
24
- }>;
25
- readonly authorizedAppIds: string[];
26
- readonly authorizedTools: Record<string, AuthorizedTool>;
27
- readonly authorizedToolIds: string[];
28
- readonly authorizedPrompts: Record<string, AuthorizedPrompt>;
29
- readonly authorizedPromptIds: string[];
30
- readonly authorizedResources: string[];
31
- /** The original bearer token (for transparent mode) */
32
- protected readonly token?: string;
33
- /** Creation timestamp */
34
- readonly createdAt: number;
35
- protected constructor(ctx: AuthorizationCreateCtx);
36
- /**
37
- * Create a new transport session for this authorization
38
- * @param protocol - Transport protocol (sse, streamable-http, etc.)
39
- * @param fingerprint - Optional client fingerprint for tracking
40
- */
41
- createTransportSession(protocol: TransportProtocol, fingerprint?: string): TransportSession;
42
- /**
43
- * Get existing transport session by ID
44
- */
45
- getTransportSession(sessionId: string): TransportSession | undefined;
46
- /**
47
- * Get all active transport sessions
48
- */
49
- getAllSessions(): TransportSession[];
50
- /**
51
- * Remove a transport session
52
- */
53
- removeTransportSession(sessionId: string): boolean;
54
- /**
55
- * Get count of active sessions
56
- */
57
- get sessionCount(): number;
58
- /**
59
- * Abstract: Get access token for a provider
60
- * Implementation varies by mode:
61
- * - Public: throws (no tokens)
62
- * - Transparent: returns the original bearer token
63
- * - Orchestrated: retrieves from vault/store
64
- */
65
- abstract getToken(providerId?: string): Promise<string>;
66
- /**
67
- * Check if a scope is granted
68
- */
69
- hasScope(scope: string): boolean;
70
- /**
71
- * Check if all scopes are granted
72
- */
73
- hasAllScopes(scopes: string[]): boolean;
74
- /**
75
- * Check if any scope is granted
76
- */
77
- hasAnyScope(scopes: string[]): boolean;
78
- /**
79
- * Check if a tool is authorized
80
- */
81
- canAccessTool(toolId: string): boolean;
82
- /**
83
- * Check if a prompt is authorized
84
- */
85
- canAccessPrompt(promptId: string): boolean;
86
- /**
87
- * Check if an app is authorized.
88
- * Used for progressive authorization to determine if tools from this app can be executed.
89
- * @param appId - App ID to check
90
- */
91
- isAppAuthorized(appId: string): boolean;
92
- /**
93
- * Build URL for progressive/incremental authorization.
94
- * Used when a tool requires authorization for an app that was skipped during initial auth.
95
- * @param appId - App ID that requires authorization
96
- * @param baseUrl - Base URL of the server
97
- */
98
- getProgressiveAuthUrl(appId: string, baseUrl: string): string;
99
- /**
100
- * Check if the authorization is expired
101
- */
102
- isExpired(): boolean;
103
- /**
104
- * Get time until expiration in milliseconds
105
- * Returns undefined if no expiration, negative if expired
106
- */
107
- getTimeToExpiry(): number | undefined;
108
- /**
109
- * Convert a transport session to encrypted session JWT
110
- * This is what gets sent in the Mcp-Session-Id header
111
- */
112
- toSessionJwt(session: TransportSession): string;
113
- /**
114
- * Convert to LLM-safe context (no tokens exposed)
115
- */
116
- toLLMSafeContext(session: TransportSession): LLMSafeAuthContext;
117
- /**
118
- * Validate that no tokens are leaked in data
119
- * Throws if JWT pattern detected
120
- */
121
- static validateNoTokenLeakage(data: unknown): void;
122
- }
123
- //# sourceMappingURL=authorization.class.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"authorization.class.d.ts","sourceRoot":"","sources":["../../../src/auth/authorization/authorization.class.ts"],"names":[],"mappings":"AAGA,OAAO,EACL,aAAa,EACb,sBAAsB,EACtB,gBAAgB,EAChB,cAAc,EACd,QAAQ,EACR,kBAAkB,EACnB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,gBAAgB,EAAE,iBAAiB,EAAqB,MAAM,YAAY,CAAC;AACpF,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAE5D,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AAIxC,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAE7C;;;GAGG;AACH,8BAAsB,iBAAkB,YAAW,aAAa;;IAC9D,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,QAAQ,CAAC,IAAI,EAAE,QAAQ,CAAC;IACjC,QAAQ,CAAC,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AG,SAAS;IAIpE;;OAEG;IACH,cAAc,IAAI,gBAAgB,EAAE;IAIpC;;OAEG;IACH,sBAAsB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO;IAIlD;;OAEG;IACH,IAAI,YAAY,IAAI,MAAM,CAEzB;IAED;;;;;;OAMG;IACH,QAAQ,CAAC,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAEvD;;OAEG;IACH,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO;IAIhC;;OAEG;IACH,YAAY,CAAC,MAAM,EAAE,MAAM,EAAE,GAAG,OAAO;IAIvC;;OAEG;IACH,WAAW,CAAC,MAAM,EAAE,MAAM,EAAE,GAAG,OAAO;IAItC;;OAEG;IACH,aAAa,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO;IAItC;;OAEG;IACH,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO;IAI1C;;;;OAIG;IACH,eAAe,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO;IAIvC;;;;;OAKG;IACH,qBAAqB,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM;IAI7D;;OAEG;IACH,SAAS,IAAI,OAAO;IAKpB;;;OAGG;IACH,eAAe,IAAI,MAAM,GAAG,SAAS;IAKrC;;;OAGG;IACH,YAAY,CAAC,OAAO,EAAE,gBAAgB,GAAG,MAAM;IAY/C;;OAEG;IACH,gBAAgB,CAAC,OAAO,EAAE,gBAAgB,GAAG,kBAAkB;IAgB/D;;;OAGG;IACH,MAAM,CAAC,sBAAsB,CAAC,IAAI,EAAE,OAAO,GAAG,IAAI;CAcnD"}
@@ -1,128 +0,0 @@
1
- export { type AuthMode, type AuthUser, type AuthorizedTool, type AuthorizedPrompt, type LLMSafeAuthContext, type AppAuthorizationRecord, type ProgressiveAuthState, type AuthorizationCreateCtx as BaseAuthorizationCreateCtx, AppAuthState, authModeSchema, authUserSchema, authorizedToolSchema, authorizedPromptSchema, llmSafeAuthContextSchema, appAuthStateSchema, appAuthorizationRecordSchema, progressiveAuthStateSchema, } from '@frontmcp/auth';
2
- import type { ProviderSnapshot } from '../session/session.types';
3
- import type { TransportSession, TransportProtocol } from '../session';
4
- import type { AuthMode, AuthUser, AuthorizedTool, AuthorizedPrompt } from '@frontmcp/auth';
5
- /**
6
- * Authorization represents the authenticated user context (SDK-specific).
7
- * Created from JWT verification, independent of transport.
8
- * One authorization can have multiple transport sessions.
9
- */
10
- export interface Authorization {
11
- /** Unique authorization ID (derived from token signature) */
12
- readonly id: string;
13
- /** Auth mode that created this authorization */
14
- readonly mode: AuthMode;
15
- /** Whether this is an anonymous/public authorization */
16
- readonly isAnonymous: boolean;
17
- /** User identity */
18
- readonly user: AuthUser;
19
- /** JWT claims */
20
- readonly claims?: Record<string, unknown>;
21
- /** Token expiration (epoch ms) */
22
- readonly expiresAt?: number;
23
- /** Granted scopes */
24
- readonly scopes: string[];
25
- /** Authorized providers (for orchestrated mode) */
26
- readonly authorizedProviders: Record<string, ProviderSnapshot>;
27
- /** Authorized provider IDs */
28
- readonly authorizedProviderIds: string[];
29
- /** Authorized apps */
30
- readonly authorizedApps: Record<string, {
31
- id: string;
32
- toolIds: string[];
33
- }>;
34
- /** Authorized app IDs */
35
- readonly authorizedAppIds: string[];
36
- /** Authorized tools */
37
- readonly authorizedTools: Record<string, AuthorizedTool>;
38
- /** Authorized tool IDs */
39
- readonly authorizedToolIds: string[];
40
- /** Authorized prompts */
41
- readonly authorizedPrompts: Record<string, AuthorizedPrompt>;
42
- /** Authorized prompt IDs */
43
- readonly authorizedPromptIds: string[];
44
- /** Authorized resources */
45
- readonly authorizedResources: string[];
46
- /**
47
- * Get access token for a provider (orchestrated mode)
48
- * @param providerId - Provider ID, defaults to primary
49
- */
50
- getToken(providerId?: string): Promise<string>;
51
- /**
52
- * Create a new transport session for this authorization
53
- * @param protocol - Transport protocol (sse, streamable-http, etc.)
54
- * @param fingerprint - Optional client fingerprint for tracking
55
- */
56
- createTransportSession(protocol: TransportProtocol, fingerprint?: string): TransportSession;
57
- /**
58
- * Get existing transport session by ID
59
- * @param sessionId - Session ID to retrieve
60
- */
61
- getTransportSession(sessionId: string): TransportSession | undefined;
62
- /**
63
- * Check if a scope is granted
64
- * @param scope - Scope to check
65
- */
66
- hasScope(scope: string): boolean;
67
- /**
68
- * Check if all scopes are granted
69
- * @param scopes - Scopes to check
70
- */
71
- hasAllScopes(scopes: string[]): boolean;
72
- /**
73
- * Check if any scope is granted
74
- * @param scopes - Scopes to check
75
- */
76
- hasAnyScope(scopes: string[]): boolean;
77
- /**
78
- * Check if a tool is authorized
79
- * @param toolId - Tool ID to check
80
- */
81
- canAccessTool(toolId: string): boolean;
82
- /**
83
- * Check if a prompt is authorized
84
- * @param promptId - Prompt ID to check
85
- */
86
- canAccessPrompt(promptId: string): boolean;
87
- }
88
- /**
89
- * Context for creating an authorization (SDK-specific, includes ProviderSnapshot)
90
- */
91
- export interface AuthorizationCreateCtx {
92
- /** Unique ID (typically token signature fingerprint) */
93
- id: string;
94
- /** Whether this is anonymous */
95
- isAnonymous: boolean;
96
- /** User identity */
97
- user: AuthUser;
98
- /** JWT claims */
99
- claims?: Record<string, unknown>;
100
- /** Token expiration (epoch ms) */
101
- expiresAt?: number;
102
- /** Granted scopes */
103
- scopes?: string[];
104
- /** The original token (for transparent mode) */
105
- token?: string;
106
- /** Authorized providers (SDK-specific, uses ProviderSnapshot) */
107
- authorizedProviders?: Record<string, ProviderSnapshot>;
108
- /** Authorized provider IDs */
109
- authorizedProviderIds?: string[];
110
- /** Authorized apps */
111
- authorizedApps?: Record<string, {
112
- id: string;
113
- toolIds: string[];
114
- }>;
115
- /** Authorized app IDs */
116
- authorizedAppIds?: string[];
117
- /** Authorized tools */
118
- authorizedTools?: Record<string, AuthorizedTool>;
119
- /** Authorized tool IDs */
120
- authorizedToolIds?: string[];
121
- /** Authorized prompts */
122
- authorizedPrompts?: Record<string, AuthorizedPrompt>;
123
- /** Authorized prompt IDs */
124
- authorizedPromptIds?: string[];
125
- /** Authorized resources */
126
- authorizedResources?: string[];
127
- }
128
- //# sourceMappingURL=authorization.types.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"authorization.types.d.ts","sourceRoot":"","sources":["../../../src/auth/authorization/authorization.types.ts"],"names":[],"mappings":"AAGA,OAAO,EACL,KAAK,QAAQ,EACb,KAAK,QAAQ,EACb,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,EACvB,KAAK,sBAAsB,EAC3B,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,IAAI,0BAA0B,EACzD,YAAY,EACZ,cAAc,EACd,cAAc,EACd,oBAAoB,EACpB,sBAAsB,EACtB,wBAAwB,EACxB,kBAAkB,EAClB,4BAA4B,EAC5B,0BAA0B,GAC3B,MAAM,gBAAgB,CAAC;AAGxB,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AACjE,OAAO,KAAK,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AACtE,OAAO,KAAK,EAAE,QAAQ,EAAE,QAAQ,EAAE,cAAc,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAM3F;;;;GAIG;AACH,MAAM,WAAW,aAAa;IAC5B,6DAA6D;IAC7D,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IAEpB,gDAAgD;IAChD,QAAQ,CAAC,IAAI,EAAE,QAAQ,CAAC;IAExB,wDAAwD;IACxD,QAAQ,CAAC,WAAW,EAAE,OAAO,CAAC;IAE9B,oBAAoB;IACpB,QAAQ,CAAC,IAAI,EAAE,QAAQ,CAAC;IAExB,iBAAiB;IACjB,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAE1C,kCAAkC;IAClC,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAE5B,qBAA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rD,4BAA4B;IAC5B,mBAAmB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC/B,2BAA2B;IAC3B,mBAAmB,CAAC,EAAE,MAAM,EAAE,CAAC;CAChC"}
@@ -1,161 +0,0 @@
1
- /**
2
- * OrchestratedAuthAccessor - Interface for accessing orchestrated authorization
3
- *
4
- * This interface provides the runtime API for tools to access upstream provider
5
- * tokens in orchestrated mode. It supports:
6
- * - Token retrieval by provider ID
7
- * - App token retrieval for progressive auth
8
- * - Automatic token refresh
9
- * - Authorization checks
10
- */
11
- import { Token } from '@frontmcp/di';
12
- /**
13
- * OrchestratedAuthAccessor - Runtime accessor for orchestrated authorization.
14
- *
15
- * Available in tool execution via `this.orchestration`:
16
- * ```typescript
17
- * @Tool({ name: 'my_tool' })
18
- * class MyTool extends ToolContext {
19
- * async execute(input: Input) {
20
- * // Get upstream provider token
21
- * const githubToken = await this.orchestration.getToken('github');
22
- *
23
- * // Check if provider is authorized
24
- * const hasSlack = await this.orchestration.hasProvider('slack');
25
- *
26
- * // Get app-specific token (progressive auth)
27
- * const jiraToken = await this.orchestration.getAppToken('jira');
28
- * }
29
- * }
30
- * ```
31
- */
32
- export interface OrchestratedAuthAccessor {
33
- /**
34
- * Get access token for an upstream provider.
35
- *
36
- * @param providerId - Provider ID (e.g., 'github', 'slack')
37
- * @returns Access token string
38
- * @throws Error if provider not authorized or token unavailable
39
- *
40
- * @example
41
- * ```typescript
42
- * const token = await this.orchestration.getToken('github');
43
- * const response = await fetch('https://api.github.com/user', {
44
- * headers: { Authorization: `Bearer ${token}` },
45
- * });
46
- * ```
47
- */
48
- getToken(providerId?: string): Promise<string>;
49
- /**
50
- * Try to get access token, returning null if not available.
51
- *
52
- * @param providerId - Provider ID
53
- * @returns Access token or null
54
- */
55
- tryGetToken(providerId?: string): Promise<string | null>;
56
- /**
57
- * Get access token for a specific app (progressive authorization).
58
- *
59
- * @param appId - App ID
60
- * @returns Access token or null if app not authorized
61
- */
62
- getAppToken(appId: string): Promise<string | null>;
63
- /**
64
- * Check if a provider is authorized.
65
- *
66
- * @param providerId - Provider ID
67
- * @returns true if provider has tokens stored
68
- */
69
- hasProvider(providerId: string): boolean;
70
- /**
71
- * Get all authorized provider IDs.
72
- */
73
- getProviderIds(): string[];
74
- /**
75
- * Check if an app is authorized.
76
- *
77
- * @param appId - App ID
78
- * @returns true if app is authorized
79
- */
80
- isAppAuthorized(appId: string): boolean;
81
- /**
82
- * Get all authorized app IDs.
83
- */
84
- getAllAuthorizedAppIds(): string[];
85
- /**
86
- * Get tool IDs authorized through a specific app.
87
- *
88
- * @param appId - App ID
89
- * @returns Tool IDs or undefined if app not authorized
90
- */
91
- getAppToolIds(appId: string): string[] | undefined;
92
- /**
93
- * Get the primary provider ID (default for getToken).
94
- */
95
- readonly primaryProviderId?: string;
96
- /**
97
- * Get the issuer (local orchestrator).
98
- */
99
- readonly issuer?: string;
100
- /**
101
- * Get authorization ID.
102
- */
103
- readonly authorizationId: string;
104
- /**
105
- * Check if user is authenticated (not anonymous).
106
- */
107
- readonly isAuthenticated: boolean;
108
- }
109
- /**
110
- * DI Token for OrchestratedAuthAccessor
111
- */
112
- export declare const ORCHESTRATED_AUTH_ACCESSOR: Token<OrchestratedAuthAccessor>;
113
- /**
114
- * Null implementation for when orchestrated auth is not available.
115
- */
116
- export declare class NullOrchestratedAuthAccessor implements OrchestratedAuthAccessor {
117
- readonly primaryProviderId: undefined;
118
- readonly issuer: undefined;
119
- readonly authorizationId = "null";
120
- readonly isAuthenticated = false;
121
- getToken(providerId?: string): Promise<string>;
122
- tryGetToken(providerId?: string): Promise<string | null>;
123
- getAppToken(appId: string): Promise<string | null>;
124
- hasProvider(providerId: string): boolean;
125
- getProviderIds(): string[];
126
- isAppAuthorized(appId: string): boolean;
127
- getAllAuthorizedAppIds(): string[];
128
- getAppToolIds(appId: string): string[] | undefined;
129
- }
130
- /**
131
- * Adapter that wraps OrchestratedAuthorization as OrchestratedAuthAccessor.
132
- */
133
- export declare class OrchestratedAuthAccessorAdapter implements OrchestratedAuthAccessor {
134
- private readonly authorization;
135
- constructor(authorization: {
136
- readonly id: string;
137
- readonly isAnonymous: boolean;
138
- readonly primaryProviderId?: string;
139
- readonly issuer?: string;
140
- hasProvider(providerId: string): boolean;
141
- getProviderIds(): string[];
142
- getToken(providerId?: string): Promise<string>;
143
- getAppToken(appId: string): Promise<string | null>;
144
- isAppAuthorized(appId: string): boolean;
145
- getAllAuthorizedAppIds(): string[];
146
- getAppToolIds(appId: string): string[] | undefined;
147
- });
148
- get primaryProviderId(): string | undefined;
149
- get issuer(): string | undefined;
150
- get authorizationId(): string;
151
- get isAuthenticated(): boolean;
152
- getToken(providerId?: string): Promise<string>;
153
- tryGetToken(providerId?: string): Promise<string | null>;
154
- getAppToken(appId: string): Promise<string | null>;
155
- hasProvider(providerId: string): boolean;
156
- getProviderIds(): string[];
157
- isAppAuthorized(appId: string): boolean;
158
- getAllAuthorizedAppIds(): string[];
159
- getAppToolIds(appId: string): string[] | undefined;
160
- }
161
- //# sourceMappingURL=orchestrated.accessor.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"orchestrated.accessor.d.ts","sourceRoot":"","sources":["../../../src/auth/authorization/orchestrated.accessor.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AAErC;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,WAAW,wBAAwB;IACvC;;;;;;;;;;;;;;OAcG;IACH,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;IAE/C;;;;;OAKG;IACH,WAAW,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;IAEzD;;;;;OAKG;IACH,WAAW,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;IAEnD;;;;;OAKG;IAC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