Skip to content

Docs

Metric and Handshake

Two ways a Deal decides. The 72 h rule, silence means release, and kill fee math.

Two modes

Every Deal picks one mode at creation. It cannot change later.

MetricHandshake
Who decidesThe TermThe payer, within limits
Use forResults the chain can readWork the chain cannot measure
Tranches1 to 8, each with a TermExactly 1, no Term
Releasesettle when the Term is trueacceptDelivery, or settle after 72 h of silence
Refundsettle after the deadline with the Term falsereject minus kill fee, or settle after the deadline if never delivered
Kill feeNot available0 to 30 %

Metric mode

The Term decides. Nobody has to approve anything. When the Term reads true, anyone can call settle(trancheIndex) and the payee is paid, minus the 1 % fee. When the deadline passes and the Term still reads false, anyone can call settle and the payer is refunded.

Use Metric mode for KOL deals tied to market cap, market-making deals tied to volume or liquidity, listing deals, and vesting.

Handshake mode

Some work cannot be read by a contract: a website, a logo, an audit report, a thread. For these, the payee declares the work done and the payer reviews it.

  1. The payee accepts the deal.
  2. The payee calls markDelivered before the deadline. State becomes Delivered and the review window starts.
  3. The payer has 72 h to answer:
    • acceptDelivery releases the full amount to the payee, minus the 1 % fee.
    • reject pays the kill fee to the payee and refunds the rest to the payer.
  4. If the payer does nothing for 72 h, anyone can call settle and the full amount is released to the payee.

The payer function is named acceptDelivery to keep it distinct from the payee's accept.

The 72 h rule

The review window is fixed at 72 h for every Handshake deal. It starts at the block in which markDelivered is mined. reject works only while the window is open. From the first second after it closes, settle releases.

Silence means release

A payer who stops answering cannot hold the earnest hostage. Silence is treated as acceptance. This protects the payee from the most common failure in paid-after deals.

Never delivered

If the payee never calls markDelivered and the deadline passes, anyone can call settle. The payer is refunded in full and any payee bond goes to the payer.

Kill fee

The kill fee is the share of the earnest the payee keeps when the payer rejects a delivery. It is set at creation, from 0 to 30 %. The presets use 20 %.

It pays the payee for time spent on work the payer did not want, and it puts a price on rejection so a payer cannot reject good work for free.

The kill fee is a release, so the 1 % protocol fee applies to it. The refunded part pays nothing.

Worked example

A Handshake deal of 100 HYPE with a 20 % kill fee. The payee delivers. The payer calls reject inside the window.

LineAmount
Earnest100 HYPE
Kill fee, 20 %20 HYPE
Protocol fee, 1 % of 20 HYPE0.2 HYPE to the Treasury
Paid to the payee19.8 HYPE
Refunded to the payer80 HYPE

If the payer had called acceptDelivery instead, the payee would receive 99 HYPE and the Treasury 1 HYPE.

After a rejection the deal ends in state Refunded. A posted payee bond is returned to the payee, because the payee did deliver.