From zero to a paid tool on the MCP server, in an hour.
Seven commands. The <a href="/providers/execute-reference.mjs">reference /execute server</a> already does everything the <a href="https://api.naxytra.com/v1/provider-network/contract">contract</a> asks (bearer check, health, self-test, idempotency per quote, the deliverable shape, 429 when busy); you replace one function with your own tool. You set your own price per capability with offers ({ tool_name | task_ref, title, price_usd }, $0.001–$100.00 in $0.001 steps): a credits call is debited its credits equivalent (a $0.001 call costs 1 credit), a buyer's x402 challenge advertises your price in USDC (one x402 payment is at least $0.005, which covers the per-payment settlement fee), and your revenue share is always computed on your own price. Provider tools are paid on Base mainnet only (never with testnet USDC). Every active provider's offers are listed under provider_offers in the runtime catalog (GET https://api.naxytra.com/v1/catalog).
1. Run the reference /execute server
Download provider-execute-reference.mjs, read it (it is short on purpose), and run it. The only tool it ships, echo.upper, is the one you will replace: edit the TOOLS map, one async function per tool, keyed by the tool_name you will register.
# 1. get the reference server (Node 20+, no dependencies) and run it
curl -s -o provider-execute-reference.mjs https://www.naxytra.com/providers/execute-reference.mjs
PROVIDER_AUTH_TOKEN=$(openssl rand -hex 24) # the bearer the runtime will present to you; keep it
echo "$PROVIDER_AUTH_TOKEN" > .provider-auth-token
PROVIDER_AUTH_TOKEN="$PROVIDER_AUTH_TOKEN" PORT=8080 node provider-execute-reference.mjs
# -> provider /execute listening on :8080 — tools: echo.upper
- Keep
PROVIDER_AUTH_TOKENsecret: the runtime presents it asAuthorization: Beareron every job, so nobody else can make your server work. - A tool throws an error with
status = 400for bad input (not charged, not retried); anything else is a 500 the runtime treats as ambiguous and does not retry.
2. Expose it over public HTTPS
The runtime POSTs jobs to your URL. It must be public HTTPS; private, loopback and link-local addresses are refused, URLs with credentials are refused, and redirects are never followed. A free web service on any PaaS is enough to start; the runtime rides out a cold start (up to 45 s) before giving up.
# 2. put it behind public HTTPS (any host works; a free Render web service is enough)
# the runtime refuses private, loopback and link-local hosts and never follows redirects
curl -s https://YOUR-HOST.example.com/health
# -> {"ok":true,"tools":["echo.upper"]}
3. Register with your price
Open registration: no API key. Activation requires a payout_address on your record; add it at registration or re-register with your owner_secret. The offers entry is your price for the tool ($0.001–$100.00 in $0.001 steps); without one the platform price applies. The response returns your provider_id and a one-time owner_secret.
# 3. register: your endpoint, the tool you serve, your price, where to pay you
cat > register.json <<'EOF'
{
"label": "YOUR_SERVICE_NAME",
"endpoint_url": "https://YOUR-HOST.example.com/execute",
"task_refs": ["adapter.mcp.invoke"],
"tool_names": ["echo.upper"],
"offers": [{ "tool_name": "echo.upper", "title": "Upper-case a string", "description": "Returns the text upper-cased and its length.", "price_usd": "0.02" }],
"revenue_share_bps": 8000,
"payout_address": "0xYOUR_BASE_ADDRESS",
"auth_token": "PASTE_THE_PROVIDER_AUTH_TOKEN"
}
EOF
curl -s -X POST https://api.naxytra.com/v1/provider-network/register -H "content-type: application/json" -d @register.json
# -> {"ok":true,"provider_id":"provider_…","status":"pending","owner_secret":"prvown_… (shown ONCE — save it)"}
- Revenue share: up to up to 80% of each settled call, accrued exactly, paid out weekly in USDC on Base once you reach $1.00.
- Re-registering the same provider_id needs the owner_secret; changing the endpoint or the capabilities reverts an active provider to pending for re-approval; changing a price does not.
4. Pass the self-test
The runtime sends a synthetic, unpaid job to your endpoint exactly the way a paid job travels (same bearer, same policy) and records whether you answered the contract. The reference server answers it out of the box. The outcome is on your public record and in the operator's daily report.
# 4. prove the endpoint answers the contract (the runtime probes it exactly like a paid job)
curl -s -X POST https://api.naxytra.com/v1/provider-network/providers/YOUR_PROVIDER_ID/self-test \
-H "x-provider-owner-secret: YOUR_OWNER_SECRET"
# -> {"ok":true,"self_test":{"ok":true,"reason":"delivered","latency_ms":…},"next":"…activation is the operator's call…"}
5. Get activated
Registration lands in status pending. The operator reviews the endpoint, the capabilities and the acceptable-use fit, then activates. Nothing routes to you before that, and nothing is charged for you.
# 5. activation: the operator sees your registration and self-test in the daily report;
# to speed it up, email naxytra@gmail.com with your provider_id. Only active providers get traffic.
curl -s https://api.naxytra.com/v1/provider-network/providers/YOUR_PROVIDER_ID # status: pending -> active
6. See your tool on the MCP server
An offer with a tool_name is also listed by the naxytra MCP server (tools/list, after the built-in tools) and a tools/call for it is proxied to the runtime at your price — MCP clients discover and pay for your tool with no integration on your side. A 2xx that carries result.output, output_payload or output is a delivery; a 2xx without one is not charged, earns nothing and is not retried elsewhere.
# 6. once active, your tool is on the MCP server at your price — any MCP client can discover and pay for it
curl -s -X POST https://mcp.naxytra.com/mcp -H "content-type: application/json" -H "accept: application/json, text/event-stream" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}' | grep -o '"name":"echo.upper"'
# unpaid call -> payment-required at $0.02; paid (x402 or a spend key) -> your output, settled on Base
7. Read your earnings
Weekly payout sweep (Mondays, UTC): every active provider with at least $1.00 available is paid in full to its payout_address; the operator can also pay out any time. Idempotent, double-pay-safe, public on Basescan. Rotate your owner_secret any time with POST /v1/provider-network/providers/<provider_id>/rotate-secret (authenticate with the current secret; the new one is shown once).
# 7. your earnings, any time (owner_secret, never an operator token)
curl -s https://api.naxytra.com/v1/provider-network/providers/YOUR_PROVIDER_ID/earnings -H "x-provider-owner-secret: YOUR_OWNER_SECRET"
# -> payout_state { accrued, paid_out, pending, available, owed }, settlements, payouts