rhinestone, rhinestoneAccount, and the session owner account.
1
Create the sessions
Define every session before asking the account owner to sign. A session’s chain is part of its authorization:Examples on this page use Each session can use different owners and restrictions. Reusing the same session owner does not make the on-chain sessions interchangeable.
@rhinestone/sdk, where rhinestone is the RhinestoneSDK instance from Create a session with a custom setup.2
Sign once
Get the authorization details, then ask the account owner for one signature:
getSessionDetails reads the required nonce on every session chain and builds one MultiChainSession typed-data message. Store the resolved sessions, sessionDetails.hashesAndChainIds, signature, and indexes together. Rebuilding or reordering the array changes which index enables which session.3
Enable and use each session
Pass a per-chain session map when one transaction can touch several chains. Select a funded
enableData lets the first operation on a chain enable and use that chain’s session in one flow:sourceTokenAddress on Base Sepolia and the destinationTokenAddress, amount, and calls on Optimism Sepolia. Configure a session for the selected EVM source chain and the EVM destination where the account executes. The SDK fails before signing if a required chain has no session.First-use enableData adds source-chain pre-claim calls, so even a sponsored no-delivery intent needs an explicit source when enabling this way. Enable destination sessions separately first if they are not yet active.Enable a session separately
Use the same signed details to enable one session in an account-owner transaction before the session is used:enableData. Check first with rhinestoneAccount.isSessionEnabled(session) when your application does not track activation reliably.
Constraints
- A session authorization is chain-specific even when its owner and permissions match another chain.
- Session keys cannot sign a chain-agnostic origin payload whose one signature must validate across several chains. Split that operation into per-chain intents.
- Accounts using the K1 validator cannot sign one multi-chain session authorization. Sign and enable one chain at a time.
- Keep the original session order.
sessionToEnableIndexselects an entry in the signedhashesAndChainIdsset. - A session scoped by a cross-chain permit cannot run destination calls or leftover sweeps by itself. The destination chain’s session must declare those actions or set
fallback. - A one-time-use session burns its ID on each chain an intent settles on.
Cross-chain permits restrict which assets a session may move between chains.
They do not enable the session on those chains. Configure both features when
you need both behaviors. See Cross-chain
permits.