createPrivateVoting()
SIP Protocol API Reference v0.7.0
SIP Protocol API Reference / createPrivateVoting
Function: createPrivateVoting()
Section titled “Function: createPrivateVoting()”createPrivateVoting():
PrivateVoting
Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:8588
Create a new PrivateVoting instance
Returns
Section titled “Returns”PrivateVoting instance
Example
Section titled “Example”import { createPrivateVoting } from '@sip-protocol/sdk'
const voting = createPrivateVoting()
const encryptedVote = voting.castVote({ proposalId: 'proposal-123', choice: 1, weight: 1000n, encryptionKey: '0xabc...',})