Search docs

Find a documentation page

Book a lease

The end-to-end web flow: browse validators, pick exclusive or shared, pay with Solana Pay, then manage credentials, extensions, and ratings.

This page walks through booking a lease entirely in the 2QUIC Marketplace web app, from browsing validators to rating one after your lease completes. For the programmatic flow (REST calls, SDKs, JWT minting), see the integration guide.

Before you start

  • A 2QUIC account. Booking in the web app runs under your signed-in session, no API token needed.
  • A Solana wallet holding enough SOL for the lease total. Any wallet that supports Solana Pay transaction requests works.

Browse validators

Open /validators. Each listing card shows:

FieldWhat it tells you
Price / epochThe exclusive price, plus the shared price underneath when offered
Offering badge"Exclusive + Shared" when the validator opted into shared leases, "Exclusive only" otherwise
StakeCurrent activated stake, which is what buys your connections SWQoS priority
Uptime 30dRolling 30-day TEE uptime from the probe (one health check per minute)
Reputation0-100 score: 50% uptime, 30% sign latency, 20% trader ratings

Click View details for the full picture before committing:

  • Seats free right now for shared validators, shown as "x of N seats free" for the current epoch.
  • Latency p50: the probe-measured signing latency of the TEE.
  • Leader time / epoch: how many hours per epoch this validator spends as leader. More leader time means more slots where its stake directly fronts your transactions.
  • A 14-epoch calendar of upcoming epochs. Per-epoch availability is not wired into it yet, so it does not mark booked slots. The next available epoch surfaces as a hint on the booking form instead (see below).

When you have picked one, hit Book.

The booking form

The form lives at /book/{validatorId}.

Pick a lease type

The exclusive vs shared picker appears only when the validator offers shared leases. Otherwise the form notes the lease is exclusive: one tenant per epoch, the TEE and its full leader bandwidth are yours alone.

  • Exclusive: sole tenant of the TEE, full bandwidth, full JWT handshake quota (default 100/min).
  • Shared: the TEE is shared with other traders, priced separately and typically lower. The option shows how many seats are still free on your chosen window ("x of N seats free"). Your JWT handshake quota becomes the budget divided by the seat cap (minimum 1/min), and post-handshake leader bandwidth is split across all active tenants.

An option is greyed out, with the reason inline, when your chosen window cannot host it:

Greyed optionReason shownWhy
Exclusive"Window already booked"Any lease, exclusive or shared, overlaps your window. Exclusive needs the range completely free
Shared"An exclusive lease blocks this window"An exclusive lease overlaps part of the window
Shared"All shared seats are taken in this window"Every seat is occupied on at least one epoch of the window

The form computes this from the validator's published availability and blocks submit so you never pay for a window that is already taken. The backend remains authoritative: a race still returns 409 lease-slot-taken or 409 shared-capacity-full, surfaced as a toast.

Picking shared shows a warning for a reason: other traders can lease the same TEE during your window, and their activity can affect your throughput. Choose exclusive if you need guaranteed, sole-tenant bandwidth.

Pick start epoch and duration

  • Starting epoch: an absolute Solana epoch number. The form syncs it to the validator's next available epoch when it loads, and a hint tells you whether the validator is free now or "Booked through epoch N-1, first free slot is N" with a reset button.
  • Duration: 1 to 30 epochs, with quick picks for 1, 5, 10, and 30. One epoch is 432,000 slots at ~0.4s each, roughly 2 days, so the summary shows the approximate calendar duration alongside the epoch count.

The cost summary on the right prices the booking at the selected mode's per-epoch price times the duration. Click Book lease to submit. Under the hood this is POST /v1/leases with {validator_id, epoch_start, epoch_count, mode}.

Pay with Solana Pay

On success the form swaps to a payment panel showing the SOL amount, a QR code, an Open in wallet deep link, and a copyable reference (the payment memo).

This is a Solana Pay transaction request, not a bare transfer link. When you scan the QR or open the link, your wallet fetches the exact server-built transaction:

  • two transfers in one atomic transaction: the validator's share straight to its payout wallet and the platform fee to the platform wallet, a 90/10 split at the default 10% fee
  • the memo that ties the payment to your lease

