Tip
Scoping this repo with an AI agent? Give it full context in one shot:
curl -sL https://raw.githubusercontent.com/NethermindEth/aztec-fpc/main/docs/public/llms.txt
This returns a structured project summary, source code map with line numbers, function index, error codes, and config reference. For the complete docs (~5k lines), replace llms.txt with llms-full.txt.
Users pay fees in the token they already hold. The operator covers the Fee Juice.
FPC is a smart contract on Aztec that pays transaction fees in Fee Juice on the user's behalf. Instead of acquiring Fee Juice themselves, users pay the FPC operator in any accepted token (USDC, ETH, app tokens) at a rate locked by a signed quote. One contract instance handles any number of tokens with no redeployment.
Read the docs | Testnet addresses | SDK reference
| Component | Role |
|---|---|
| FPC contract | Verifies operator-signed Schnorr quotes, transfers tokens from user to operator, pays Fee Juice to the protocol |
| Attestation service | Signs per-user fee quotes, serves wallet discovery at /.well-known/fpc.json |
| Top-up service | Watches FPC balance on L2, bridges Fee Juice from L1 when it drops below threshold |
| SDK | createPaymentMethod() for existing users, executeColdStart() for L1 onboarding |
import { FpcClient } from "@nethermindeth/aztec-fpc-sdk";
const fpcClient = new FpcClient({ fpcAddress, operator, node, attestationBaseUrl });
// User already has L2 tokens
const { fee } = await fpcClient.createPaymentMethod({
wallet, user: userAddress, tokenAddress, estimatedGas,
});
await contract.methods.transfer(recipient, amount).send({ fee });
// User just bridged from L1, no account, no Fee Juice
const result = await fpcClient.executeColdStart({
wallet, userAddress, tokenAddress, bridgeAddress, bridgeClaim,
});Two methods. That's the entire SDK surface.
Run the full stack locally in one command:
git clone --recurse-submodules https://github.com/NethermindEth/aztec-fpc.git
cd aztec-fpc && bun install
docker buildx bake
docker compose --profile full up wait --waitVerify:
curl http://localhost:3000/health # attestation
curl http://localhost:3001/ready # topup
curl http://localhost:3000/accepted-assets # registered tokensFor testnet deployment, manual bring-up, or SDK-only integration: Quick Start guide.
docs/README.md is the entry point. It routes you by role:
|
Start here
|
Full docs
|
aztec-fpc/
├── contracts/
│ ├── fpc/ ← FPCMultiAsset (Noir)
│ ├── faucet/ ← Test token dispenser
│ ├── token_bridge/ ← L1-L2 bridge
│ └── noop/ ← Profiling baseline
├── services/
│ ├── attestation/ ← Quote-signing REST service
│ └── topup/ ← Fee Juice bridge daemon
├── sdk/ ← TypeScript SDK
├── scripts/
│ ├── contract/ ← Deploy + smoke wrappers
│ ├── services/ ← Service bootstrap scripts
│ └── tests/ ← Integration and E2E suites
├── vendor/
│ └── aztec-standards/ ← Git submodule (token contract)
└── docs/ ← Documentation (start with README.md)
aztec compile --workspace --force # compile all Noir contracts
bun run test:contracts # Noir contract tests
bun run test:ts # service + SDK unit tests
bun run ci # full pipeline: format, lint, typecheck, build, testDocker integration tests (same flow as CI):
docker buildx bake
docker compose --profile full up wait --wait
docker compose --profile full down -v --remove-orphans- Operator key: single Schnorr keypair signs all quotes and receives all revenue. Use KMS/HSM in production. Compromise requires contract redeployment (no on-chain key rotation).
- L1 key: used only by the top-up service for bridging. Keep minimal ETH balance.
- Production mode:
runtime_profile=productionrejects plaintext secrets and requires auth on quote endpoints.
Full threat matrix and production checklist: Security Model.
Questions, bugs, or feedback:
- Email: aayush@nethermind.io
- GitHub: Open an issue or start a discussion
Built by Nethermind