SuiStealthService
SIP Protocol API Reference v0.7.0
SIP Protocol API Reference / SuiStealthService
Class: SuiStealthService
Section titled “Class: SuiStealthService”Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:2802
Sui Stealth Service
Provides a convenient class-based interface for Sui stealth address operations. This is useful when you need to perform multiple operations or want to encapsulate the logic in a service object.
Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new SuiStealthService():
SuiStealthService
Returns
Section titled “Returns”SuiStealthService
Methods
Section titled “Methods”generateStealthAddress()
Section titled “generateStealthAddress()”generateStealthAddress(
recipientMetaAddress):SuiStealthResult
Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:2809
Generate a stealth address for a Sui recipient
Parameters
Section titled “Parameters”recipientMetaAddress
Section titled “recipientMetaAddress”Recipient’s stealth meta-address
Returns
Section titled “Returns”Complete stealth address result
stealthKeyToSuiAddress()
Section titled “stealthKeyToSuiAddress()”stealthKeyToSuiAddress(
publicKey):string
Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:2816
Convert an ed25519 public key to Sui address format
Parameters
Section titled “Parameters”publicKey
Section titled “publicKey”`0x${string}`
32-byte ed25519 public key
Returns
Section titled “Returns”string
Sui address string
deriveStealthPrivateKey()
Section titled “deriveStealthPrivateKey()”deriveStealthPrivateKey(
stealthAddress,spendingPrivateKey,viewingPrivateKey):object
Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:2825
Derive the private key for a stealth address
Parameters
Section titled “Parameters”stealthAddress
Section titled “stealthAddress”Stealth address data
spendingPrivateKey
Section titled “spendingPrivateKey”`0x${string}`
Recipient’s spending private key
viewingPrivateKey
Section titled “viewingPrivateKey”`0x${string}`
Recipient’s viewing private key
Returns
Section titled “Returns”object
Recovery data with derived private key
stealthAddress
Section titled “stealthAddress”stealthAddress:
`0x${string}`
ephemeralPublicKey
Section titled “ephemeralPublicKey”ephemeralPublicKey:
`0x${string}`
privateKey
Section titled “privateKey”privateKey:
`0x${string}`
suiAddress
Section titled “suiAddress”suiAddress:
string
checkStealthAddress()
Section titled “checkStealthAddress()”checkStealthAddress(
stealthAddress,spendingPrivateKey,viewingPrivateKey):boolean
Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:2839
Check if a stealth address belongs to this recipient
Parameters
Section titled “Parameters”stealthAddress
Section titled “stealthAddress”Stealth address to check
spendingPrivateKey
Section titled “spendingPrivateKey”`0x${string}`
Recipient’s spending private key
viewingPrivateKey
Section titled “viewingPrivateKey”`0x${string}`
Recipient’s viewing private key
Returns
Section titled “Returns”boolean
true if the address belongs to this recipient
isValidAddress()
Section titled “isValidAddress()”isValidAddress(
address):boolean
Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:2846
Validate a Sui address format
Parameters
Section titled “Parameters”address
Section titled “address”string
Address to validate
Returns
Section titled “Returns”boolean
true if valid format