Skip to content

CreateIntentOptions

SIP Protocol API Reference v0.7.0


SIP Protocol API Reference / CreateIntentOptions

Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:839

Options for creating a shielded intent

Additional configuration passed to createShieldedIntent that affects proof generation and sender identification.

optional senderAddress: string

Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:850

Wallet address of the sender

Used for:

  • Generating ownership proofs (proving control of input funds)
  • Creating sender commitments
  • Enabling refunds if transaction fails

Optional but recommended for production use.


optional proofProvider: ProofProvider

Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:876

Proof provider for automatic ZK proof generation

If provided and privacy level is SHIELDED or COMPLIANT, proofs will be generated automatically during intent creation. If not provided, proofs must be attached later using attachProofs.

Available providers:

  • MockProofProvider: For testing
  • NoirProofProvider: For production (Node.js)
  • BrowserNoirProvider: For browsers
import { NoirProofProvider } from '@sip-protocol/sdk/proofs/noir'
const provider = new NoirProofProvider()
await provider.initialize()
const intent = await createShieldedIntent(params, {
senderAddress: wallet.address,
proofProvider: provider,
})

optional ownershipSignature: Uint8Array<ArrayBufferLike>

Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:885

Signature proving ownership of the sender’s address

Required for production proof generation. This signature proves the sender controls the address that holds the input funds.

Should be a 64-byte ECDSA signature over the address.


optional senderSecret: Uint8Array<ArrayBufferLike>

Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:895

Sender’s secret key for nullifier derivation

Required for production proof generation. Used to derive:

  • Public key for ECDSA verification in proofs
  • Nullifier to prevent double-spending

Should be a 32-byte secret. Keep this secure!


optional authorizationSignature: Uint8Array<ArrayBufferLike>

Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:904

Signature authorizing this specific intent

Required for production proof generation. This signature proves the sender authorized this intent (signs the intent hash).

Should be a 64-byte ECDSA signature over the intent hash.


optional allowPlaceholders: boolean

Defined in: @sip-protocol/sdk/dist/index-BYZbDjal.d.ts:914

Allow placeholder signatures for development/testing

When true, allows proof generation with empty placeholder signatures. WARNING: Never use this in production! Proofs with placeholders are not cryptographically valid.

false