portal_flutter library
Flutter SDK for Portal - MPC wallet infrastructure
This library provides a complete Flutter interface to the Portal MPC wallet system. Portal enables secure, user-friendly Web3 wallet experiences using Multi-Party Computation (MPC).
Classes
- BlockaidScanAddressRequest
- Request to scan an address via Blockaid
- BlockaidScanAddressResponse
- Response from scanning an address via Blockaid
- BlockaidScanEvmRequest
- Request to scan an EVM transaction via Blockaid
- BlockaidScanEvmResponse
- Response from scanning an EVM transaction via Blockaid
- BlockaidScanSolanaRequest
- Request to scan a Solana transaction via Blockaid
- BlockaidScanSolanaResponse
- Response from scanning a Solana transaction via Blockaid
- BlockaidScanTokensRequest
- Request to scan tokens via Blockaid
- BlockaidScanTokensResponse
- Response from scanning tokens via Blockaid
- BlockaidScanUrlRequest
- Request to scan a URL via Blockaid
- BlockaidScanUrlResponse
- Response from scanning a URL via Blockaid
- Build7702UpgradeTxData
- Data portion of Build7702UpgradeTxResponse
- Build7702UpgradeTxMetadata
- Metadata portion of Build7702UpgradeTxResponse
- Build7702UpgradeTxResponse
-
Response from
build7702UpgradeTx. - BuildAuthorizationListData
- Data portion of BuildAuthorizationListResponse
- BuildAuthorizationListMetadata
- Metadata portion of BuildAuthorizationListResponse
- BuildAuthorizationListResponse
-
Response from
buildAuthorizationList. - DelegationApproveMetadata
- Metadata for approve delegation response
- DelegationApproveRequest
- Request to approve a delegation
- DelegationApproveResponse
- Response from approve delegation
- DelegationConstructedTransaction
- EVM transaction for delegation operations
- DelegationGetStatusRequest
- Request to get delegation status
- DelegationRevokeMetadata
- Metadata for revoke delegation response
- DelegationRevokeRequest
- Request to revoke a delegation
- DelegationRevokeResponse
- Response from revoke delegation
- DelegationStatus
- Status of a single delegation
- DelegationStatusResponse
- Response from get delegation status
- DelegationSubmitProgress
- Progress event emitted during a delegation submit flow.
- DelegationSubmitProgressEvent
- Progress event emitted by the native SDK during a delegation submit flow.
- DelegationSubmitResponse
- Result of a high-level delegation submit flow.
- DelegationTransferFromMetadata
- Metadata for transfer from delegation response
- DelegationTransferFromRequest
- Request to transfer from delegation
- DelegationTransferFromResponse
- Response from transfer from delegation
- Eip7702AuthorizationListItem
- Single signed authorization tuple inside an EIP-7702 transaction.
- Eip7702TransactionResult
- Unsigned EIP-7702 transaction that the consumer should send to the network.
- EvmAccountTypeAddresses
- The EOA and smart contract addresses for an EVM account.
- EvmAccountTypeData
- EVM account type data containing the status
- EvmAccountTypeMetadata
- EVM account type metadata
- EvmAccountTypeStatusResponse
- Response from getting EVM account type status
- EvmAuthorizationDetail
- Authorization detail used in EIP-7702 builder responses
- EvmAuthorizationSignature
-
Authorization signature returned in the
build7702UpgradeTxmetadata. - HypernativeScanAddressesItem
- Item in the address scan response
- HypernativeScanAddressesRequest
- Request to scan addresses with Hypernative
- HypernativeScanAddressesResponse
- Response from scanning addresses
- HypernativeScanEip712Request
- Request to scan an EIP-712 message with Hypernative
- HypernativeScanEvmRequest
- Request to scan an EVM transaction with Hypernative
- HypernativeScanNftItem
- NFT item for scan request
- HypernativeScanNftResultItem
- NFT scan result item
- HypernativeScanNftsRequest
- Request to scan NFTs with Hypernative
- HypernativeScanNftsResponse
- Response from scanning NFTs
- HypernativeScanSolanaRequest
- Request to scan a Solana transaction with Hypernative
- HypernativeScanTokenItem
- Token item for scan request
- HypernativeScanTokenResultItem
- Token scan result item
- HypernativeScanTokensRequest
- Request to scan tokens with Hypernative
- HypernativeScanTokensResponse
- Response from scanning tokens
- HypernativeScanTransactionResponse
- Response from scanning a transaction (EVM, EIP-712, or Solana)
- HypernativeScanUrlRequest
- Request to scan a URL with Hypernative
- HypernativeScanUrlResponse
- Response from scanning a URL
- Lifi
- LiFi cross-chain swap and bridging functionality
- LifiAction
- Action details within a LiFi step
- LifiChainStatus
- Chain status information in a LiFi transfer
- LifiEstimate
- Estimate details for a LiFi step
- LifiFeeCost
- Fee cost information
- LifiGasCost
- Gas cost information
- LifiQuoteRequest
- Request for getting a LiFi quote
- LifiQuoteResponse
- Response containing a single LiFi quote
- LifiRoute
- A complete LiFi route
- LifiRoutesRequest
- Request for getting LiFi routes
- LifiRoutesRequestOptions
- Options for LiFi routes request
- LifiRoutesResponse
- Response containing available LiFi routes
- LifiStatusRequest
- Request for getting LiFi transaction status
- LifiStatusResponse
- Response containing LiFi transfer status
- LifiStep
- A step in a LiFi route
- LifiStepTransactionRequest
- Request for getting unsigned transaction for a route step
- LifiStepTransactionResponse
- Response containing unsigned transaction for a route step
- LifiToken
- Token information in LiFi
- LifiToolsConfiguration
- Configuration for which bridges/exchanges to use
- Unavailable routes information
- PendingBackup
- A backup attempt.
- Portal
- Main Portal SDK class for Flutter
- PortalAddresses
- Wallet addresses for different chains
- PortalAsset
- Asset balance from getAssets
- PortalAssetMetadata
- Asset metadata
- PortalAssetsResponse
- Response containing assets list
- PortalBackupConfig
- Backup configuration
- Metadata for a single backup share pair.
- PortalBalance
- Simple token balance from the getBalances endpoint
- PortalBlockaid
- Blockaid security scanning integration for Portal.
- PortalBuildEip155TransactionResponse
-
Response from
PortalHostApi.buildEip155Transaction. - PortalBuildSolanaTransactionResponse
-
Response from
PortalHostApi.buildSolanaTransaction. - PortalBuildTransactionMetadata
- Metadata describing the transaction returned by the build-transaction endpoint (token info, amounts, and addresses involved).
- PortalBuildTransactionParam
- Parameters for building an unsigned transaction via the Portal backend.
- PortalClientEnvironment
- Client environment configuration
- PortalClientInfo
- Client information response
- PortalDelegations
- Portal Delegations API
- PortalEip155Transaction
-
Unsigned EIP-155 transaction payload returned by
PortalHostApi.buildEip155Transaction. - PortalEvaluateTransactionParam
- Parameters for evaluating a transaction
- PortalEvaluateTransactionResult
- Result from evaluating a transaction
- PortalEventData
- A single event delivered through the Portal.events broadcast stream.
- PortalEvmAccountType
- Portal EVM Account Type API (EIP-7702)
- PortalFeatureFlags
- Feature flags for controlling Portal SDK behavior
- PortalFundRequest
- Parameters for requesting testnet assets
- PortalFundResult
- Result from testnet funding request
- PortalGDriveConfig
- Google Drive configuration
- PortalGetAddressesResult
- Result from checking if wallet exists on device
- PortalGetTransactionDetailsResponse
- PortalHypernative
- Hypernative security scanning integration for Portal.
- PortalLogger
- Singleton logger for the Portal SDK.
- PortalMpcStatus
- MPC operation progress status
- PortalNftAsset
- NFT asset from getNftAssets
- PortalNftMetadata
- NFT metadata
- PortalPasskeyConfig
- Passkey configuration
- PortalProviderResponse
- Generic response from provider requests
- PortalRequestParams
- Generic request parameters
- PortalSecurity
- Security scanning integrations for Portal.
- PortalSendAssetParams
- Asset send parameters
- Metadata for a single signing share pair.
- PortalTransaction
- Transaction from getTransactions
- PortalTransactionRequest
- Ethereum transaction request parameters
- PortalWallet
- Wallet information from client response
- PortalYield
- Portal Yield API
- PortalYieldXyz
- Yield.xyz integration for Portal
- PortalZeroX
- 0x DEX aggregator swap functionality
- Trading
- Trading functionality including LiFi cross-chain swaps and 0x DEX aggregation
- YieldBalance
- Yield balance
- YieldBalanceItem
- Yield balance item
- YieldOpportunity
- Yield opportunity
- YieldXyzActionResponse
- Response from entering/exiting/managing yield
- YieldXyzActionTransaction
- Yield.xyz action transaction
- YieldXyzArgument
- Yield.xyz argument
- YieldXyzArgumentField
- Yield.xyz argument field
- YieldXyzArguments
- Yield.xyz arguments
- YieldXyzBalancePendingAction
- Yield balance pending action
- YieldXyzCooldownPeriod
- Yield.xyz cooldown period
- YieldXyzEnterRequest
- Request to enter a yield position
- YieldXyzEntryLimits
- Yield.xyz entry limits
- YieldXyzExitRequest
- Request to exit a yield position
- YieldXyzFee
- Yield.xyz fee
- YieldXyzGetBalancesMetadata
- Yield.xyz balances metadata
- YieldXyzGetBalancesQuery
- Query for balance request
- YieldXyzGetBalancesRequest
- Request to get yield balances
- YieldXyzGetBalancesResponse
- Response from getting yield balances
- YieldXyzGetHistoricalActionsRequest
- Request to get historical yield actions
- YieldXyzGetHistoricalActionsResponse
- Response from getting historical yield actions
- YieldXyzGetTransactionMetadata
- Yield.xyz get transaction metadata
- YieldXyzGetTransactionResponse
- Response from getting a transaction
- YieldXyzGetYieldsRequest
- Request to discover yield opportunities
- YieldXyzGetYieldsResponse
- Response from discovering yield opportunities
- YieldXyzHistoricalActionItem
- Historical action item
- YieldXyzLockupPeriod
- Yield.xyz lockup period
- YieldXyzManageRequest
- Request to manage a yield position
- YieldXyzMechanics
- Yield.xyz mechanics
- YieldXyzOpportunityMetadata
- Yield.xyz opportunity metadata
- YieldXyzPossibleFeeTakingMechanisms
- Yield.xyz fee taking mechanisms
- YieldXyzRewardRateComponent
- Yield.xyz reward rate component
- YieldXyzStatistics
- Yield.xyz statistics
- YieldXyzToken
- Yield.xyz token
- YieldXyzTrackTransactionResponse
- Response from tracking a transaction
- YieldXyzWarmupPeriod
- Yield.xyz warmup period
- ZeroXAllowanceIssue
- 0x token allowance issue details.
- ZeroXBalanceIssue
- 0x token balance issue details.
- ZeroXFeeDetail
- Generic 0x fee detail.
- ZeroXFees
- Fee breakdown for a 0x swap.
- ZeroXFill
- A single fill in a 0x swap route.
- ZeroXIssues
- Issues that may affect a 0x swap.
- ZeroXPriceRequest
-
Request for getting a price quote from 0x (no transaction data).
Note:
chainIdis used for the URL path and is also included in the request body. - ZeroXPriceResponse
- Response model for 0x price request (no transaction data).
- ZeroXQuoteRequest
-
Request for getting a swap quote from 0x.
Note:
chainIdis used for the URL path and is also included in the request body. - ZeroXQuoteResponse
- Response model for 0x quote request (with transaction data).
- ZeroXRoute
- Route information for a 0x swap.
- ZeroXRouteToken
- Token information in a 0x route.
- ZeroXSourcesResponse
- Response model for 0x sources request.
- ZeroXTokenMetadata
- Token metadata for a 0x swap.
- ZeroXTokenTaxMetadata
- Tax metadata for a token.
- ZeroXTransaction
- Transaction data from a 0x quote.
- ZeroXZeroExFeeDetail
- 0x protocol fee detail.
Enums
- DelegationSubmitStep
- The step of a high-level delegation submit flow.
- LifiRoutesOrder
- LiFi routes ordering preference
- LifiStatusBridge
- LiFi bridge types for status tracking
- LifiTransferStatus
- LiFi transfer status enum
- PortalBackupMethod
- Backup method enum
- PortalEvaluateTransactionOperationType
- Transaction evaluation operation type
- PortalEvent
- Standard Portal events emitted by the SDK.
- PortalGDriveBackupOption
- Where Google Drive backups are written.
- PortalLogLevel
- Log level for the Portal SDK
- PortalMpcStatuses
- MPC operation status values
- Status of a share pair as returned by the metadata accessors.
- Type of MPC share pair (backup or signing).
-
New status to write via
PortalHostApi.updateShareStatus. - PortalTransactionOrder
- Order for transactions list
- YieldXyzActionExecutionPattern
- Yield.xyz action execution pattern
- YieldXyzActionIntent
- Yield.xyz action intent
- YieldXyzActionStatus
- Yield.xyz action status
- YieldXyzActionTransactionStatus
- Yield.xyz action transaction status
- YieldXyzArgumentFieldName
- Yield.xyz argument field name
- YieldXyzArgumentFieldType
- Yield.xyz argument field type
- YieldXyzGetYieldsSort
- Yield.xyz discover sort
- YieldXyzMechanicsType
- Yield.xyz mechanics type
- YieldXyzRateType
- Yield.xyz rate type
- YieldXyzRewardClaiming
- Yield.xyz reward claiming
- YieldXyzRewardSchedule
- Yield.xyz reward schedule
- YieldXyzSource
- Yield.xyz yield source
Extensions
- Eip7702TransactionResultExt on Eip7702TransactionResult
- Convenience accessor that decodes the JSON-encoded authorization list.
Constants
- portalTraceIdHeader → const String
- The HTTP header Portal uses to correlate requests end-to-end.
Functions
-
generateTraceId(
) → String - Generates a UUID v4 trace ID for request correlation.
Exceptions / Errors
- PortalException
- Exception thrown by Portal SDK operations