The fee rate and payout wallet were frozen onto your lease at booking, so later changes never re-price what you approved. Review the transaction in your wallet and sign it. One rule: do not pay from the validator's own payout wallet, the wallet will get an error building the transaction.

You have 15 minutes to pay. The booking holds the slot (or seat) in pending_payment for that window. If the payment never confirms, the lease flips to expired_unpaid, the slot frees up, and the payment endpoint refuses to build a transaction for that memo, so a late payment cannot go through.

Once your transaction reaches finality, the settlement worker verifies both transfer legs on-chain and activates the lease, typically within seconds. The page polls automatically and flips to "Payment confirmed". If you close the page mid-payment, nothing is lost: the pending lease on your dashboard keeps showing the payment instructions until it either settles or expires.

Lease lifecycle

StatusMeaning
pending_paymentBooked, slot or seat held, waiting for the on-chain payment. Expires after 15 minutes unpaid
activePayment confirmed at finality. You can reveal credentials and mint JWTs
completedThe last paid epoch has elapsed
expired_unpaidThe payment window lapsed. The slot was freed, nothing was charged
revokedThe validator or the platform revoked the lease. A prorated refund applies

There is no trader-initiated cancellation: once paid, a lease is committed.

After activation: reveal your credentials

From the trader dashboard, open your lease and go to its credentials page (/trader/leases/{id}/credentials). Visiting it performs the one-shot reveal (POST /v1/leases/{id}/credentials), which returns:

  • tee_endpoint_url: the validator's TEE endpoint your client connects to
  • api_token: the per-lease bearer token for all API calls from your bot, including JWT minting
  • tls_ca_cert: a CA certificate to pin

The cleartext api_token is shown exactly once. The server stores only a hash. Use the Copy as .env button, which emits MARKETPLACE_LEASE_ID, MARKETPLACE_TEE_URL, and MARKETPLACE_API_TOKEN, and stash it somewhere safe before leaving the page.

Returning to the page later shows "Credentials already revealed" (the API returns 404 credentials-already-shown). If you lose the token, rotate it with POST /v1/leases/{id}/api-keys: this mints a fresh token and revokes the old one immediately. What to do with the credentials next is covered in the integration guide.

Extend a lease in place

An active lease can be extended without rebooking. The Extend dialog on your dashboard (backed by POST /v1/leases/{id}/extend) bumps the lease's end epoch in place:

  • Same lease: same lease ID, same credentials, same API token. Your bot keeps running through the boundary.
  • Frozen price: extensions are charged at the per-epoch price you booked at, even if the validator has changed its price since.
  • 30-epoch total cap: the whole lease, original window plus extensions, cannot span more than 30 epochs. Past that, book a fresh lease.
  • New payment: each extension produces its own Solana Pay request, the same QR-and-wallet flow as the booking. Only one extension can be pending at a time, and an unpaid extension rolls back after the same 15-minute window. If you close the dialog before paying, a Pay extension button on the lease lets you resume.

Auto-renew

PATCH /v1/leases/{id}/auto-renew with {"enabled": true} toggles the lease's auto-renew flag. Be aware of what this does today: it records your renewal preference on the lease, nothing more. Payment is non-custodial, the marketplace holds no funds and cannot charge you, so no booking or payment happens automatically. Every renewal is still a payment you create and sign yourself, via the extend flow above or a fresh booking.

Rate the validator after completion

Once your lease completes you can leave one rating at /trader/leases/{id}/rate: 1 to 5 stars plus an optional comment up to 500 characters (POST /v1/leases/{id}/rating).

Rating is gated on real usage: the lease window must have elapsed and the lease must have recorded at least 10,000 TEE signatures (the default MARKETPLACE_RATING_MIN_SIGNS). Before that the API returns 422 rating-not-yet-eligible, and a second attempt returns 409 already-rated. Ratings feed 20% of the validator's reputation score, and the validator can post one public reply.

Revocation and refunds

A validator or platform admin can revoke an active lease (for example during an incident). When that happens:

  • The lease flips to revoked and JWT minting starts failing with 403 lease-not-active. Any already-issued JWT expires naturally within its TTL, at most 10 minutes.
  • You are refunded pro rata for the remaining epochs: total paid x remaining epochs / total epochs, with the current epoch counting as remaining. Refunds are paid out manually from the platform buffer, typically within 24 hours.

Next steps