githubEdit

For developers: mapping concepts to the SDK

This page is the bridge from Architecture and main components to the canonical PoD SDK documentation on GitHubarrow-up-right. It repeats a few facts on purpose so engineers can verify mental models quickly.

For a guided first implementation, read Tutorials: building Privacy on Demand (PoD) dApps to pick the integration model, then follow Tutorial: private Adder on Sepolia for a primitive-only Solidity + TypeScript walkthrough (Sepolia presets).

Official reading order (SDK)

The upstream docs recommend:

Then deep dives:

Component → source file map

Concept (this book)
Where it lives in the SDK docs / repo

Inbox

IInbox.solarrow-up-right and cross-domain flow in the domain modelarrow-up-right diagram.

Callback guard

PodLib

PodLib.solarrow-up-right and width-specific libraries (PodLib64, PodLib128, PodLib256).

Custom COTI calls

Implementation checklist (condensed)

Derived from the SDK’s Writing privacy contractsarrow-up-right and Async executionarrow-up-right:

  1. Classify data — public metadata vs it* inputs vs ct* outputs vs internal gt* (COTI-only).

  2. Pick integration modePodLib helpers vs custom MpcAbiCodec + COTI contract.

  3. Model async state — persist requestId, track pending/completed/failed.

  4. Harden callbacksonlyInbox, correct abi.decode tuple, validate peer context when applicable.

  5. Configure routing safely — gated configure / configureCoti / inbox updates.

  6. Budget fees — understand msg.value and callbackFeeLocalWei; use Inbox fee views where available (Fees docarrow-up-right).

  7. Test failure paths — spoofed callback must revert, error callbacks must mark failures, decrypt integration must match widths.

Relationship to native COTI “build” documentation

If you build directly on COTI V2 with precompiles and private types, start from Build on COTI. PoD adds the Inbox-mediated cross-chain angle; many cryptographic ideas rhyme, but deployment and UX differ.

Package install

See Getting startedarrow-up-right for Solidity imports and the contract MyApp is PodLib, PodUserSepolia pattern.

Last updated

Was this helpful?