Skip to main content
A route is the fundamental building block of the Agent Gateway. Each route combines three things: a URL path that agents call, a price in USD that is charged per request, and a target upstream URL that the gateway proxies to after payment is verified. Routes are scoped to your organization — agents reach them at https://gateway.meterlane.app/gateway/{orgSlug}/{routePath}. You can create and manage routes either from the Meterlane dashboard or programmatically through the management API.

What a route contains

Creating routes from the dashboard

The dashboard at meterlane.app/dashboard is the easiest way to create your first route.
1

Open Routes

Navigate to Dashboard → Routes and click New Route.
2

Configure the route

Fill in the path, price, and your upstream URL. Choose the network that matches your upstream environment — use Base Sepolia for staging and Base mainnet for production.
3

Save and test

Click Save. Your route is immediately live. Copy the gateway URL shown in the route detail panel and test it with curl to confirm the 402 challenge appears.

Management API

Use the management API to create and manage routes programmatically — useful for CI/CD pipelines, infrastructure-as-code, or dynamic route generation. All management API requests require your organization’s API key in the Authorization header.

Create a route

A successful response returns 201 with the full route object:

List routes

Returns an array of all routes under your organization, ordered by creation date (newest first).

Update a route

Use PATCH /api/routes/{id} to change any field on an existing route. You only need to include the fields you want to update:

Disable a route

Set "active": false via PATCH, or DELETE /api/routes/{id} to permanently deactivate it and remove it from Bazaar discovery. Deactivated routes return 404 to agents.

Route pricing

Every route uses a fixed per-request price denominated in USD and settled in USDC. Set priceUSD to any value greater than 0. The gateway converts your USD price to the equivalent USDC token units at the time of payment configuration — there is no dynamic FX conversion at request time.
Start with a low price (e.g. 0.001 — one tenth of a cent) while testing. You can update the price at any time via PATCH without disrupting existing agent integrations.

SSE streaming routes

If your upstream returns a Server-Sent Events stream (for example, a streaming LLM response), set "streaming": true on the route. The gateway will pipe bytes directly to the agent without buffering the full response body first.
Streaming routes settle payment before opening the upstream connection. The agent pays the full route price upfront, then receives the stream.

Discoverable routes (Bazaar)

Setting "discoverable": true on a route lists it in the x402.org Bazaar, a public registry where AI agents can discover paid HTTP APIs. Include a clear description and optionally a bazaarCategory to improve discoverability.
Set "discoverable": false or call DELETE /api/routes/{id} to remove a listing from Bazaar.

Sandbox demo route

The public route at https://gateway.meterlane.app/gateway/demo/demo is a read-only sandbox maintained by Meterlane. It always responds with a 402 challenge on an unpaid request and accepts test payments on Base Sepolia. Use it to validate your agent’s x402 client integration before creating your own routes.
Do not use the demo org slug for production traffic. It is a shared sandbox and does not credit any real wallet.