Skip to main content
Examples use API client signing.

Signing request types

To sign transactions you build yourself or messages you format yourself, use raw signing.

Wallet

Create a wallet with networkType: "NETWORK_TYPE_SUI". Fund it with more than 1 SUI for the transfer example and transaction fees, plus the coin balance for non-native transfers.

Send SUI

This Sui Mainnet example sends 1 SUI. CreateSigningRequest
value is an integer string in MIST: 1 SUI = 1,000,000,000 MIST.

Send USDC

Replace suiSendNative with this payload in the same request:
This example sends 1 USDC on Sui Mainnet. coinTag is Circle’s full Sui Mainnet USDC coin type. amount: "1000000" sends 1 USDC (six decimals). SUI pays transaction fees.

Call Move functions

For Move calls or a PTB combining multiple actions, replace the transaction payload with suiSendCustom. Keep the common fields and broadcastTx: true.
payload is standard, padded base64 of either:
  • UTF-8 transaction JSON from Transaction.toJSON(): version 2, with inputs and commands, plus optional sender, gasData and expiration. Your application resolves SDK intents before submission.
  • BCS-serialized TransactionData, including the transaction kind, sender, gas data and expiration.
Your application defines the calls and inputs. MPCVault resolves JSON object inputs and fills missing sender, gas payment, gas budget, gas price and expiration before signing. The resulting bytes can differ from the submitted payload. Encode the payload before submitting it.

Sign and track

Sign the request. The returned txHash is the Sui transaction digest. Query that digest with Sui GraphQL:
data.transaction.effects.status: "SUCCESS" confirms execution; "FAILURE" includes executionError.message. A non-null checkpoint records checkpoint inclusion. Poll at a bounded interval while data.transaction is null; inspect any GraphQL errors before interpreting the result.

Sign a message

Create a message signing request with suiMessage and omit broadcastTx:
content is standard, padded base64 of the original UTF-8 message text. MPCVault applies Sui’s personal-message intent when signing. Execute the request using the shared message-signing flow. The returned eddsaSignature contains the raw 64-byte signature as base64. Sui SDK verification uses base64(0x00 || signature64 || publicKey32); GetWalletInfo returns the wallet’s public key in details.publicKey as base64. Decode both values before concatenating the bytes.