Escrow System

Trustless payments for compute

Every payment on LinqProtocol flows through on-chain escrow contracts. Providers get paid when they deliver. Requestors get refunds for unused time. No trust required.

The Challenge

The trust problem in compute

When you pay for cloud compute, you trust the provider to:

  • Actually run your workload
  • Not overcharge you
  • Refund you if they fail

When you're a provider, you trust the customer to:

  • Actually pay for resources consumed
  • Not dispute valid charges

Traditional cloud solves this with legal contracts and reputations. But what about decentralized compute where providers are anonymous?

LinqProtocol solves this with on-chain escrows.

How It Works

On-chain guarantees for both parties

1
Requestor creates escrow - Specifies resources needed, duration, and provider
2
Funds locked - LNQ tokens are locked in the escrow contract
3
Provider starts job - Deployment begins, escrow status updates
4
Work performed - Provider runs the workload
5
Earnings accrue - Provider can withdraw earned funds over time
6
Escrow finalizes - When complete, remaining funds return to requestor

The escrow contract is the source of truth. Both parties can verify: how much was deposited, when work started, how much has been earned, and how much remains.

No "trust me" handshakes. Everything on-chain.

Features

Smart contract features

EIP-712 Signatures

Offers are signed using the EIP-712 standard, providing human-readable signing prompts and preventing replay attacks.

Budget Control

Fund escrows upfront and track remaining balance in real time. Top up when you need more runway.

Partial Withdrawals

Providers can withdraw earned funds at any time without waiting for the full escrow duration.

Automatic Refunds

When an escrow finalizes, unused funds automatically return to the requestor's wallet.

Permissionless Finalization

Anyone can call finalize on an expired escrow. No admin keys required.

For Developers

What this means for developers

No Overpayment

You fund for the expected duration. If you stop early, unused funds are returned.

No Trust Required

You don't need to trust an anonymous provider. The smart contract enforces payment only for work delivered.

Budget Visibility

Track exactly how much has been consumed, how much remains, and when funds will run out.

On-Chain Transparency

Escrow activity is auditable on-chain for clear accountability.

How to Fund

1
Connect wallet via WalletConnect
2
Select deployment duration
3
Approve and fund the escrow
4
Funds are held until work is complete or escrow expires
For Providers

What this means for providers

Guaranteed Payment

Once funds are locked, they can't be withdrawn by the requestor without your consent (until finalization).

Continuous Earnings

Withdraw your earnings at any point during the escrow - don't wait until completion.

On-Chain Identity

Your provider address is associated with all your escrows, building an on-chain reputation.

No Chargebacks

Unlike credit card payments, on-chain escrows can't be reversed after work is delivered.

Technical

Under the hood

Escrow.sol

Key Functions

createEscrow(offer, signature)

Creates and funds a new escrow from a signed offer

fund(escrowId, amount)

Adds more funds to an existing escrow

startJob(escrowId)

Provider signals work has begun

withdraw(escrowId, amount)

Provider withdraws earned funds

finalize(escrowId)

Closes the escrow and returns remaining funds

Events

EscrowCreatedEscrowFundedJobStartedFundsWithdrawnEscrowFinalized

Security

  • • Open source and verifiable
  • • No admin keys for critical operations
Notes

Things to know

Escrow Duration

Once funded, an escrow runs for its specified duration. You can remove the deployment, but the escrow and compute lease remain active until expiration.

Minimum Funding

There may be minimum funding requirements based on the resource tier selected.

Gas Fees

Creating and funding escrows requires gas fees. Keep a small balance in your wallet.

Ready to deploy with on-chain guarantees?