@oobe-protocol-labs/sap-mcp-server 0.9.2 → 0.9.3
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/.env.example +8 -7
- package/CHANGELOG.md +731 -0
- package/README.md +9 -3
- package/USER_DOCS/00_START_HERE.md +51 -4
- package/USER_DOCS/01_HOSTED_REMOTE_MCP.md +1 -1
- package/USER_DOCS/03_PAYMENTS_X402_PAYSH.md +32 -3
- package/USER_DOCS/04_CLIENT_CONFIGS.md +14 -7
- package/USER_DOCS/05_SKILLS_AND_TOOLS.md +68 -8
- package/USER_DOCS/06_DESKTOP_GUI_WIZARD.md +20 -14
- package/USER_DOCS/07_SMITHERY_AND_MARKETPLACES.md +7 -0
- package/config.example.json +5 -4
- package/config.schema.json +9 -4
- package/config.secure-example.json +5 -4
- package/dist/adapters/index.d.ts +7 -1
- package/dist/adapters/index.d.ts.map +1 -1
- package/dist/adapters/index.js +7 -1
- package/dist/adapters/index.js.map +1 -1
- package/dist/adapters/mcp/errors.d.ts +13 -1
- package/dist/adapters/mcp/errors.d.ts.map +1 -1
- package/dist/adapters/mcp/errors.js +13 -1
- package/dist/adapters/mcp/errors.js.map +1 -1
- package/dist/adapters/mcp/index.d.ts +7 -1
- package/dist/adapters/mcp/index.d.ts.map +1 -1
- package/dist/adapters/mcp/index.js +7 -1
- package/dist/adapters/mcp/index.js.map +1 -1
- package/dist/adapters/mcp/prompt-response.d.ts +13 -1
- package/dist/adapters/mcp/prompt-response.d.ts.map +1 -1
- package/dist/adapters/mcp/prompt-response.js +13 -1
- package/dist/adapters/mcp/prompt-response.js.map +1 -1
- package/dist/adapters/mcp/resource-response.d.ts +14 -1
- package/dist/adapters/mcp/resource-response.d.ts.map +1 -1
- package/dist/adapters/mcp/resource-response.js +14 -1
- package/dist/adapters/mcp/resource-response.js.map +1 -1
- package/dist/adapters/mcp/sdk-compat.d.ts +11 -3
- package/dist/adapters/mcp/sdk-compat.d.ts.map +1 -1
- package/dist/adapters/mcp/sdk-compat.js +232 -25
- package/dist/adapters/mcp/sdk-compat.js.map +1 -1
- package/dist/adapters/mcp/tool-response.d.ts +51 -3
- package/dist/adapters/mcp/tool-response.d.ts.map +1 -1
- package/dist/adapters/mcp/tool-response.js +48 -3
- package/dist/adapters/mcp/tool-response.js.map +1 -1
- package/dist/adapters/solana/commitment.d.ts +14 -2
- package/dist/adapters/solana/commitment.d.ts.map +1 -1
- package/dist/adapters/solana/commitment.js +14 -2
- package/dist/adapters/solana/commitment.js.map +1 -1
- package/dist/adapters/solana/connection.d.ts +11 -2
- package/dist/adapters/solana/connection.d.ts.map +1 -1
- package/dist/adapters/solana/connection.js +11 -2
- package/dist/adapters/solana/connection.js.map +1 -1
- package/dist/adapters/solana/index.d.ts +7 -1
- package/dist/adapters/solana/index.d.ts.map +1 -1
- package/dist/adapters/solana/index.js +7 -1
- package/dist/adapters/solana/index.js.map +1 -1
- package/dist/adapters/solana/public-key.d.ts +11 -2
- package/dist/adapters/solana/public-key.d.ts.map +1 -1
- package/dist/adapters/solana/public-key.js +11 -2
- package/dist/adapters/solana/public-key.js.map +1 -1
- package/dist/config/defaults.d.ts +5 -0
- package/dist/config/defaults.d.ts.map +1 -1
- package/dist/config/defaults.js +5 -0
- package/dist/config/defaults.js.map +1 -1
- package/dist/config/env.d.ts +4 -0
- package/dist/config/env.d.ts.map +1 -1
- package/dist/config/env.js +15 -10
- package/dist/config/env.js.map +1 -1
- package/dist/config/index.d.ts +5 -0
- package/dist/config/index.d.ts.map +1 -1
- package/dist/config/index.js +5 -0
- package/dist/config/index.js.map +1 -1
- package/dist/config/mcp-client-injection.d.ts.map +1 -1
- package/dist/config/mcp-client-injection.js +136 -33
- package/dist/config/mcp-client-injection.js.map +1 -1
- package/dist/config/paths.d.ts +14 -1
- package/dist/config/paths.d.ts.map +1 -1
- package/dist/config/paths.js +20 -1
- package/dist/config/paths.js.map +1 -1
- package/dist/config/profiles.d.ts +3 -10
- package/dist/config/profiles.d.ts.map +1 -1
- package/dist/config/profiles.js +5 -0
- package/dist/config/profiles.js.map +1 -1
- package/dist/config/schema.d.ts +5 -0
- package/dist/config/schema.d.ts.map +1 -1
- package/dist/config/schema.js +5 -0
- package/dist/config/schema.js.map +1 -1
- package/dist/config/secure-config.d.ts +5 -0
- package/dist/config/secure-config.d.ts.map +1 -1
- package/dist/config/secure-config.js +5 -0
- package/dist/config/secure-config.js.map +1 -1
- package/dist/config/setup.d.ts +5 -0
- package/dist/config/setup.d.ts.map +1 -1
- package/dist/config/setup.js +5 -0
- package/dist/config/setup.js.map +1 -1
- package/dist/config/wizard.d.ts +6 -0
- package/dist/config/wizard.d.ts.map +1 -1
- package/dist/config/wizard.js +102 -18
- package/dist/config/wizard.js.map +1 -1
- package/dist/config-cli.d.ts +3 -13
- package/dist/config-cli.d.ts.map +1 -1
- package/dist/config-cli.js +14 -1
- package/dist/config-cli.js.map +1 -1
- package/dist/core/constants.d.ts +33 -6
- package/dist/core/constants.d.ts.map +1 -1
- package/dist/core/constants.js +38 -8
- package/dist/core/constants.js.map +1 -1
- package/dist/core/errors.d.ts +5 -0
- package/dist/core/errors.d.ts.map +1 -1
- package/dist/core/errors.js +5 -0
- package/dist/core/errors.js.map +1 -1
- package/dist/core/guards.d.ts +5 -0
- package/dist/core/guards.d.ts.map +1 -1
- package/dist/core/guards.js +3 -1
- package/dist/core/guards.js.map +1 -1
- package/dist/core/index.d.ts +7 -1
- package/dist/core/index.d.ts.map +1 -1
- package/dist/core/index.js +7 -1
- package/dist/core/index.js.map +1 -1
- package/dist/core/logger.js +1 -1
- package/dist/core/result.d.ts +77 -9
- package/dist/core/result.d.ts.map +1 -1
- package/dist/core/result.js +68 -9
- package/dist/core/result.js.map +1 -1
- package/dist/core/types.d.ts +5 -0
- package/dist/core/types.d.ts.map +1 -1
- package/dist/core/types.js +3 -4
- package/dist/core/types.js.map +1 -1
- package/dist/index.d.ts +5 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +5 -0
- package/dist/index.js.map +1 -1
- package/dist/memory/async-processor.d.ts +107 -0
- package/dist/memory/async-processor.d.ts.map +1 -0
- package/dist/memory/async-processor.js +204 -0
- package/dist/memory/async-processor.js.map +1 -0
- package/dist/memory/auto-record.d.ts +47 -0
- package/dist/memory/auto-record.d.ts.map +1 -0
- package/dist/memory/auto-record.js +133 -0
- package/dist/memory/auto-record.js.map +1 -0
- package/dist/memory/database.d.ts +103 -0
- package/dist/memory/database.d.ts.map +1 -0
- package/dist/memory/database.js +337 -0
- package/dist/memory/database.js.map +1 -0
- package/dist/memory/hermes-bridge.d.ts +70 -0
- package/dist/memory/hermes-bridge.d.ts.map +1 -0
- package/dist/memory/hermes-bridge.js +155 -0
- package/dist/memory/hermes-bridge.js.map +1 -0
- package/dist/memory/index.d.ts +23 -0
- package/dist/memory/index.d.ts.map +1 -0
- package/dist/memory/index.js +22 -0
- package/dist/memory/index.js.map +1 -0
- package/dist/memory/memory-store.d.ts +76 -0
- package/dist/memory/memory-store.d.ts.map +1 -0
- package/dist/memory/memory-store.js +231 -0
- package/dist/memory/memory-store.js.map +1 -0
- package/dist/memory/stream-buffer-store.d.ts +69 -0
- package/dist/memory/stream-buffer-store.d.ts.map +1 -0
- package/dist/memory/stream-buffer-store.js +182 -0
- package/dist/memory/stream-buffer-store.js.map +1 -0
- package/dist/memory/tool-call-store.d.ts +68 -0
- package/dist/memory/tool-call-store.d.ts.map +1 -0
- package/dist/memory/tool-call-store.js +189 -0
- package/dist/memory/tool-call-store.js.map +1 -0
- package/dist/memory/types.d.ts +197 -0
- package/dist/memory/types.d.ts.map +1 -0
- package/dist/memory/types.js +15 -0
- package/dist/memory/types.js.map +1 -0
- package/dist/memory/utils.d.ts +30 -0
- package/dist/memory/utils.d.ts.map +1 -0
- package/dist/memory/utils.js +47 -0
- package/dist/memory/utils.js.map +1 -0
- package/dist/payments/facilitator-rpc-fallback.d.ts.map +1 -1
- package/dist/payments/facilitator-rpc-fallback.js +95 -0
- package/dist/payments/facilitator-rpc-fallback.js.map +1 -1
- package/dist/payments/hosted-tool-eligibility.d.ts +22 -0
- package/dist/payments/hosted-tool-eligibility.d.ts.map +1 -0
- package/dist/payments/hosted-tool-eligibility.js +173 -0
- package/dist/payments/hosted-tool-eligibility.js.map +1 -0
- package/dist/payments/index.d.ts +2 -2
- package/dist/payments/index.d.ts.map +1 -1
- package/dist/payments/index.js +1 -1
- package/dist/payments/index.js.map +1 -1
- package/dist/payments/mcp-session-cache.d.ts +35 -0
- package/dist/payments/mcp-session-cache.d.ts.map +1 -0
- package/dist/payments/mcp-session-cache.js +83 -0
- package/dist/payments/mcp-session-cache.js.map +1 -0
- package/dist/payments/monetization-gate.d.ts +33 -0
- package/dist/payments/monetization-gate.d.ts.map +1 -1
- package/dist/payments/monetization-gate.js +124 -12
- package/dist/payments/monetization-gate.js.map +1 -1
- package/dist/payments/pricing.d.ts +31 -0
- package/dist/payments/pricing.d.ts.map +1 -1
- package/dist/payments/pricing.js +317 -19
- package/dist/payments/pricing.js.map +1 -1
- package/dist/payments/usage-ledger.d.ts +36 -2
- package/dist/payments/usage-ledger.d.ts.map +1 -1
- package/dist/payments/usage-ledger.js +121 -4
- package/dist/payments/usage-ledger.js.map +1 -1
- package/dist/payments/x402-paid-call.d.ts +121 -0
- package/dist/payments/x402-paid-call.d.ts.map +1 -1
- package/dist/payments/x402-paid-call.js +428 -1
- package/dist/payments/x402-paid-call.js.map +1 -1
- package/dist/policy/default-policies.d.ts +18 -2
- package/dist/policy/default-policies.d.ts.map +1 -1
- package/dist/policy/default-policies.js +18 -2
- package/dist/policy/default-policies.js.map +1 -1
- package/dist/policy/index.d.ts +6 -3
- package/dist/policy/index.d.ts.map +1 -1
- package/dist/policy/index.js +6 -3
- package/dist/policy/index.js.map +1 -1
- package/dist/policy/local-policy-engine.d.ts +71 -13
- package/dist/policy/local-policy-engine.d.ts.map +1 -1
- package/dist/policy/local-policy-engine.js +33 -11
- package/dist/policy/local-policy-engine.js.map +1 -1
- package/dist/policy/permission-checks.d.ts +29 -3
- package/dist/policy/permission-checks.d.ts.map +1 -1
- package/dist/policy/permission-checks.js +29 -3
- package/dist/policy/permission-checks.js.map +1 -1
- package/dist/policy/policy-engine.d.ts +22 -2
- package/dist/policy/policy-engine.d.ts.map +1 -1
- package/dist/policy/policy-engine.js +22 -2
- package/dist/policy/policy-engine.js.map +1 -1
- package/dist/policy/policy-types.d.ts +55 -5
- package/dist/policy/policy-types.d.ts.map +1 -1
- package/dist/policy/policy-types.js +8 -1
- package/dist/policy/policy-types.js.map +1 -1
- package/dist/policy/risk-level.d.ts +32 -3
- package/dist/policy/risk-level.d.ts.map +1 -1
- package/dist/policy/risk-level.js +32 -3
- package/dist/policy/risk-level.js.map +1 -1
- package/dist/policy/spending-limits.d.ts +29 -3
- package/dist/policy/spending-limits.d.ts.map +1 -1
- package/dist/policy/spending-limits.js +29 -3
- package/dist/policy/spending-limits.js.map +1 -1
- package/dist/premium/activation-manager.d.ts +43 -0
- package/dist/premium/activation-manager.d.ts.map +1 -0
- package/dist/premium/activation-manager.js +131 -0
- package/dist/premium/activation-manager.js.map +1 -0
- package/dist/premium/builtin-plugins.d.ts +165 -0
- package/dist/premium/builtin-plugins.d.ts.map +1 -0
- package/dist/premium/builtin-plugins.js +422 -0
- package/dist/premium/builtin-plugins.js.map +1 -0
- package/dist/premium/event-store.d.ts +61 -0
- package/dist/premium/event-store.d.ts.map +1 -0
- package/dist/premium/event-store.js +130 -0
- package/dist/premium/event-store.js.map +1 -0
- package/dist/premium/index.d.ts +54 -0
- package/dist/premium/index.d.ts.map +1 -0
- package/dist/premium/index.js +54 -0
- package/dist/premium/index.js.map +1 -0
- package/dist/premium/manifest-builder.d.ts +65 -0
- package/dist/premium/manifest-builder.d.ts.map +1 -0
- package/dist/premium/manifest-builder.js +182 -0
- package/dist/premium/manifest-builder.js.map +1 -0
- package/dist/premium/meme-radar-capabilities.d.ts +38 -0
- package/dist/premium/meme-radar-capabilities.d.ts.map +1 -0
- package/dist/premium/meme-radar-capabilities.js +306 -0
- package/dist/premium/meme-radar-capabilities.js.map +1 -0
- package/dist/premium/metrics.d.ts +27 -0
- package/dist/premium/metrics.d.ts.map +1 -0
- package/dist/premium/metrics.js +65 -0
- package/dist/premium/metrics.js.map +1 -0
- package/dist/premium/plugin-validator.d.ts +39 -0
- package/dist/premium/plugin-validator.d.ts.map +1 -0
- package/dist/premium/plugin-validator.js +325 -0
- package/dist/premium/plugin-validator.js.map +1 -0
- package/dist/premium/private-manifest-loader.d.ts +111 -0
- package/dist/premium/private-manifest-loader.d.ts.map +1 -0
- package/dist/premium/private-manifest-loader.js +285 -0
- package/dist/premium/private-manifest-loader.js.map +1 -0
- package/dist/premium/provider-bridge.d.ts +133 -0
- package/dist/premium/provider-bridge.d.ts.map +1 -0
- package/dist/premium/provider-bridge.js +349 -0
- package/dist/premium/provider-bridge.js.map +1 -0
- package/dist/premium/session-manager.d.ts +125 -0
- package/dist/premium/session-manager.d.ts.map +1 -0
- package/dist/premium/session-manager.js +337 -0
- package/dist/premium/session-manager.js.map +1 -0
- package/dist/premium/stream-broker.d.ts +98 -0
- package/dist/premium/stream-broker.d.ts.map +1 -0
- package/dist/premium/stream-broker.js +199 -0
- package/dist/premium/stream-broker.js.map +1 -0
- package/dist/premium/tech-fundamentals-capabilities.d.ts +37 -0
- package/dist/premium/tech-fundamentals-capabilities.d.ts.map +1 -0
- package/dist/premium/tech-fundamentals-capabilities.js +283 -0
- package/dist/premium/tech-fundamentals-capabilities.js.map +1 -0
- package/dist/premium/trading-capabilities.d.ts +36 -0
- package/dist/premium/trading-capabilities.d.ts.map +1 -0
- package/dist/premium/trading-capabilities.js +205 -0
- package/dist/premium/trading-capabilities.js.map +1 -0
- package/dist/premium/types.d.ts +518 -0
- package/dist/premium/types.d.ts.map +1 -0
- package/dist/premium/types.js +23 -0
- package/dist/premium/types.js.map +1 -0
- package/dist/premium/webhook-engine.d.ts +138 -0
- package/dist/premium/webhook-engine.d.ts.map +1 -0
- package/dist/premium/webhook-engine.js +516 -0
- package/dist/premium/webhook-engine.js.map +1 -0
- package/dist/prompts/context/sap-agent-context.prompt.d.ts +5 -0
- package/dist/prompts/context/sap-agent-context.prompt.d.ts.map +1 -1
- package/dist/prompts/context/sap-agent-context.prompt.js +20 -16
- package/dist/prompts/context/sap-agent-context.prompt.js.map +1 -1
- package/dist/prompts/context/sap-agent-intent-router.prompt.d.ts +14 -0
- package/dist/prompts/context/sap-agent-intent-router.prompt.d.ts.map +1 -0
- package/dist/prompts/context/sap-agent-intent-router.prompt.js +155 -0
- package/dist/prompts/context/sap-agent-intent-router.prompt.js.map +1 -0
- package/dist/prompts/context/sap-agent-start.prompt.js +7 -0
- package/dist/prompts/context/sap-agent-start.prompt.js.map +1 -1
- package/dist/prompts/developer/debug-sap-error.prompt.d.ts +5 -0
- package/dist/prompts/developer/debug-sap-error.prompt.d.ts.map +1 -1
- package/dist/prompts/developer/debug-sap-error.prompt.js +3 -4
- package/dist/prompts/developer/debug-sap-error.prompt.js.map +1 -1
- package/dist/prompts/developer/generate-sap-integration.prompt.d.ts +5 -0
- package/dist/prompts/developer/generate-sap-integration.prompt.d.ts.map +1 -1
- package/dist/prompts/developer/generate-sap-integration.prompt.js +3 -4
- package/dist/prompts/developer/generate-sap-integration.prompt.js.map +1 -1
- package/dist/prompts/developer/index.d.ts +4 -1
- package/dist/prompts/developer/index.d.ts.map +1 -1
- package/dist/prompts/developer/index.js +4 -1
- package/dist/prompts/developer/index.js.map +1 -1
- package/dist/prompts/execution-proof/explain-proof-of-execution.prompt.d.ts +5 -0
- package/dist/prompts/execution-proof/explain-proof-of-execution.prompt.d.ts.map +1 -1
- package/dist/prompts/execution-proof/explain-proof-of-execution.prompt.js +3 -4
- package/dist/prompts/execution-proof/explain-proof-of-execution.prompt.js.map +1 -1
- package/dist/prompts/execution-proof/index.d.ts +4 -1
- package/dist/prompts/execution-proof/index.d.ts.map +1 -1
- package/dist/prompts/execution-proof/index.js +4 -1
- package/dist/prompts/execution-proof/index.js.map +1 -1
- package/dist/prompts/execution-proof/verify-execution-proof.prompt.d.ts +5 -0
- package/dist/prompts/execution-proof/verify-execution-proof.prompt.d.ts.map +1 -1
- package/dist/prompts/execution-proof/verify-execution-proof.prompt.js +3 -4
- package/dist/prompts/execution-proof/verify-execution-proof.prompt.js.map +1 -1
- package/dist/prompts/index.d.ts +4 -1
- package/dist/prompts/index.d.ts.map +1 -1
- package/dist/prompts/index.js +4 -1
- package/dist/prompts/index.js.map +1 -1
- package/dist/prompts/payments/create-paid-api.prompt.d.ts +5 -0
- package/dist/prompts/payments/create-paid-api.prompt.d.ts.map +1 -1
- package/dist/prompts/payments/create-paid-api.prompt.js +3 -4
- package/dist/prompts/payments/create-paid-api.prompt.js.map +1 -1
- package/dist/prompts/payments/explain-x402-settlement.prompt.d.ts +5 -0
- package/dist/prompts/payments/explain-x402-settlement.prompt.d.ts.map +1 -1
- package/dist/prompts/payments/explain-x402-settlement.prompt.js +4 -5
- package/dist/prompts/payments/explain-x402-settlement.prompt.js.map +1 -1
- package/dist/prompts/payments/index.d.ts +4 -1
- package/dist/prompts/payments/index.d.ts.map +1 -1
- package/dist/prompts/payments/index.js +4 -1
- package/dist/prompts/payments/index.js.map +1 -1
- package/dist/prompts/register-prompts.d.ts +18 -2
- package/dist/prompts/register-prompts.d.ts.map +1 -1
- package/dist/prompts/register-prompts.js +21 -3
- package/dist/prompts/register-prompts.js.map +1 -1
- package/dist/prompts/registry/analyze-sap-agent.prompt.d.ts +5 -0
- package/dist/prompts/registry/analyze-sap-agent.prompt.d.ts.map +1 -1
- package/dist/prompts/registry/analyze-sap-agent.prompt.js +3 -4
- package/dist/prompts/registry/analyze-sap-agent.prompt.js.map +1 -1
- package/dist/prompts/registry/index.d.ts +4 -1
- package/dist/prompts/registry/index.d.ts.map +1 -1
- package/dist/prompts/registry/index.js +4 -1
- package/dist/prompts/registry/index.js.map +1 -1
- package/dist/prompts/registry/register-sap-agent.prompt.d.ts +5 -0
- package/dist/prompts/registry/register-sap-agent.prompt.d.ts.map +1 -1
- package/dist/prompts/registry/register-sap-agent.prompt.js +22 -23
- package/dist/prompts/registry/register-sap-agent.prompt.js.map +1 -1
- package/dist/remote/premium-memory.d.ts +90 -0
- package/dist/remote/premium-memory.d.ts.map +1 -0
- package/dist/remote/premium-memory.js +161 -0
- package/dist/remote/premium-memory.js.map +1 -0
- package/dist/remote/premium-routes.d.ts +99 -0
- package/dist/remote/premium-routes.d.ts.map +1 -0
- package/dist/remote/premium-routes.js +347 -0
- package/dist/remote/premium-routes.js.map +1 -0
- package/dist/remote/public-home/sections.d.ts.map +1 -1
- package/dist/remote/public-home/sections.js +23 -4
- package/dist/remote/public-home/sections.js.map +1 -1
- package/dist/remote/public-home/types.d.ts +9 -0
- package/dist/remote/public-home/types.d.ts.map +1 -1
- package/dist/remote/server.d.ts +20 -0
- package/dist/remote/server.d.ts.map +1 -1
- package/dist/remote/server.js +369 -8
- package/dist/remote/server.js.map +1 -1
- package/dist/remote/tx-relay.d.ts +42 -0
- package/dist/remote/tx-relay.d.ts.map +1 -0
- package/dist/remote/tx-relay.js +118 -0
- package/dist/remote/tx-relay.js.map +1 -0
- package/dist/resources/current/sap-current-config.resource.d.ts +5 -0
- package/dist/resources/current/sap-current-config.resource.d.ts.map +1 -1
- package/dist/resources/current/sap-current-config.resource.js +2 -5
- package/dist/resources/current/sap-current-config.resource.js.map +1 -1
- package/dist/resources/execution-proof/index.d.ts +5 -0
- package/dist/resources/execution-proof/index.d.ts.map +1 -1
- package/dist/resources/execution-proof/index.js +5 -0
- package/dist/resources/execution-proof/index.js.map +1 -1
- package/dist/resources/execution-proof/sap-execution-record.resource.d.ts +5 -0
- package/dist/resources/execution-proof/sap-execution-record.resource.d.ts.map +1 -1
- package/dist/resources/execution-proof/sap-execution-record.resource.js +3 -4
- package/dist/resources/execution-proof/sap-execution-record.resource.js.map +1 -1
- package/dist/resources/index.d.ts +5 -0
- package/dist/resources/index.d.ts.map +1 -1
- package/dist/resources/index.js +5 -0
- package/dist/resources/index.js.map +1 -1
- package/dist/resources/memory/index.d.ts +5 -0
- package/dist/resources/memory/index.d.ts.map +1 -1
- package/dist/resources/memory/index.js +5 -0
- package/dist/resources/memory/index.js.map +1 -1
- package/dist/resources/memory/sap-memory.resource.d.ts +5 -0
- package/dist/resources/memory/sap-memory.resource.d.ts.map +1 -1
- package/dist/resources/memory/sap-memory.resource.js +3 -4
- package/dist/resources/memory/sap-memory.resource.js.map +1 -1
- package/dist/resources/profile/sap-active-profile.resource.d.ts +5 -0
- package/dist/resources/profile/sap-active-profile.resource.d.ts.map +1 -1
- package/dist/resources/profile/sap-active-profile.resource.js +2 -5
- package/dist/resources/profile/sap-active-profile.resource.js.map +1 -1
- package/dist/resources/register-resources.d.ts +5 -0
- package/dist/resources/register-resources.d.ts.map +1 -1
- package/dist/resources/register-resources.js +3 -1
- package/dist/resources/register-resources.js.map +1 -1
- package/dist/resources/registry/index.d.ts +5 -0
- package/dist/resources/registry/index.d.ts.map +1 -1
- package/dist/resources/registry/index.js +5 -0
- package/dist/resources/registry/index.js.map +1 -1
- package/dist/resources/registry/sap-agent.resource.d.ts +5 -0
- package/dist/resources/registry/sap-agent.resource.d.ts.map +1 -1
- package/dist/resources/registry/sap-agent.resource.js +3 -4
- package/dist/resources/registry/sap-agent.resource.js.map +1 -1
- package/dist/resources/registry/sap-global-registry.resource.d.ts +18 -4
- package/dist/resources/registry/sap-global-registry.resource.d.ts.map +1 -1
- package/dist/resources/registry/sap-global-registry.resource.js +18 -4
- package/dist/resources/registry/sap-global-registry.resource.js.map +1 -1
- package/dist/resources/reputation/index.d.ts +4 -1
- package/dist/resources/reputation/index.d.ts.map +1 -1
- package/dist/resources/reputation/index.js +4 -1
- package/dist/resources/reputation/index.js.map +1 -1
- package/dist/resources/reputation/sap-reputation.resource.d.ts +18 -4
- package/dist/resources/reputation/sap-reputation.resource.d.ts.map +1 -1
- package/dist/resources/reputation/sap-reputation.resource.js +18 -4
- package/dist/resources/reputation/sap-reputation.resource.js.map +1 -1
- package/dist/resources/tool-schema/index.d.ts +4 -1
- package/dist/resources/tool-schema/index.d.ts.map +1 -1
- package/dist/resources/tool-schema/index.js +4 -1
- package/dist/resources/tool-schema/index.js.map +1 -1
- package/dist/resources/tool-schema/sap-tool-schema.resource.d.ts +18 -4
- package/dist/resources/tool-schema/sap-tool-schema.resource.d.ts.map +1 -1
- package/dist/resources/tool-schema/sap-tool-schema.resource.js +18 -4
- package/dist/resources/tool-schema/sap-tool-schema.resource.js.map +1 -1
- package/dist/sap/index.d.ts +7 -1
- package/dist/sap/index.d.ts.map +1 -1
- package/dist/sap/index.js +7 -1
- package/dist/sap/index.js.map +1 -1
- package/dist/sap/sap-client-manager.d.ts +80 -13
- package/dist/sap/sap-client-manager.d.ts.map +1 -1
- package/dist/sap/sap-client-manager.js +80 -13
- package/dist/sap/sap-client-manager.js.map +1 -1
- package/dist/sap/sap-errors.d.ts +22 -3
- package/dist/sap/sap-errors.d.ts.map +1 -1
- package/dist/sap/sap-errors.js +22 -3
- package/dist/sap/sap-errors.js.map +1 -1
- package/dist/sap/sap-types.d.ts +75 -6
- package/dist/sap/sap-types.d.ts.map +1 -1
- package/dist/sap/sap-types.js +11 -1
- package/dist/sap/sap-types.js.map +1 -1
- package/dist/schemas/common.schema.d.ts +45 -8
- package/dist/schemas/common.schema.d.ts.map +1 -1
- package/dist/schemas/common.schema.js +45 -8
- package/dist/schemas/common.schema.js.map +1 -1
- package/dist/schemas/developer.schema.d.ts +22 -3
- package/dist/schemas/developer.schema.d.ts.map +1 -1
- package/dist/schemas/developer.schema.js +22 -3
- package/dist/schemas/developer.schema.js.map +1 -1
- package/dist/schemas/execution-proof.schema.d.ts +29 -4
- package/dist/schemas/execution-proof.schema.d.ts.map +1 -1
- package/dist/schemas/execution-proof.schema.js +29 -4
- package/dist/schemas/execution-proof.schema.js.map +1 -1
- package/dist/schemas/identity.schema.d.ts +23 -3
- package/dist/schemas/identity.schema.d.ts.map +1 -1
- package/dist/schemas/identity.schema.js +23 -3
- package/dist/schemas/identity.schema.js.map +1 -1
- package/dist/schemas/index.d.ts +11 -1
- package/dist/schemas/index.d.ts.map +1 -1
- package/dist/schemas/index.js +11 -1
- package/dist/schemas/index.js.map +1 -1
- package/dist/schemas/memory.schema.d.ts +23 -3
- package/dist/schemas/memory.schema.d.ts.map +1 -1
- package/dist/schemas/memory.schema.js +23 -3
- package/dist/schemas/memory.schema.js.map +1 -1
- package/dist/schemas/payments.schema.d.ts +24 -3
- package/dist/schemas/payments.schema.d.ts.map +1 -1
- package/dist/schemas/payments.schema.js +24 -3
- package/dist/schemas/payments.schema.js.map +1 -1
- package/dist/schemas/registry.schema.d.ts +38 -6
- package/dist/schemas/registry.schema.d.ts.map +1 -1
- package/dist/schemas/registry.schema.js +36 -4
- package/dist/schemas/registry.schema.js.map +1 -1
- package/dist/schemas/reputation.schema.d.ts +22 -3
- package/dist/schemas/reputation.schema.d.ts.map +1 -1
- package/dist/schemas/reputation.schema.js +22 -3
- package/dist/schemas/reputation.schema.js.map +1 -1
- package/dist/schemas/settlement.schema.d.ts +31 -4
- package/dist/schemas/settlement.schema.d.ts.map +1 -1
- package/dist/schemas/settlement.schema.js +31 -4
- package/dist/schemas/settlement.schema.js.map +1 -1
- package/dist/schemas/tool-schema.schema.d.ts +29 -3
- package/dist/schemas/tool-schema.schema.d.ts.map +1 -1
- package/dist/schemas/tool-schema.schema.js +29 -3
- package/dist/schemas/tool-schema.schema.js.map +1 -1
- package/dist/schemas/transaction.schema.d.ts +23 -3
- package/dist/schemas/transaction.schema.d.ts.map +1 -1
- package/dist/schemas/transaction.schema.js +23 -3
- package/dist/schemas/transaction.schema.js.map +1 -1
- package/dist/security/approval-required.d.ts +19 -2
- package/dist/security/approval-required.d.ts.map +1 -1
- package/dist/security/approval-required.js +19 -2
- package/dist/security/approval-required.js.map +1 -1
- package/dist/security/index.d.ts +7 -1
- package/dist/security/index.d.ts.map +1 -1
- package/dist/security/index.js +7 -1
- package/dist/security/index.js.map +1 -1
- package/dist/security/private-key-guard.d.ts +18 -2
- package/dist/security/private-key-guard.d.ts.map +1 -1
- package/dist/security/private-key-guard.js +19 -2
- package/dist/security/private-key-guard.js.map +1 -1
- package/dist/security/prompt-injection-notes.d.ts +10 -1
- package/dist/security/prompt-injection-notes.d.ts.map +1 -1
- package/dist/security/prompt-injection-notes.js +10 -1
- package/dist/security/prompt-injection-notes.js.map +1 -1
- package/dist/security/tool-permissions.d.ts.map +1 -1
- package/dist/security/tool-permissions.js +12 -0
- package/dist/security/tool-permissions.js.map +1 -1
- package/dist/security/unsafe-action-guard.d.ts +36 -10
- package/dist/security/unsafe-action-guard.d.ts.map +1 -1
- package/dist/security/unsafe-action-guard.js +67 -15
- package/dist/security/unsafe-action-guard.js.map +1 -1
- package/dist/server/create-server.d.ts +18 -3
- package/dist/server/create-server.d.ts.map +1 -1
- package/dist/server/create-server.js +18 -3
- package/dist/server/create-server.js.map +1 -1
- package/dist/server/index.d.ts +6 -1
- package/dist/server/index.d.ts.map +1 -1
- package/dist/server/index.js +6 -1
- package/dist/server/index.js.map +1 -1
- package/dist/server/register-capabilities.d.ts +17 -2
- package/dist/server/register-capabilities.d.ts.map +1 -1
- package/dist/server/register-capabilities.js +17 -2
- package/dist/server/register-capabilities.js.map +1 -1
- package/dist/server/server-metadata.d.ts +35 -1
- package/dist/server/server-metadata.d.ts.map +1 -1
- package/dist/server/server-metadata.js +36 -2
- package/dist/server/server-metadata.js.map +1 -1
- package/dist/session/agent-session.d.ts +35 -4
- package/dist/session/agent-session.d.ts.map +1 -1
- package/dist/session/agent-session.js +35 -4
- package/dist/session/agent-session.js.map +1 -1
- package/dist/session/delegated-session.d.ts +31 -3
- package/dist/session/delegated-session.d.ts.map +1 -1
- package/dist/session/delegated-session.js +31 -3
- package/dist/session/delegated-session.js.map +1 -1
- package/dist/session/index.d.ts +7 -1
- package/dist/session/index.d.ts.map +1 -1
- package/dist/session/index.js +7 -1
- package/dist/session/index.js.map +1 -1
- package/dist/session/redis-session-store.d.ts +94 -21
- package/dist/session/redis-session-store.d.ts.map +1 -1
- package/dist/session/redis-session-store.js +87 -20
- package/dist/session/redis-session-store.js.map +1 -1
- package/dist/session/session-limits.d.ts +34 -4
- package/dist/session/session-limits.d.ts.map +1 -1
- package/dist/session/session-limits.js +34 -4
- package/dist/session/session-limits.js.map +1 -1
- package/dist/session/session-permissions.d.ts +57 -7
- package/dist/session/session-permissions.d.ts.map +1 -1
- package/dist/session/session-permissions.js +57 -7
- package/dist/session/session-permissions.js.map +1 -1
- package/dist/session/session-store.d.ts +9 -1
- package/dist/session/session-store.d.ts.map +1 -1
- package/dist/session/session-store.js +18 -3
- package/dist/session/session-store.js.map +1 -1
- package/dist/session/session-types.d.ts +33 -4
- package/dist/session/session-types.d.ts.map +1 -1
- package/dist/session/session-types.js +9 -1
- package/dist/session/session-types.js.map +1 -1
- package/dist/signer/index.d.ts +7 -1
- package/dist/signer/index.d.ts.map +1 -1
- package/dist/signer/index.js +7 -1
- package/dist/signer/index.js.map +1 -1
- package/dist/signer/load-keypair.d.ts +25 -4
- package/dist/signer/load-keypair.d.ts.map +1 -1
- package/dist/signer/load-keypair.js +25 -4
- package/dist/signer/load-keypair.js.map +1 -1
- package/dist/signer/local-keypair-signer.d.ts +19 -3
- package/dist/signer/local-keypair-signer.d.ts.map +1 -1
- package/dist/signer/local-keypair-signer.js +24 -4
- package/dist/signer/local-keypair-signer.js.map +1 -1
- package/dist/signer/signer-resolver.d.ts +19 -2
- package/dist/signer/signer-resolver.d.ts.map +1 -1
- package/dist/signer/signer-resolver.js +26 -3
- package/dist/signer/signer-resolver.js.map +1 -1
- package/dist/signer/signer-types.d.ts +47 -5
- package/dist/signer/signer-types.d.ts.map +1 -1
- package/dist/signer/signer-types.js +13 -1
- package/dist/signer/signer-types.js.map +1 -1
- package/dist/strategies/strategy-store.d.ts +82 -0
- package/dist/strategies/strategy-store.d.ts.map +1 -0
- package/dist/strategies/strategy-store.js +165 -0
- package/dist/strategies/strategy-store.js.map +1 -0
- package/dist/tools/agent-start-tool.d.ts.map +1 -1
- package/dist/tools/agent-start-tool.js +481 -5
- package/dist/tools/agent-start-tool.js.map +1 -1
- package/dist/tools/client-sdk-tools.d.ts.map +1 -1
- package/dist/tools/client-sdk-tools.js +32 -7
- package/dist/tools/client-sdk-tools.js.map +1 -1
- package/dist/tools/estimate-tool-cost.d.ts +13 -0
- package/dist/tools/estimate-tool-cost.d.ts.map +1 -0
- package/dist/tools/estimate-tool-cost.js +139 -0
- package/dist/tools/estimate-tool-cost.js.map +1 -0
- package/dist/tools/index.d.ts +8 -0
- package/dist/tools/index.d.ts.map +1 -1
- package/dist/tools/index.js +11 -0
- package/dist/tools/index.js.map +1 -1
- package/dist/tools/magicblock-tools.d.ts +31 -6
- package/dist/tools/magicblock-tools.d.ts.map +1 -1
- package/dist/tools/magicblock-tools.js +178 -53
- package/dist/tools/magicblock-tools.js.map +1 -1
- package/dist/tools/memory-tools.d.ts +26 -0
- package/dist/tools/memory-tools.d.ts.map +1 -0
- package/dist/tools/memory-tools.js +533 -0
- package/dist/tools/memory-tools.js.map +1 -0
- package/dist/tools/perp-tools.d.ts +39 -0
- package/dist/tools/perp-tools.d.ts.map +1 -0
- package/dist/tools/perp-tools.js +1110 -0
- package/dist/tools/perp-tools.js.map +1 -0
- package/dist/tools/premium-tools.d.ts +8 -0
- package/dist/tools/premium-tools.d.ts.map +1 -0
- package/dist/tools/premium-tools.js +1102 -0
- package/dist/tools/premium-tools.js.map +1 -0
- package/dist/tools/profile-tools.d.ts.map +1 -1
- package/dist/tools/profile-tools.js +18 -1
- package/dist/tools/profile-tools.js.map +1 -1
- package/dist/tools/quick-context-tool.d.ts +16 -0
- package/dist/tools/quick-context-tool.d.ts.map +1 -0
- package/dist/tools/quick-context-tool.js +304 -0
- package/dist/tools/quick-context-tool.js.map +1 -0
- package/dist/tools/register-tools.d.ts.map +1 -1
- package/dist/tools/register-tools.js +17 -0
- package/dist/tools/register-tools.js.map +1 -1
- package/dist/tools/sap-sdk-tools.d.ts +419 -0
- package/dist/tools/sap-sdk-tools.d.ts.map +1 -1
- package/dist/tools/sap-sdk-tools.js +1547 -126
- package/dist/tools/sap-sdk-tools.js.map +1 -1
- package/dist/tools/sap-sns-tools.d.ts +2 -2
- package/dist/tools/sap-sns-tools.d.ts.map +1 -1
- package/dist/tools/sap-sns-tools.js +12 -8
- package/dist/tools/sap-sns-tools.js.map +1 -1
- package/dist/tools/skills-tools.d.ts +16 -0
- package/dist/tools/skills-tools.d.ts.map +1 -1
- package/dist/tools/skills-tools.js +282 -5
- package/dist/tools/skills-tools.js.map +1 -1
- package/dist/tools/tool-aliases.d.ts.map +1 -1
- package/dist/tools/tool-aliases.js +7 -0
- package/dist/tools/tool-aliases.js.map +1 -1
- package/dist/tools/transaction-tools.d.ts +135 -0
- package/dist/tools/transaction-tools.d.ts.map +1 -1
- package/dist/tools/transaction-tools.js +515 -16
- package/dist/tools/transaction-tools.js.map +1 -1
- package/dist/tools/x402-paid-call-tool.d.ts.map +1 -1
- package/dist/tools/x402-paid-call-tool.js +756 -23
- package/dist/tools/x402-paid-call-tool.js.map +1 -1
- package/dist/transports/index.d.ts +6 -1
- package/dist/transports/index.d.ts.map +1 -1
- package/dist/transports/index.js +6 -1
- package/dist/transports/index.js.map +1 -1
- package/dist/transports/stdio.d.ts +17 -5
- package/dist/transports/stdio.d.ts.map +1 -1
- package/dist/transports/stdio.js +17 -5
- package/dist/transports/stdio.js.map +1 -1
- package/dist/tui/wizard-save.d.ts +88 -8
- package/dist/tui/wizard-save.d.ts.map +1 -1
- package/dist/tui/wizard-save.js +77 -8
- package/dist/tui/wizard-save.js.map +1 -1
- package/dist/wizard-core/desktop-flow.d.ts.map +1 -1
- package/dist/wizard-core/desktop-flow.js +4 -2
- package/dist/wizard-core/desktop-flow.js.map +1 -1
- package/docs/03_CONFIGURATION_AND_WIZARD.md +5 -3
- package/docs/06_PAYMENTS_X402_AND_PAYSH.md +82 -4
- package/docs/07_ENDPOINTS_AND_CLIENTS.md +7 -3
- package/docs/09_TOOLS_SKILLS_AND_AGENT_GUIDE.md +21 -3
- package/docs/14_DESKTOP_WIZARD_RELEASE.md +8 -6
- package/docs/16_SAP_AGENT_IDENTITY_PIPELINE.md +304 -0
- package/docs/18_PREMIUM_PLUGIN_RUNTIME.md +108 -0
- package/docs/BRANCH_AND_CI.md +67 -0
- package/docs/README.md +19 -2
- package/docs/magicblock-tools.md +70 -29
- package/package.json +10 -6
- package/server.json +3 -3
- package/skills/README.md +12 -2
- package/skills/sap-agent-registry/SKILL.md +99 -4
- package/skills/sap-defi/SKILL.md +8 -4
- package/skills/sap-discovery-indexing/SKILL.md +26 -4
- package/skills/sap-escrow-settlement/SKILL.md +22 -4
- package/skills/sap-mcp/SKILL.md +140 -22
- package/skills/sap-mcp/TOOL_REFERENCE.md +47 -7
- package/skills/sap-nft-metaplex/SKILL.md +22 -0
- package/skills/sap-operations/SKILL.md +32 -3
- package/skills/sap-payments-x402/SKILL.md +85 -8
- package/skills/sap-sns/SKILL.md +32 -10
- package/smithery.config.schema.json +7 -0
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
# SAP MCP Premium Plugin Runtime
|
|
2
|
+
|
|
3
|
+
SAP MCP includes a typed premium plugin contract for paid streams, webhooks, and enterprise capabilities. The goal is to let agents discover paid real-time capabilities, validate schemas before spending, and bind future x402/pay.sh receipts to a clear session id without exposing private provider code or user key material.
|
|
4
|
+
|
|
5
|
+
This layer is deliberately strict:
|
|
6
|
+
|
|
7
|
+
- no fake stream data
|
|
8
|
+
- no implicit provider claims
|
|
9
|
+
- no execution of plugin code from user input
|
|
10
|
+
- no keypair bytes or provider secrets in public metadata
|
|
11
|
+
- no x402 charge for invalid catalog/session planning requests
|
|
12
|
+
|
|
13
|
+
## What Ships In The Open Server
|
|
14
|
+
|
|
15
|
+
The public MCP server exposes free discovery and planning tools:
|
|
16
|
+
|
|
17
|
+
| Tool | Purpose |
|
|
18
|
+
| --- | --- |
|
|
19
|
+
| `sap_premium_plugin_catalog` | Lists premium plugin manifests, schemas, pricing contracts, provider readiness, and private plugin loader guidance. |
|
|
20
|
+
| `sap_stream_catalog` | Lists stream capability contracts such as quote deltas, price ticks, registry events, and x402 ledger events. |
|
|
21
|
+
| `sap_webhook_catalog` | Lists webhook delivery contracts and signed callback event types. |
|
|
22
|
+
| `sap_premium_validate_plugin_manifest` | Validates a manifest before publication or enterprise loading. |
|
|
23
|
+
| `sap_premium_plugin_template` | Builds a strict data-only manifest template for custom stream, webhook, or premium tool contracts. |
|
|
24
|
+
| `sap_premium_session_start` | Creates an unpaid, bounded session plan for a premium capability. |
|
|
25
|
+
| `sap_premium_session_status` | Reads in-memory premium session planning status. |
|
|
26
|
+
|
|
27
|
+
Planning is free because it prevents wasted x402 attempts. Live premium delivery should be charged by the delivery rail once the provider is configured and the session is activation-ready.
|
|
28
|
+
|
|
29
|
+
## Public HTTP Discovery
|
|
30
|
+
|
|
31
|
+
The hosted server also exposes the same premium contracts as public, machine-readable JSON:
|
|
32
|
+
|
|
33
|
+
| Endpoint | Purpose |
|
|
34
|
+
| --- | --- |
|
|
35
|
+
| `/premium/catalog.json` | Full premium plugin catalog with provider readiness, pricing contracts, stream/webhook/tool capability ids, and private loader guidance. |
|
|
36
|
+
| `/premium/streams.json` | Stream-only discovery for price ticks, quote deltas, registry events, and x402 ledger streams. |
|
|
37
|
+
| `/premium/webhooks.json` | Webhook-only discovery for signed callback subscriptions and event delivery contracts. |
|
|
38
|
+
|
|
39
|
+
These endpoints are discovery-only. They do not activate paid streams, execute private plugins, expose provider secrets, or return live provider data while readiness is false.
|
|
40
|
+
|
|
41
|
+
## Provider Readiness
|
|
42
|
+
|
|
43
|
+
Capabilities that depend on external streaming or webhook infrastructure include explicit provider env vars. If a required env var is missing, the capability returns:
|
|
44
|
+
|
|
45
|
+
```txt
|
|
46
|
+
status: requires-provider
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
Agents must not attempt paid activation when provider readiness is false. They should tell the user that the capability is contract-ready but not live on this deployment.
|
|
50
|
+
|
|
51
|
+
## Built-In Premium Contracts
|
|
52
|
+
|
|
53
|
+
The open catalog currently defines contract-level manifests for:
|
|
54
|
+
|
|
55
|
+
| Plugin | Capability Examples |
|
|
56
|
+
| --- | --- |
|
|
57
|
+
| `sap-premium-market-data` | Jupiter quote deltas, Pyth price ticks, price threshold webhooks. |
|
|
58
|
+
| `sap-premium-trading-streams` | Cross-DEX arbitrage scanning, volatility breakout detection, MEV-protected route optimization. |
|
|
59
|
+
| `sap-premium-meme-radar` | New listing alerts, social sentiment, rugpull risk, DEX volume anomalies. |
|
|
60
|
+
| `sap-premium-tech-fundamentals` | GitHub activity spikes, TVL changes, tokenomics analysis. |
|
|
61
|
+
|
|
62
|
+
These are not mock feeds. They are typed contracts that become live only when the corresponding provider env is configured.
|
|
63
|
+
|
|
64
|
+
## Private Enterprise Plugins
|
|
65
|
+
|
|
66
|
+
Enterprise/private plugin code should live outside the public repository. The public server exposes the contract and validation path only.
|
|
67
|
+
|
|
68
|
+
Supported loader env contract:
|
|
69
|
+
|
|
70
|
+
```txt
|
|
71
|
+
SAP_MCP_ENABLE_PREMIUM_PLUGINS=true
|
|
72
|
+
SAP_MCP_PLUGIN_DIR=/secure/path/to/private/plugins
|
|
73
|
+
SAP_MCP_PREMIUM_EXPOSE_PRIVATE_DISCOVERY=false
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
Private plugins must provide manifests that pass:
|
|
77
|
+
|
|
78
|
+
```txt
|
|
79
|
+
sap_premium_validate_plugin_manifest
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
The runtime loads private manifests as data only from the configured directory.
|
|
83
|
+
It does not execute plugin code supplied through MCP tool input. Private and
|
|
84
|
+
enterprise manifests are not exposed in public catalog responses unless
|
|
85
|
+
`SAP_MCP_PREMIUM_EXPOSE_PRIVATE_DISCOVERY=true` is set deliberately, which
|
|
86
|
+
should be reserved for authenticated or explicitly shared deployments.
|
|
87
|
+
|
|
88
|
+
Use `sap_premium_plugin_template` to generate a starter manifest, then store the
|
|
89
|
+
reviewed JSON in the private plugin subrepo under `manifests/`. Plugging and
|
|
90
|
+
unplugging a private capability is a file/deploy operation: add or remove the
|
|
91
|
+
manifest, validate it, and restart the hosted server with the intended env.
|
|
92
|
+
|
|
93
|
+
## Agent Flow
|
|
94
|
+
|
|
95
|
+
Recommended agent behavior:
|
|
96
|
+
|
|
97
|
+
1. Call `sap_premium_plugin_catalog` with `includeSchemas:true`.
|
|
98
|
+
2. Use `sap_stream_catalog` or `sap_webhook_catalog` to pick an exact capability id.
|
|
99
|
+
3. Check `providerStatus` and the capability-level `providerReady` boolean.
|
|
100
|
+
4. Call `sap_premium_session_start` to get a bounded session plan and estimated price.
|
|
101
|
+
5. Activate only through the future paid delivery rail when provider readiness is true.
|
|
102
|
+
6. Bind x402/pay.sh receipt, session id, plugin id, capability id, and event ids in the audit output.
|
|
103
|
+
|
|
104
|
+
If the provider is not ready, stop cleanly and do not request payment.
|
|
105
|
+
|
|
106
|
+
## Why This Matters
|
|
107
|
+
|
|
108
|
+
Agent commerce needs more than one-shot tools. Trading agents, research agents, protocol monitors, and marketplace agents need fast event access with clear payment boundaries. SAP MCP premium plugins create the contract layer for that: typed schemas, bounded sessions, x402/pay.sh pricing, signed delivery, and enterprise provider isolation.
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
# Branch & CI/CD Strategy
|
|
2
|
+
|
|
3
|
+
## Branch model
|
|
4
|
+
|
|
5
|
+
```
|
|
6
|
+
main ← production-ready, tagged releases only
|
|
7
|
+
develop ← integration branch, PRs merge here first
|
|
8
|
+
release/* ← optional release prep branches (release/0.9.21)
|
|
9
|
+
feature/* ← short-lived feature branches → PR to develop
|
|
10
|
+
hotfix/* ← urgent fixes → PR to main + cherry-pick to develop
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
### Flow
|
|
14
|
+
|
|
15
|
+
1. **Feature work**: branch from `develop` → PR back to `develop`
|
|
16
|
+
2. **Release prep**: branch `release/<version>` from `develop` → bump version, CHANGELOG → merge to `main` + tag
|
|
17
|
+
3. **Hotfix**: branch from `main` → fix → PR to `main` + tag → cherry-pick to `develop`
|
|
18
|
+
4. **Desktop builds**: triggered automatically on tag push, binary artifacts published to GitHub Release
|
|
19
|
+
|
|
20
|
+
## CI/CD workflows
|
|
21
|
+
|
|
22
|
+
| Workflow | File | Triggers | Purpose |
|
|
23
|
+
|---|---|---|---|
|
|
24
|
+
| **CI** | `ci.yml` | push to main/develop, PR to main/develop | typecheck, lint, test, build, audit |
|
|
25
|
+
| **CodeQL** | GitHub default setup | push, PR, weekly cron | security analysis (JS/TS + Actions) — configured in repo Settings → Security → Code security |
|
|
26
|
+
| **Desktop Release** | `desktop-release.yml` | tag push, workflow_dispatch | build desktop binaries, publish to GitHub Release |
|
|
27
|
+
|
|
28
|
+
### CI (`ci.yml`)
|
|
29
|
+
|
|
30
|
+
- Runs on: Ubuntu (full test suite) + Windows (typecheck + lint + build only — Unix path tests skip)
|
|
31
|
+
- Audit: `pnpm audit --audit-level high --prod` (production deps only)
|
|
32
|
+
- Concurrency group cancels stale runs on same ref
|
|
33
|
+
|
|
34
|
+
### Desktop Release (`desktop-release.yml`)
|
|
35
|
+
|
|
36
|
+
- Triggers on: tag push (`*`) or manual dispatch
|
|
37
|
+
- Matrix: macOS 15, Windows 2025, Ubuntu 24.04
|
|
38
|
+
- Verify gates: typecheck + lint + test (Unix only) + build
|
|
39
|
+
- Audit: production deps only, high severity
|
|
40
|
+
- Publish job: downloads all 3 OS artifacts, generates SHA256 checksums, attaches to GitHub Release
|
|
41
|
+
- Signing: optional (uses secrets if available, warns if unsigned)
|
|
42
|
+
|
|
43
|
+
## Secrets management
|
|
44
|
+
|
|
45
|
+
The `.gitignore` excludes:
|
|
46
|
+
- `.env`, `.env.local`, `.env.*.local`
|
|
47
|
+
- `*.pem`, `*.key`, `*.p8`, `*.p12`, `*.secret`
|
|
48
|
+
- `*keypair*.json`, `*wallet*.json`, `id.json`
|
|
49
|
+
- `keypairs/`, `wallets/`
|
|
50
|
+
- `sap-mcp-premium-private/` (separate private repo)
|
|
51
|
+
- `PRIVATE_VPS_DOCS/`, `*.private.md`
|
|
52
|
+
|
|
53
|
+
GitHub Actions secrets (configured in repo settings):
|
|
54
|
+
- `MACOS_CSC_LINK`, `MACOS_CSC_KEY_PASSWORD` — macOS code signing
|
|
55
|
+
- `APPLE_ID`, `APPLE_APP_SPECIFIC_PASSWORD`, `APPLE_TEAM_ID` — notarization
|
|
56
|
+
- `WINDOWS_CSC_LINK`, `WINDOWS_CSC_KEY_PASSWORD` — Windows code signing
|
|
57
|
+
|
|
58
|
+
## Tag convention
|
|
59
|
+
|
|
60
|
+
Tags are plain version numbers: `0.9.21` (NOT `v0.9.21`).
|
|
61
|
+
|
|
62
|
+
## Binary artifacts
|
|
63
|
+
|
|
64
|
+
Desktop binaries are built by CI and published to GitHub Releases only.
|
|
65
|
+
They are never committed to the repo. The `release/` directory is gitignored.
|
|
66
|
+
|
|
67
|
+
Local builds: `pnpm run desktop:build` outputs to `release/desktop/`.
|
package/docs/README.md
CHANGED
|
@@ -64,6 +64,8 @@ For paid/write hosted tools, also configure the local `sap_payments` bridge. The
|
|
|
64
64
|
- [Client Configs](user/04_CLIENT_CONFIGS.md)
|
|
65
65
|
- [Payments: x402 And pay.sh](user/03_PAYMENTS_X402_PAYSH.md)
|
|
66
66
|
- [Smithery And MCP Marketplaces](user/07_SMITHERY_AND_MARKETPLACES.md)
|
|
67
|
+
- [SAP Agent Identity Pipeline](16_SAP_AGENT_IDENTITY_PIPELINE.md)
|
|
68
|
+
- [Premium Plugin Runtime](18_PREMIUM_PLUGIN_RUNTIME.md)
|
|
67
69
|
|
|
68
70
|
## What The Hosted Server Provides
|
|
69
71
|
|
|
@@ -91,8 +93,11 @@ Hosted paid tools use x402 and pay.sh:
|
|
|
91
93
|
- value flows: fixed or percentage pricing only where it is operationally appropriate
|
|
92
94
|
|
|
93
95
|
For agents that cannot replay x402 challenges natively, configure the local
|
|
94
|
-
`sap_payments` MCP bridge and call `sap_payments_call_paid_tool`.
|
|
95
|
-
|
|
96
|
+
`sap_payments` MCP bridge and call `sap_payments_call_paid_tool`. If a hosted
|
|
97
|
+
builder returns an unsigned transaction, finalize it with
|
|
98
|
+
`sap_payments_finalize_transaction` so the local signer previews, signs, and
|
|
99
|
+
optionally submits without exposing keypair bytes. The standalone helper remains
|
|
100
|
+
available as a terminal/custom-wrapper fallback:
|
|
96
101
|
|
|
97
102
|
```bash
|
|
98
103
|
npx --yes --package @oobe-protocol-labs/sap-mcp-server sap-mcp-x402-paid-call \
|
|
@@ -113,6 +118,8 @@ Read these first:
|
|
|
113
118
|
5. [Desktop GUI Wizard](user/06_DESKTOP_GUI_WIZARD.md)
|
|
114
119
|
6. [Configuration And Wizard](03_CONFIGURATION_AND_WIZARD.md)
|
|
115
120
|
7. [Endpoints And Clients](07_ENDPOINTS_AND_CLIENTS.md)
|
|
121
|
+
8. [SAP Agent Identity Pipeline](16_SAP_AGENT_IDENTITY_PIPELINE.md)
|
|
122
|
+
9. [Premium Plugin Runtime](18_PREMIUM_PLUGIN_RUNTIME.md)
|
|
116
123
|
|
|
117
124
|
## Public Endpoints
|
|
118
125
|
|
|
@@ -122,6 +129,16 @@ Read these first:
|
|
|
122
129
|
| `GET /docs` | This documentation site. |
|
|
123
130
|
| `POST /mcp` | Streamable HTTP MCP endpoint for agents. |
|
|
124
131
|
| `GET /server.json` | Public, secret-free machine-readable server metadata. |
|
|
132
|
+
| `GET /premium/catalog.json` | Public premium plugin contracts, pricing models, schemas, and provider readiness. |
|
|
133
|
+
| `GET /premium/streams.json` | Public premium stream contracts for future x402/pay.sh real-time delivery rails. |
|
|
134
|
+
| `GET /premium/webhooks.json` | Public premium webhook contracts with signed delivery expectations. |
|
|
135
|
+
|
|
136
|
+
Premium plugin authors can use `sap_premium_plugin_template` and
|
|
137
|
+
`sap_premium_validate_plugin_manifest` to build strict data-only contracts,
|
|
138
|
+
then deploy reviewed manifests from a private plugin directory. The public
|
|
139
|
+
server never executes plugin code supplied through MCP input and does not expose
|
|
140
|
+
private/enterprise manifests unless the operator explicitly enables private
|
|
141
|
+
discovery.
|
|
125
142
|
| `GET /smithery.config.schema.json` | Optional Smithery setup schema for free discovery, native x402 clients, and local `sap_payments` bridge users. |
|
|
126
143
|
| `GET /.well-known/agent-card.json` | A2A-style agent card. |
|
|
127
144
|
| `GET /.well-known/sap-mcp-wizard.json` | Wizard install descriptor for agents that cannot see local config. |
|
package/docs/magicblock-tools.md
CHANGED
|
@@ -24,21 +24,34 @@ additional configuration needed.
|
|
|
24
24
|
|
|
25
25
|
## Pricing
|
|
26
26
|
|
|
27
|
-
|
|
27
|
+
Hosted pricing is resolved centrally by `src/payments/pricing.ts` and returned
|
|
28
|
+
as an x402/pay.sh challenge before the paid tool executes.
|
|
28
29
|
|
|
29
|
-
| Tier |
|
|
30
|
-
|
|
31
|
-
|
|
|
32
|
-
|
|
|
30
|
+
| Tier | Tools |
|
|
31
|
+
|------|-------|
|
|
32
|
+
| Free/readiness | MCP discovery, SAP skill bootstrap, payment readiness, transaction decode/preview |
|
|
33
|
+
| Read-premium | ER Router queries, balances, swap quotes, mint checks, VRF result |
|
|
34
|
+
| Builder | Deposit, transfer, withdraw, initialize mint, VRF request transaction builders |
|
|
35
|
+
| Value-action | Public/private swap transaction builders and other value-moving actions |
|
|
33
36
|
|
|
34
|
-
|
|
35
|
-
|
|
37
|
+
Do not hard-code MagicBlock prices in agents. Call `sap_x402_estimate_cost` or
|
|
38
|
+
the local `sap_payments_call_paid_tool` helper and enforce the user profile's
|
|
39
|
+
`maxPriceUsd` / spend policy.
|
|
40
|
+
|
|
41
|
+
Successful MagicBlock tool payloads intentionally do not report their own
|
|
42
|
+
price. Hosted cost is authoritative only in the SAP MCP x402 challenge and the
|
|
43
|
+
payment receipt returned by `sap_payments_call_paid_tool`.
|
|
44
|
+
|
|
45
|
+
When a hosted MagicBlock builder returns an unsigned transaction, hosted SAP MCP
|
|
46
|
+
remains non-custodial. Finalize the returned `transactionBase64` with the local
|
|
47
|
+
`sap_payments_finalize_transaction` bridge. Do not call hosted
|
|
48
|
+
`sap_sign_transaction`, create temporary signing scripts, or read keypair JSON.
|
|
36
49
|
|
|
37
50
|
---
|
|
38
51
|
|
|
39
52
|
## Tools (20 total)
|
|
40
53
|
|
|
41
|
-
### ER Router (6 read-only
|
|
54
|
+
### ER Router (6 read-only)
|
|
42
55
|
|
|
43
56
|
| Tool | Description |
|
|
44
57
|
|------|-------------|
|
|
@@ -49,7 +62,7 @@ includes `priceUsd` and `priceBaseUnits` fields for SAP escrow settlement.
|
|
|
49
62
|
| `magicblock_getBlockhashForAccounts` | Get a blockhash for a batch of accounts (max 100) |
|
|
50
63
|
| `magicblock_getSignatureStatuses` | Check transaction confirmation status |
|
|
51
64
|
|
|
52
|
-
### Private Payments — Meta & Auth (3
|
|
65
|
+
### Private Payments — Meta & Auth (3)
|
|
53
66
|
|
|
54
67
|
| Tool | Description |
|
|
55
68
|
|------|-------------|
|
|
@@ -57,14 +70,14 @@ includes `priceUsd` and `priceBaseUnits` fields for SAP escrow settlement.
|
|
|
57
70
|
| `magicblock_challenge` | Generate a challenge string for wallet auth |
|
|
58
71
|
| `magicblock_login` | Exchange signed challenge for bearer token |
|
|
59
72
|
|
|
60
|
-
### Private Payments — Balance (2
|
|
73
|
+
### Private Payments — Balance (2)
|
|
61
74
|
|
|
62
75
|
| Tool | Description |
|
|
63
76
|
|------|-------------|
|
|
64
77
|
| `magicblock_balance` | Read base-chain SPL token balance |
|
|
65
78
|
| `magicblock_privateBalance` | Read ephemeral-rollup SPL balance (requires auth) |
|
|
66
79
|
|
|
67
|
-
### Private Payments — SPL Token Flows (3
|
|
80
|
+
### Private Payments — SPL Token Flows (3)
|
|
68
81
|
|
|
69
82
|
| Tool | Description |
|
|
70
83
|
|------|-------------|
|
|
@@ -74,24 +87,24 @@ includes `priceUsd` and `priceBaseUnits` fields for SAP escrow settlement.
|
|
|
74
87
|
|
|
75
88
|
### Private Payments — Swap (2)
|
|
76
89
|
|
|
77
|
-
| Tool |
|
|
78
|
-
|
|
79
|
-
| `magicblock_swapQuote` |
|
|
80
|
-
| `magicblock_swap` |
|
|
90
|
+
| Tool | Description |
|
|
91
|
+
|------|-------------|
|
|
92
|
+
| `magicblock_swapQuote` | Get a swap quote between two SPL mints |
|
|
93
|
+
| `magicblock_swap` | Build unsigned swap tx (public or private) |
|
|
81
94
|
|
|
82
95
|
### Private Payments — Mint Init (2)
|
|
83
96
|
|
|
84
|
-
| Tool |
|
|
85
|
-
|
|
86
|
-
| `magicblock_initializeMint` |
|
|
87
|
-
| `magicblock_isMintInitialized` |
|
|
97
|
+
| Tool | Description |
|
|
98
|
+
|------|-------------|
|
|
99
|
+
| `magicblock_initializeMint` | Build unsigned mint transfer queue init tx |
|
|
100
|
+
| `magicblock_isMintInitialized` | Check if a mint's transfer queue exists |
|
|
88
101
|
|
|
89
102
|
### VRF (2 — on-chain via @solana/web3.js)
|
|
90
103
|
|
|
91
|
-
| Tool |
|
|
92
|
-
|
|
93
|
-
| `magicblock_requestRandomness` |
|
|
94
|
-
| `magicblock_getRandomnessResult` |
|
|
104
|
+
| Tool | Description |
|
|
105
|
+
|------|-------------|
|
|
106
|
+
| `magicblock_requestRandomness` | Build unsigned tx invoking request_randomness on the VRF program (Vrf1RNUjXmQGjmQrQLvJHs9SNkvDJEsRVFPkfSQUwGz) |
|
|
107
|
+
| `magicblock_getRandomnessResult` | Read the RandomnessRequest account on-chain to check fulfillment and retrieve random bytes |
|
|
95
108
|
|
|
96
109
|
---
|
|
97
110
|
|
|
@@ -126,21 +139,49 @@ Write tools return an unsigned transaction:
|
|
|
126
139
|
Expected flow:
|
|
127
140
|
|
|
128
141
|
1. Call the MagicBlock tool (e.g. `magicblock_deposit`) → get `transactionBase64`
|
|
129
|
-
2.
|
|
130
|
-
|
|
142
|
+
2. If the transaction came from hosted SAP MCP, call local
|
|
143
|
+
`sap_payments_finalize_transaction` with `confirm: true` and `submit: false`
|
|
144
|
+
for preview/sign, or `submit: true` after user approval.
|
|
145
|
+
3. If the transaction came from local stdio SAP MCP, use
|
|
146
|
+
`sap_preview_transaction` → `sap_sign_transaction` →
|
|
147
|
+
`sap_submit_signed_transaction`.
|
|
148
|
+
4. Record the signed transaction or submitted signature in the audit trail.
|
|
149
|
+
|
|
150
|
+
Agents must not create temporary JavaScript signing scripts, read keypair JSON,
|
|
151
|
+
or sign raw message bytes outside SAP MCP transaction tools.
|
|
152
|
+
|
|
153
|
+
## Safety Guardrails
|
|
154
|
+
|
|
155
|
+
SAP MCP fails closed for MagicBlock flows that live testing has shown to be
|
|
156
|
+
unsafe:
|
|
157
|
+
|
|
158
|
+
- `magicblock_swap` with `visibility: "private"` requires a valid
|
|
159
|
+
`destination`. The server rejects the request before contacting MagicBlock if
|
|
160
|
+
the destination is missing or invalid.
|
|
161
|
+
- `magicblock_swap` with `visibility: "private"` and
|
|
162
|
+
`quoteResponse.outputMint = So11111111111111111111111111111111111111112`
|
|
163
|
+
is blocked. Mainnet testing found that private swaps outputting wSOL can leave
|
|
164
|
+
funds stuck in the Hydra mixer pool when shuttle delivery fails. Use
|
|
165
|
+
`visibility: "public"` for SOL output, or swap privately into a non-SOL SPL
|
|
166
|
+
token until MagicBlock provides shuttle delivery recovery.
|
|
167
|
+
- `magicblock_transfer` requires `from`, `to`, `mint`, `amount`,
|
|
168
|
+
`visibility`, `fromBalance`, and `toBalance`. `amount` must be a positive
|
|
169
|
+
JavaScript-safe integer in token base units because the upstream API expects a
|
|
170
|
+
JSON number, not a string.
|
|
171
|
+
- Private transfers require a bearer token from `magicblock_challenge` and
|
|
172
|
+
`magicblock_login`. Private SOL transfers may deliver wSOL, not native SOL;
|
|
173
|
+
agents should say that clearly before asking for confirmation.
|
|
131
174
|
|
|
132
175
|
---
|
|
133
176
|
|
|
134
177
|
## Response Format
|
|
135
178
|
|
|
136
|
-
|
|
179
|
+
Successful tool responses are wrapped by SAP MCP:
|
|
137
180
|
|
|
138
181
|
```json
|
|
139
182
|
{
|
|
140
183
|
"success": true,
|
|
141
184
|
"tool": "magicblock_deposit",
|
|
142
|
-
"priceUsd": "$0.05",
|
|
143
|
-
"priceBaseUnits": "50000",
|
|
144
185
|
"data": { ... }
|
|
145
186
|
}
|
|
146
187
|
```
|
|
@@ -163,4 +204,4 @@ Error responses:
|
|
|
163
204
|
| `src/tools/magicblock-tools.ts` | 20 tool registrations with HTTP client |
|
|
164
205
|
| `src/tools/__tests__/magicblock-tools.test.ts` | 10 smoke tests |
|
|
165
206
|
| `src/tools/index.ts` | Barrel export |
|
|
166
|
-
| `src/tools/register-tools.ts` | Registration call during server init |
|
|
207
|
+
| `src/tools/register-tools.ts` | Registration call during server init |
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oobe-protocol-labs/sap-mcp-server",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.3",
|
|
4
4
|
"mcpName": "ai.oobeprotocol.sap.mcp/sap-mcp",
|
|
5
5
|
"description": "Official MCP gateway for OOBE Protocol SAP — AI agents can interact with SAP identity, registry, reputation, tools, memory, payments, settlement, and proof-of-execution on Solana",
|
|
6
6
|
"type": "module",
|
|
@@ -93,9 +93,11 @@
|
|
|
93
93
|
"@solana/kit": "^5.5.1",
|
|
94
94
|
"@solana/sysvars": "^5.5.1",
|
|
95
95
|
"@solana/web3.js": "^1.95.0",
|
|
96
|
+
"@types/better-sqlite3": "^7.6.13",
|
|
96
97
|
"@x402/core": "^2.17.0",
|
|
97
98
|
"@x402/express": "^2.17.0",
|
|
98
99
|
"@x402/svm": "^2.17.0",
|
|
100
|
+
"better-sqlite3": "^13.0.1",
|
|
99
101
|
"bn.js": "^5.2.1",
|
|
100
102
|
"bs58": "^6.0.0",
|
|
101
103
|
"cli-spinners": "^3.4.0",
|
|
@@ -145,13 +147,15 @@
|
|
|
145
147
|
"engines": {
|
|
146
148
|
"node": ">=22.12.0"
|
|
147
149
|
},
|
|
148
|
-
"packageManager": "pnpm@11.7.0",
|
|
149
150
|
"overrides": {
|
|
150
|
-
"
|
|
151
|
-
"
|
|
151
|
+
"@hono/node-server": "2.0.10",
|
|
152
|
+
"body-parser": "1.20.6",
|
|
153
|
+
"fast-uri": "3.1.4",
|
|
154
|
+
"hono": "4.12.27",
|
|
152
155
|
"langsmith": "^0.6.0",
|
|
156
|
+
"postcss": "8.5.18",
|
|
153
157
|
"uuid": "^11.1.1",
|
|
154
|
-
"vite": "8.1.0",
|
|
155
158
|
"ws": "^8.21.0"
|
|
156
|
-
}
|
|
159
|
+
},
|
|
160
|
+
"packageManager": "pnpm@11.7.0"
|
|
157
161
|
}
|
package/server.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"name": "ai.oobeprotocol.sap.mcp/sap-mcp",
|
|
4
4
|
"title": "SAP MCP Server | OOBE Protocol",
|
|
5
5
|
"description": "Solana-native MCP gateway for SAP tools, DeFi, SNS identity, x402/pay.sh, and agent operations.",
|
|
6
|
-
"version": "0.9.
|
|
6
|
+
"version": "0.9.21",
|
|
7
7
|
"websiteUrl": "https://mcp.sap.oobeprotocol.ai/",
|
|
8
8
|
"repository": {
|
|
9
9
|
"url": "https://github.com/OOBE-PROTOCOL/sap-mcp",
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
{
|
|
30
30
|
"registryType": "npm",
|
|
31
31
|
"identifier": "@oobe-protocol-labs/sap-mcp-server",
|
|
32
|
-
"version": "0.9.
|
|
32
|
+
"version": "0.9.21",
|
|
33
33
|
"transport": {
|
|
34
34
|
"type": "stdio"
|
|
35
35
|
},
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
},
|
|
46
46
|
{
|
|
47
47
|
"type": "positional",
|
|
48
|
-
"value": "@oobe-protocol-labs/sap-mcp-server@0.9.
|
|
48
|
+
"value": "@oobe-protocol-labs/sap-mcp-server@0.9.21"
|
|
49
49
|
},
|
|
50
50
|
{
|
|
51
51
|
"type": "positional",
|
package/skills/README.md
CHANGED
|
@@ -55,10 +55,20 @@ or wants to compare this bundled MCP skill pack with the source SDK skills:
|
|
|
55
55
|
## Agent Behavior
|
|
56
56
|
|
|
57
57
|
- Answer in the same natural language as the user's latest request.
|
|
58
|
-
- Use
|
|
59
|
-
|
|
58
|
+
- Use free exact/base SAP reads before paid discovery when possible:
|
|
59
|
+
`sap_agent_context`, `sap_get_agent`, `sap_get_agent_profile`,
|
|
60
|
+
`sap_get_agent_stats`, `sap_is_agent_active`, `sap_get_global_state`, and
|
|
61
|
+
compact `sap_list_agents` pages with `limit <= 20`.
|
|
62
|
+
- Use `sap_discover_agents` for targeted hosted agent search by query, wallet,
|
|
63
|
+
PDA, protocol, capability, capability list, or x402 endpoint presence.
|
|
64
|
+
- Use `sap_list_all_agents` for current global SAP ecosystem agent lists only
|
|
65
|
+
when the user needs more than the free compact orientation page, and continue
|
|
66
|
+
with `pagination.nextCursor` when more pages are needed.
|
|
60
67
|
- Treat `mcp_sap_<tool>` as a client display prefix; the callable MCP tool name
|
|
61
68
|
inside this server is the suffix, for example `jupiter_getQuote`.
|
|
69
|
+
- Call `sap_agent_next_action` before retrying after `payment_required`,
|
|
70
|
+
`hosted_local_signer_required`, transient Solana RPC errors, a missing local
|
|
71
|
+
bridge, or a submitted signature that has not confirmed.
|
|
62
72
|
- Use `skills/sap-mcp/TOOL_REFERENCE.md` and `USER_DOCS/05_SKILLS_AND_TOOLS.md`
|
|
63
73
|
as the bundled routing maps when deciding which SAP MCP tool or skill domain
|
|
64
74
|
applies to a user request.
|
|
@@ -6,12 +6,31 @@ state, global directory listing, and agent profile inspection.
|
|
|
6
6
|
## First Steps
|
|
7
7
|
|
|
8
8
|
1. Call `sap_profile_current`.
|
|
9
|
-
2. Call `
|
|
10
|
-
|
|
9
|
+
2. Call `sap_protocol_invariants` before registry writes when treasury, fee,
|
|
10
|
+
hosted/local routing, or lifecycle-complete rules are unclear.
|
|
11
|
+
3. For registration, profile-image updates, Metaplex identity, SNS linking, or
|
|
12
|
+
full identity setup, call `sap_agent_identity_plan` before any write. It is
|
|
13
|
+
free and returns normalized fields, local-signer routing, metadata contract,
|
|
14
|
+
forbidden actions, and verification checklist.
|
|
15
|
+
4. Use free exact/base reads before paid discovery: `sap_agent_context`,
|
|
16
|
+
`sap_get_agent`,
|
|
17
|
+
`sap_get_agent_profile`, `sap_get_agent_stats`, `sap_is_agent_active`,
|
|
18
|
+
`sap_get_global_state`, and `sap_list_agents` with `limit <= 20`,
|
|
19
|
+
`view: "compact"`, and `includeProtocolIndexes: false`.
|
|
20
|
+
5. Call `sap_get_network_overview` for ecosystem counters when needed.
|
|
21
|
+
6. Use `sap_discover_agents` with `query`, `wallet`, `protocol`, or
|
|
22
|
+
`capability` for targeted paid hosted directory reads when free exact/base
|
|
23
|
+
reads are not enough.
|
|
24
|
+
7. Use `sap_list_all_agents` for global current agent lists and follow
|
|
25
|
+
`pagination.nextCursor` for additional pages.
|
|
11
26
|
|
|
12
27
|
## Tools
|
|
13
28
|
|
|
14
29
|
- `sap_register_agent`
|
|
30
|
+
- `sap_protocol_invariants`
|
|
31
|
+
- `sap_agent_identity_plan`
|
|
32
|
+
- `sap_agent_context`
|
|
33
|
+
- `sap_agent_next_action`
|
|
15
34
|
- `sap_update_agent`
|
|
16
35
|
- `sap_deactivate_agent`
|
|
17
36
|
- `sap_reactivate_agent`
|
|
@@ -21,6 +40,7 @@ state, global directory listing, and agent profile inspection.
|
|
|
21
40
|
- `sap_get_agent_stats`
|
|
22
41
|
- `sap_get_global_state`
|
|
23
42
|
- `sap_get_network_overview`
|
|
43
|
+
- `sap_list_agents`
|
|
24
44
|
- `sap_list_all_agents`
|
|
25
45
|
- `sap_is_agent_active`
|
|
26
46
|
- `sap_report_calls`
|
|
@@ -28,7 +48,52 @@ state, global directory listing, and agent profile inspection.
|
|
|
28
48
|
|
|
29
49
|
## Routing
|
|
30
50
|
|
|
31
|
-
-
|
|
51
|
+
- Hosted accountless SAP MCP cannot sign user-owned registry writes. If
|
|
52
|
+
`sap_register_agent`, `sap_update_agent`, or another registry write returns
|
|
53
|
+
`hosted_local_signer_required`, no x402 payment was charged. For agent
|
|
54
|
+
registration, call the local `sap_payments.sap_payments_register_agent`
|
|
55
|
+
bridge with the same fields and `confirm: true`; it signs locally with the
|
|
56
|
+
active SAP MCP profile. For agent profile, image, metadata, capability,
|
|
57
|
+
protocol, pricing, or x402 endpoint updates, call local
|
|
58
|
+
`sap_payments.sap_payments_update_agent` with the same update fields and
|
|
59
|
+
`confirm: true`. For other registry writes, run the write on the local SAP
|
|
60
|
+
MCP profile or use a production unsigned builder/finalizer flow when
|
|
61
|
+
available.
|
|
62
|
+
- Before any retry after `payment_required`, `hosted_local_signer_required`,
|
|
63
|
+
`BlockhashNotFound`, timeout, missing `sap_payments`, or a submitted
|
|
64
|
+
signature that did not confirm, call `sap_agent_next_action`. Follow its
|
|
65
|
+
`safeToRetryNow`, `nextTool`, and `forbiddenActions` fields.
|
|
66
|
+
- Agent pictures must be public metadata, not desktop file paths. Upload the
|
|
67
|
+
image or metadata JSON to IPFS, Arweave, Kommodo, or HTTPS, then set
|
|
68
|
+
`agentUri`/`metadataUri` with `sap_payments_update_agent`.
|
|
69
|
+
- After `sap_payments_register_agent`, do not stop at a Solscan link. Verify
|
|
70
|
+
`success`, `agentRegistered`, `agentPda`, `confirmationStatus`,
|
|
71
|
+
`protocolComplete`, and `protocolFee.status`. A complete registration should
|
|
72
|
+
show the expected protocol fee credited to treasury
|
|
73
|
+
`J7PyZAGKvprCz4SQ5DKBLAHstJxgVqZcz6kguUoWpP7P`. If `success` is false but
|
|
74
|
+
`agentRegistered` is true, the account may exist but SAP registration is not
|
|
75
|
+
protocol-complete. Report the integrity issue and do not retry automatically.
|
|
76
|
+
- After `sap_payments_update_agent`, fetch the agent profile again and verify
|
|
77
|
+
the changed fields. For image/profile updates, `agentUri` or `metadataUri`
|
|
78
|
+
must resolve to public metadata containing the image URL.
|
|
79
|
+
- If `sap_payments_update_agent` returns Anchor 3012, `AccountNotInitialized`,
|
|
80
|
+
or mentions `pricing_menu`, do not run runtime repair and do not retry the
|
|
81
|
+
same write. This means the write reached the SAP on-chain program but a
|
|
82
|
+
required registry lifecycle PDA is missing or stale. Call
|
|
83
|
+
`sap_agent_next_action` and `sap_protocol_invariants`, then upgrade the
|
|
84
|
+
SDK/server or use the initializer path before retrying.
|
|
85
|
+
- For full agent identity setup, follow
|
|
86
|
+
`docs/16_SAP_AGENT_IDENTITY_PIPELINE.md`: SAP registration first, optional
|
|
87
|
+
Metaplex/MPL Core identity, optional SNS domain and records, then a final SAP
|
|
88
|
+
update that points `metadataUri` at the public metadata document.
|
|
89
|
+
- "Find XONA Agent" or "find an agent by name" means `sap_discover_agents` with
|
|
90
|
+
`query`.
|
|
91
|
+
- "Find x402 agents" means `sap_discover_agents` with
|
|
92
|
+
`hasX402Endpoint: true`.
|
|
93
|
+
- "List all agents" means first call free `sap_list_agents` with
|
|
94
|
+
`limit <= 20`, `view: "compact"`, and `includeProtocolIndexes: false`; then
|
|
95
|
+
use paid `sap_list_all_agents` with `pagination.nextCursor` if the user wants
|
|
96
|
+
more, full rows, or ecosystem-scale enumeration.
|
|
32
97
|
- "Agent by wallet" means `sap_get_agent` or `sap_get_agent_profile`.
|
|
33
98
|
- "Is this agent live?" means `sap_is_agent_active`.
|
|
34
99
|
- "Network totals" means `sap_get_network_overview`.
|
|
@@ -36,4 +101,34 @@ state, global directory listing, and agent profile inspection.
|
|
|
36
101
|
## Safety
|
|
37
102
|
|
|
38
103
|
Registration and update tools are write operations. Explain the action, read
|
|
39
|
-
policy context, and never inspect keypair files.
|
|
104
|
+
policy context, require explicit confirmation, and never inspect keypair files.
|
|
105
|
+
For registrations, distinguish `agent account exists` from `protocol lifecycle
|
|
106
|
+
complete`; the latter requires confirmation plus a non-failing protocol fee
|
|
107
|
+
audit.
|
|
108
|
+
|
|
109
|
+
## Canonical Register Fields
|
|
110
|
+
|
|
111
|
+
Use these exact fields for `sap_payments_register_agent` and local
|
|
112
|
+
`sap_register_agent`:
|
|
113
|
+
|
|
114
|
+
- `name`: public display name.
|
|
115
|
+
- `description`: public purpose, capabilities, and trust boundary.
|
|
116
|
+
- `capabilities`: array of strings or objects. Prefer object form:
|
|
117
|
+
`{ "id": "jupiter:swap", "description": "...", "protocolId": "jupiter", "version": "1.0.0" }`.
|
|
118
|
+
- `pricing`: array of pricing tiers. For x402/pay.sh use
|
|
119
|
+
`{ "pricePerCall": "1000", "tokenType": "usdc", "settlementMode": "x402", "tokenDecimals": 6 }`;
|
|
120
|
+
USDC amounts are micro-USDC.
|
|
121
|
+
- `protocols`: array such as `["sap", "mcp", "jupiter", "pyth", "metaplex"]`.
|
|
122
|
+
- `agentId`: stable lowercase id, for example `solking`.
|
|
123
|
+
- `agentUri` or `metadataUri`: public metadata/profile URL. Never a local path.
|
|
124
|
+
- `x402Endpoint`: optional `https://host/.well-known/x402`.
|
|
125
|
+
- `confirm`: required `true` on the local `sap_payments` bridge.
|
|
126
|
+
- `protocolFee`: returned output audit for registration; verify it before
|
|
127
|
+
announcing completion.
|
|
128
|
+
|
|
129
|
+
## Canonical Update Fields
|
|
130
|
+
|
|
131
|
+
`sap_payments_update_agent` accepts the same profile fields as registration,
|
|
132
|
+
but every field is optional. Omitted fields stay unchanged. Array fields
|
|
133
|
+
replace the full on-chain list, so fetch the current agent first before adding
|
|
134
|
+
only one capability, protocol, or pricing tier.
|
package/skills/sap-defi/SKILL.md
CHANGED
|
@@ -40,12 +40,16 @@ staking protocols.
|
|
|
40
40
|
## Flow
|
|
41
41
|
|
|
42
42
|
1. Use quote/read tools first.
|
|
43
|
-
2.
|
|
44
|
-
`jupiter_swapInstructions
|
|
43
|
+
2. In hosted mode, prefer quote/read tools and unsigned builders such as
|
|
44
|
+
`jupiter_getOrder`, `jupiter_swapInstructions`, or supported private swap
|
|
45
|
+
builders. Direct signer tools such as `jupiter_swap`, `jupiter_smartSwap`,
|
|
46
|
+
and `jupiter_executeOrder` require a local SAP MCP profile or external
|
|
47
|
+
signer and are rejected before x402 payment on hosted accountless servers.
|
|
45
48
|
3. Explain slippage, route, token mints, amount units, and expected output.
|
|
46
49
|
4. Preview and policy-check before signing.
|
|
47
|
-
5. For any unsigned or partially signed transaction returned by
|
|
48
|
-
|
|
50
|
+
5. For any unsigned or partially signed transaction returned by hosted SAP MCP,
|
|
51
|
+
use `sap_payments_finalize_transaction`. For local SAP MCP stdio builders,
|
|
52
|
+
use `sap_preview_transaction`, `sap_sign_transaction`, and
|
|
49
53
|
`sap_submit_signed_transaction`. Do not write ad-hoc signing scripts.
|
|
50
54
|
|
|
51
55
|
## Safety
|