Error in user YAML: (<unknown>): did not find expected key while parsing a block mapping at line 1 column 1
---
name: trustless-work
description: Integrate Trustless Work Escrow-as-a-Service (EaaS) for stablecoin escrow on Stellar. Use when building escrow flows, marketplace payments, milestone-based funding, freelance platforms, grant disbursements, or implementing non-custodial payment systems with USDC.
argument-hint: [action] [escrow-type]
allowed-tools: Read, WebFetch, mcp__plugin_context7_context7__resolve-library-id, mcp__plugin_context7_context7__query-docs
---
Build non-custodial escrow flows with milestones, approvals, and disputes on Stellar (Soroban).
What is Trustless Work?
- Escrow-as-a-Service (EaaS) for stablecoin escrow (primarily USDC on Stellar)
- Non-custodial smart contracts with programmable release logic
- Role-based permissions and milestone tracking
- REST API and React SDK available
Key Resources:
- 📚 API Documentation: https://dev.api.trustlesswork.com/docs
- 🛠️ Backoffice dApp: https://dapp.trustlesswork.com
- 🎮 Demo dApp: https://demo.trustlesswork.com
- 👁️ Escrow Viewer: https://viewer.trustlesswork.com
- 💻 GitHub: https://github.com/Trustless-Work
- 🌐 Website: https://trustlesswork.com
- Single-Release: Multiple milestones, one payout (best for simple jobs, deposits)
- Multi-Release: Multiple milestones, multiple payouts (best for grants, staged projects)
See escrow-types.md for detailed comparison.
Every escrow assigns these roles to specific addresses:
- Service Provider: Delivers work, marks milestones complete
- Approver: Validates milestone completion
- Release Signer: Executes fund releases
- Dispute Resolver: Arbitrates conflicts, can re-route funds
- Receiver: Final destination of funds
- Platform Address: Platform itself, collects fees, configures escrow
See roles-reference.md for full permissions matrix.
- Initiation → Define schema, roles, amounts, milestones
- Funding → Lock assets via Stellar trustline
- Milestone Updates → Service provider marks progress
- Approval → Approver signs off on milestones
- Release → Release signer triggers transfer
- (Optional) Dispute Resolution → Resolver steps in if needed
See lifecycle-guide.md for detailed phase breakdown.
When to use Trustless Work:
- Building a freelance/gig marketplace with milestone payments
- Implementing escrow for e-commerce or service platforms
- Creating grant platforms with staged funding
- Security deposits for rentals/bookings
- Crowdfunding with conditional payouts
- B2B tools using USDC for global settlement
Base URLs:
- Testnet: https://dev.api.trustlesswork.com
- Mainnet: https://api.trustlesswork.com
Key endpoints:
POST /escrow/single-release- Create single-release escrowPOST /escrow/multi-release- Create multi-release escrowPOST /escrow/{escrowId}/fund- Fund an escrowPOST /escrow/{escrowId}/milestone/{milestoneId}/update- Update milestonePOST /escrow/{escrowId}/approve- Approve milestonesPOST /escrow/{escrowId}/release- Release fundsGET /escrow/{escrowId}- Get escrow details
See api-reference.md for complete endpoint documentation.
npm install @trustless-work/react-sdkKey hooks:
useCreateEscrow()- Create new escrowuseFundEscrow()- Fund an escrowuseUpdateMilestone()- Update milestone statususeApproveEscrow()- Approve milestonesuseReleaseEscrow()- Release funds
Pre-built UI components for common escrow flows.
const escrow = {
engagementId: "order-123",
title: "Website Development",
description: "Build marketing website",
roles: {
approver: "G...CLIENT",
serviceProvider: "G...FREELANCER",
releaseSigner: "G...PLATFORM",
platformAddress: "G...PLATFORM",
disputeResolver: "G...RESOLVER",
receiver: "G...FREELANCER"
},
amount: 1000,
platformFee: 0.5, // 0.5% platform fee
milestones: [
{ description: "Homepage design", status: "Pending", approved: false },
{ description: "Full website deployment", status: "Pending", approved: false }
],
trustline: {
address: "GBBD47IF6LWK7P7MDEVSCWR7DPUWV3NY3DTQEVFL4NAT4AQH3ZLLFLA5" // USDC
}
};const escrow = {
engagementId: "grant-456",
title: "Research Grant",
description: "Funding in two phases",
roles: {
approver: "G...FUNDER",
serviceProvider: "G...RESEARCHER",
releaseSigner: "G...PLATFORM",
platformAddress: "G...PLATFORM",
disputeResolver: "G...RESOLVER"
},
platformFee: 0.5,
milestones: [
{
description: "Interim report",
amount: 500,
status: "Pending",
flags: { approved: false, released: false, disputed: false, resolved: false },
receiver: "G...RESEARCHER"
},
{
description: "Final report",
amount: 500,
status: "Pending",
flags: { approved: false, released: false, disputed: false, resolved: false },
receiver: "G...RESEARCHER"
}
],
trustline: {
address: "GBBD47IF6LWK7P7MDEVSCWR7DPUWV3NY3DTQEVFL4NAT4AQH3ZLLFLA5"
}
};See examples.md for more complete code examples.
- All participants must have the trustline enabled for the asset (e.g., USDC)
- USDC on Stellar:
GBBD47IF6LWK7P7MDEVSCWR7DPUWV3NY3DTQEVFL4NAT4AQH3ZLLFLA5 - Without trustline, transactions will fail
- Trustless Work Protocol Fee: 0.3% (automatic)
- Platform Fee: Configurable percentage (set by you)
- Total deduction: Protocol fee + Platform fee
- Recommended: Freighter (non-custodial)
- Supported: Any Stellar wallet with trustline support
- Not supported: Some custodial exchanges (e.g., Binance) can't send to contract addresses
- Always test on Testnet first
- Use Testnet USDC for testing
- Testnet API: https://dev.api.trustlesswork.com
- Get testnet tokens from Stellar testnet faucet
When user requests help with Trustless Work:
- Understand the use case: What type of escrow flow do they need?
- Choose escrow type: Single-Release or Multi-Release?
- Define roles: Which addresses will have which permissions?
- Design milestones: What needs to be completed? How many stages?
- Select trustline: USDC or another Stellar asset?
- Set platform fee: What percentage should the platform earn?
- Provide code examples: Use the API or SDK based on their stack
- Guide through lifecycle: Explain what happens at each phase
- Reference supporting docs: Point to specific guides as needed
- api-reference.md - Complete API documentation
- escrow-types.md - Single vs Multi-Release comparison
- lifecycle-guide.md - Detailed lifecycle phases
- roles-reference.md - Role permissions and examples
- examples.md - Code examples for common scenarios
- stellar-guide.md - Stellar network integration details
For questions or feature requests:
- GitHub Issues: https://github.com/Trustless-Work
- Documentation: Read the full PDF at project root
- API Reference: https://dev.api.trustlesswork.com/docs