Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.faremeter.xyz/llms.txt

Use this file to discover all available pages before exploring further.

A marketplace is what you get when you put many publishers’ x402-paid APIs behind one proxy with shared discovery, pricing, and settlement. Faremeter ships the OSS building blocks; an operator runs them as a multi-tenant service. If you only want to charge for one API, you do not need a marketplace — drop @faremeter/middleware into your existing server and you are done. Reach for the marketplace stack when you have multiple publishers, shared infrastructure, or a directory of paid APIs that consumers want to discover programmatically.

Two ways to participate

As a publisher

Register an API on a marketplace, set per-endpoint pricing, and let the proxy collect payment for you.

As a client

Discover paid APIs in a registry and call them with @faremeter/rides. No accounts, no API keys.

OSS components

The marketplace stack is published at github.com/faremeter/marketplace and combines:
ComponentWhat it does
Control planeManages tenants, endpoints, pricing, and wallets. Pushes config to API nodes.
API nodesFront clients with nginx, validate payment via the facilitator, and proxy to publisher backends.
Discovery serviceSearchable registry of published APIs. Serves OpenAPI specs and pricing to consumers.
Gateway SDK@faremeter/gateway-nginx generates nginx + Lua config for gateway-mode tenants.
API nodes use the gateway SDK to enforce payment at the edge before requests reach a publisher’s backend. Settlement runs through a standard Faremeter facilitator, so the same payment schemes you use in the rest of Faremeter work here.

Hosted vs self-hosted

A marketplace is meant to be operated. You have two options:
  • Use a hosted marketplace. Corbits runs a hosted instance at api.corbits.dev with a dashboard for publishers and a public Discovery API for consumers. Pricing, dashboards, and operations are managed for you. See the Corbits documentation for sign-up and product details.
  • Run your own. Deploy the marketplace repo on your own infrastructure. See self-hosting for what that involves.
Either way, the client side is identical: a Faremeter wallet plus @faremeter/rides is enough to discover and pay for any marketplace API.

How it relates to other Faremeter pieces

  • @faremeter/middleware is what publishers reach for when they run their own server and want to charge for it directly. The marketplace is the layer above that — it lets a third-party operator run the proxy on the publisher’s behalf.
  • @faremeter/rides is the only client-side dependency for paying marketplace APIs. The Discovery API tells you where the API lives and what it costs; rides handles the payment.
  • Facilitators still settle every paid request. A marketplace operator typically runs a facilitator, but a publisher can supply their own.
  • Flex is a payment scheme. Marketplaces can offer Flex-priced endpoints when the publisher opts in.

Where to next

Publisher path

What it takes to put your API on a marketplace.

Client path

Discover and call paid APIs from any wallet.

Gateway SDK

@faremeter/gateway-nginx: how API nodes enforce payment.

Self-hosting

Deploy the marketplace stack on your own infrastructure.