Skip to main content
Start with the Rust SDK quickstart if you want the smallest app-shaped project. Then move to the private matchmaking tutorial for the full Rust service boundary, and use the focused tutorials to isolate the privacy patterns you will reuse in your own app: reveal boundaries and hidden state.

Start here

Rust SDK quickstart

Build a private approval tally that opens only an aggregate yes-vote count, then maps it into a normal Rust launch decision.

Build a private matchmaking service

Compute matches from private feature and preference vectors without exposing raw vectors, scores, rankings, or rejection paths. This is the best next step if you want to see the full Rust service boundary around a Stoffel computation.

Deepen the mental model

Private lottery

Reveal the winner without exposing eligibility bits, ticket values, losing order, or comparison trace.

N-party Battleship

Update hidden state while revealing only the shot result each recipient is allowed to see.

Privacy boundary

Decide what is private, public, opened, routed, or never revealed before adapting the tutorial pattern.

Run the source

The runnable projects live in the Stoffel tutorials repository. From the repository root:
Then run the quickstart or matching tutorial directly:
Each tutorial README includes its exact cargo run, stoffel check, stoffel build, and stoffel run commands.

What to copy into your app

Copy the boundary pattern, not the sample domain:
  1. Keep public product data in ordinary application code.
  2. Give each logical client an explicit client slot and private payload type.
  3. Put only the private computation boundary in StoffelLang.
  4. Attach client inputs with one with_client_input(slot, values) call per logical client slot.
  5. Validate the client input shape before running local MPC.
  6. Open only the authorized output your product needs.
  7. Map the opened result back into a typed Rust domain object.

Next steps

Rust SDK quickstart

Build a private matchmaking service

Embed Stoffel in a Rust service

Run a local Docker MPC network

Browse StoffelLang examples