Skip to main content

Function Signature

Description

Signs an ERC-4337 UserOperation using the client’s MPC key without broadcasting it to the network. This method is invoked via portal.request() with the method set to eth_signUserOperation. The signed UserOperation can then be submitted through a separate backend (e.g., Pimlico or a custom bundler endpoint).
This method requires the client to be created with Account Abstraction enabled (isAccountAbstracted: true). Non-AA clients will receive a METHOD_UNSUPPORTED error.

Parameters

The params array takes a single object with the following fields:

Returns

PortalProviderResponse - An object containing:

Example

With EIP-1559 Gas Parameters

Errors