Summary
Create a production-grade demo path that combines:
- managed owner custody/signing (Privy)
- on-chain session-key policy enforcement (SessionAccount)
- signer-boundary isolation for runtime session signing (SISNA/keyring proxy)
This should supersede the current split where:
examples/starkzap-onboard-transfer demonstrates Privy + Starkzap onboarding/transfer
examples/full-stack-swarm demonstrates session-key policy + proxy signing
Problem
Today we have strong pieces, but no single production-grade end-to-end reference that demonstrates both:
- managed owner key custody (no raw owner private key in app/runtime process)
- delegated session execution with on-chain spend/selector guardrails and verifiable deny paths
full-stack-swarm currently uses STARKNET_SIGNER_MODE=direct + STARKNET_PRIVATE_KEY for owner-side setup steps, which is useful for demos but not ideal as a production reference architecture.
Goal
Deliver an explicit reference flow for Sepolia that proves the intended production trust boundaries:
- Owner/admin actions are signed via Privy (or equivalent managed custody signer mode)
- Session execution is signed only via proxy boundary (SISNA/keyring), never by app process keys
- On-chain guardrails enforce policy (spend cap + selector blocklist)
- Demo outputs include positive and negative execution evidence links
Scope
In scope
- Add a new signer mode path for owner-side MCP operations that supports Privy-backed signing
- Keep session path on
proxy signer mode (existing keyring contract unchanged)
- New/updated example flow that runs:
- deploy SessionAccount
- register ERC-8004 identity + link account
- add session key + set spending policy
- successful transfer/swap within cap
- deliberate over-cap rejection
- deliberate admin-selector rejection (if included in selected flow)
- Documentation: architecture diagram, env vars, security notes, expected evidence artifacts
Out of scope
- Replacing proxy/session signer boundary with Privy for delegated session signatures
- Mainnet rollout in this issue
- UI-level production integration in Starkclaw app
Acceptance criteria
- No owner private key required for owner-side setup flow in the new reference demo
- Session execution still requires proxy signer mode and emits 4-felt session signatures
- At least one deny-path tx is reproducible and captured in output report
- CI/README reproduce steps validated on Sepolia
- Security notes clearly document trust boundaries and failure modes
Proposed implementation slices
packages/starknet-mcp-server: add STARKNET_SIGNER_MODE=privy (owner/admin only)
examples/full-stack-swarm (or sibling examples/full-stack-swarm-privy): wire owner sidecars to privy signer mode
- Keep trade/session sidecars in proxy mode
- Add runbook and evidence template
Risks
- Signer interface mismatch between existing MCP account signer abstraction and Privy signer requirements
- Env complexity and operational UX (Privy server URL/auth, paymaster, proxy config)
- Confusion between owner signer mode and session signer mode unless docs are explicit
Dependencies
- Privy app credentials and signing endpoint availability
- Sepolia paymaster/API keys for gasless paths
- SISNA/keyring proxy deployment for session signing path
Nice-to-have follow-ups
- Mergeable checklist for “production trust boundary compliance” across examples
- Optional telemetry fields tying deny-path tx hashes to policy snapshot IDs
Summary
Create a production-grade demo path that combines:
This should supersede the current split where:
examples/starkzap-onboard-transferdemonstrates Privy + Starkzap onboarding/transferexamples/full-stack-swarmdemonstrates session-key policy + proxy signingProblem
Today we have strong pieces, but no single production-grade end-to-end reference that demonstrates both:
full-stack-swarmcurrently usesSTARKNET_SIGNER_MODE=direct+STARKNET_PRIVATE_KEYfor owner-side setup steps, which is useful for demos but not ideal as a production reference architecture.Goal
Deliver an explicit reference flow for Sepolia that proves the intended production trust boundaries:
Scope
In scope
proxysigner mode (existing keyring contract unchanged)Out of scope
Acceptance criteria
Proposed implementation slices
packages/starknet-mcp-server: addSTARKNET_SIGNER_MODE=privy(owner/admin only)examples/full-stack-swarm(or siblingexamples/full-stack-swarm-privy): wire owner sidecars to privy signer modeRisks
Dependencies
Nice-to-have follow-ups