Skip to main content
Function Signature
Where:
Description Replaces the signer that approveAndSubmit, revokeAndSubmit, and transferAndSubmit use when no per-call DelegationSubmitOptions.signAndSendTransaction is provided. The signer receives one transaction and the CAIP-2 chain ID, signs and broadcasts it, and returns the transaction hash. Portal already installs a signer on portal.delegations that routes .evm transactions to eth_sendTransaction and .solana transactions to sol_signAndSendTransaction, so you only need this method to change that behavior — for example to attach a signatureApprovalMemo, add your own logging, or route signing through a different key. Signer precedence is per-call DelegationSubmitOptions.signAndSendTransaction → the signer set here → the Portal default. Parameters The transaction argument is a DelegationTransaction:
Each accessor returns nil for the other case, so you can branch with if let instead of writing a full switch. ConstructedEipTransaction is Codable, so you can encode it for logging or to hand it off to another process. Returns Nothing. The signer is stored on the instance and used by subsequent submit calls. Throws Nothing. Errors from the signer itself surface from whichever submit method invoked it. Notes
  • The stored signer is not access-synchronized. Set it once — during app setup, before any submit call — rather than changing it while a submit is in flight. To vary the signer per call, pass DelegationSubmitOptions.signAndSendTransaction instead.
Example Usage
Related Documentation