@kya-os/mcp-i 1.5.1 → 1.5.3-canary.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.
- package/dist/compiler/config/injection.d.ts +5 -1
- package/dist/compiler/config/injection.js +25 -0
- package/dist/compiler/get-webpack-config/get-injected-variables.js +2 -0
- package/dist/runtime/adapter-express.js +1 -1
- package/dist/runtime/adapter-nextjs.js +1 -1
- package/dist/runtime/auth-handshake.d.ts +2 -0
- package/dist/runtime/auth-handshake.js +2 -3
- package/dist/runtime/http.js +1 -1
- package/dist/runtime/index.d.ts +2 -0
- package/dist/runtime/index.js +13 -1
- package/dist/runtime/mcpi-runtime.d.ts +16 -0
- package/dist/runtime/mcpi-runtime.js +63 -0
- package/dist/runtime/proof-batch-queue.d.ts +3 -0
- package/dist/runtime/proof-batch-queue.js +21 -4
- package/dist/runtime/proof.d.ts +8 -6
- package/dist/runtime/proof.js +35 -16
- package/dist/runtime/request-context.d.ts +37 -0
- package/dist/runtime/request-context.js +56 -0
- package/dist/runtime/session.js +1 -0
- package/dist/runtime/stdio.js +1 -1
- package/dist/runtime/tool-protection-registry.d.ts +94 -0
- package/dist/runtime/tool-protection-registry.js +140 -0
- package/dist/runtime/tool-protection.d.ts +120 -0
- package/dist/runtime/tool-protection.js +192 -0
- package/dist/runtime/transports/http/index.js +2 -1
- package/dist/runtime/utils/tools.js +293 -76
- package/package.json +1 -1
|
@@ -42,6 +42,8 @@ export interface AgentReputation {
|
|
|
42
42
|
export interface AuthHandshakeConfig {
|
|
43
43
|
/** Delegation verifier instance */
|
|
44
44
|
delegationVerifier: DelegationVerifier;
|
|
45
|
+
/** Resume token store (REQUIRED to persist tokens across calls) */
|
|
46
|
+
resumeTokenStore: ResumeTokenStore;
|
|
45
47
|
/** KTA API configuration (optional, for reputation checks) */
|
|
46
48
|
kta?: {
|
|
47
49
|
apiUrl: string;
|
|
@@ -205,9 +205,8 @@ async function fetchAgentReputation(agentDid, ktaConfig) {
|
|
|
205
205
|
* @returns NeedsAuthorizationError
|
|
206
206
|
*/
|
|
207
207
|
async function buildNeedsAuthorizationError(agentDid, scopes, config, message) {
|
|
208
|
-
//
|
|
209
|
-
const
|
|
210
|
-
const resumeToken = await resumeTokenStore.create(agentDid, scopes, {
|
|
208
|
+
// Use the persistent resume token store from config
|
|
209
|
+
const resumeToken = await config.resumeTokenStore.create(agentDid, scopes, {
|
|
211
210
|
requestedAt: Date.now(),
|
|
212
211
|
});
|
|
213
212
|
const expiresAt = Date.now() + (config.bouncer.resumeTokenTtl || 600_000);
|