Contracts let players trade without trusting each other: what each side puts up waits in escrow at a station until the contract closes.
Trade contracts
- A trade contract swaps goods for goods at one station. Any commodity or item can be a price.
POST /v1/contractsoffers goods from one of the poster's stations for others, with adeadline_tickand, optionally, the one player it is for (for_player_id) or only the poster's allies (for_allies). The offer leaves the station's hold into escrow.POST /v1/contracts/{id}/accept, with aship_idat the station's body, pays the asked goods from the ship's hold and takes the offer aboard. The station needs a dock that fits the ship.POST /v1/contracts/{id}/withdrawtakes back an open contract. The escrow returns to the station.- An open contract expires at its deadline, and the escrow returns to the station.
- Posting is free. A player cannot accept their own contract (
own_contract).
The board
GET /v1/contractslists open contracts, filtered bystation_id,system_idandcommodity. Once accepted, a contract shows only to its poster and taker.?mine=truelists the player's own, posted or accepted, in every state.- A contract for one player shows only to that player and its poster. A contract for allies shows only to whoever is allied with the poster at the time.
contract.posted,contract.accepted,contract.expiredandcontract.withdrawngo to the poster and to the taker or named player.- Any contract can carry a public key from the poster's keyring (
public_key). It goes into the taker's keyring when they accept. See Keys.
Courier contracts
- A courier contract pays someone to carry cargo between two of the poster's stations by a deadline.
POST /v1/contracts/courierputs thecargoandpayinto escrow at the pickup station, and names thedelivery_station_id, thecollateraland thedeadline_tick.- Accepting, with a ship at the pickup station's dock, puts the collateral into escrow and the cargo aboard as the ship's
consignment. A consignment takes hold space but cannot be unloaded or used. POST /v1/contracts/{id}/deliver, with the carrying ship at the delivery station's dock, hands the cargo over. The ship receives the pay, and its collateral back if on time.- At the deadline an undelivered contract turns
late, and the collateral goes to the delivery station. Delivering late still earns the pay (contract.delivered,contract.late). - A courier job nobody accepts expires at its deadline, and its cargo and pay return.
- On the board, a courier job shows
jumpsandfuelfor the cheapest route over the viewer's own map, or null when that map does not connect the stations.
Infonet leases
- A lease opens the Infonet segment one of the poster's relays is in to another side for a time, in exchange for goods. A firewall relay opens every segment it borders.
POST /v1/contracts/leasenames the station, the goodsasked, thelease_ticks, therelay(ship:<id>orstation:<id>), acapand adeadline_tickto accept by. A relay not of the poster's side is refused (not_a_relay).- Accepting, with a ship docked at the station, pays the asked goods into the station. The lease covers the taker's whole side until
ends_tick. - While it runs, the relays of the segment the named relay is in at the time are part of the taker's Infonet. If the relay is gone or changes hands, the lease opens nothing.
- Packets still enter from the taker's own command posts. The leased segment's doors are its firewall relays if it has any, which check the taker's packets by their inbound rules, or any of its relays if it has none.
- The taker's packets share the poster's bandwidth, up to
cappackets a minute at each relay. - The poster sees the headers of the taker's packets that cross its relays, never their contents:
GET /v1/infonet/forwarded.
Bounties
- A bounty pays someone to hurt a player.
POST /v1/contracts/bountyputs therewardinto escrow at a station, and names thetarget_player_idand adeadline_tick. A combat record of the poster's can go with it asevidence_record_id.- Any one ship of a player not on the target's side accepts it, anywhere, with no dock.
- When the taker's side disables a ship or station of the target's side, the hull excepted, before the deadline, the bounty is
delivered. The reward waits as a payout at the poster's station, collected withPOST /v1/payouts/collect. - An unfulfilled bounty expires at its deadline, or when the poster's station is wrecked, and the reward returns.
- The board shows
has_evidence. The record itself shows only to the poster and the taker.