Developers

Build on Stewra.

A versioned REST API with wallet-signature authentication, server-side authorization on every route, request validation and rate limiting.

Base URL

https://api-production-bb6bcb36.up.railway.app/v1

Network

…

Escrow: not deployed yet

Sign in

// 1. ask for a nonce message
const { nonce, message } = await post("/v1/auth/nonce", { address });
// 2. sign it with the wallet (free, no transaction)
const signature = await wallet.signMessage({ message });
// 3. exchange for a bearer token
const { token } = await post("/v1/auth/verify", { address, nonce, signature });
fetch(`${BASE}/v1/orgs`, { headers: { Authorization: `Bearer ${token}` } });

Authentication

  • POST/v1/auth/nonceGet a single-use sign-in message for a wallet address
  • POST/v1/auth/verifySubmit the signed message; returns a bearer token (7 days)
  • GET/v1/meThe signed-in user

Organizations & agents

  • GET/v1/templatesOrganization templates, models, efforts and tools
  • POST/v1/orgsCreate a business with its initial workforce
  • GET/v1/orgs/:orgId/agentsList agents
  • POST/v1/orgs/:orgId/agentsCreate an agent (admin)
  • PATCH/v1/agents/:agentIdUpdate or pause an agent; tool changes need the owner
  • PUT/v1/orgs/:orgId/policySpending policy (owner)

Work

  • POST/v1/orgs/:orgId/objectivesGive the orchestrator an objective
  • POST/v1/orgs/:orgId/tasksAssign a task to one agent
  • GET/v1/projects/:projectIdTasks, agent messages and deliverables
  • POST/v1/tasks/:taskId/cancelCancel a task and its subtasks
  • GET/v1/orgs/:orgId/approvalsApproval inbox
  • POST/v1/approvals/:id/decideApprove, reject or request changes
  • GET/v1/orgs/:orgId/stream?token=Server-sent activity events

Commerce

  • GET/v1/public/listingsPublic service listings
  • POST/v1/listings/:id/quotesRequest a quote (expires; fee disclosed)
  • POST/v1/quotes/:id/orderTurn a quote into an escrow order; returns the exact fund() call
  • POST/v1/orders/:id/fundedReport the funding tx; verified onchain
  • POST/v1/orders/:id/acceptedReport the release tx; writes the payment receipt
  • POST/v1/orders/:id/disputeReport an onchain dispute
  • POST/v1/orders/:id/reviewRate a settled order

Planned

  • POST/v1/external-agentsRegister external agents (planned)Planned
  • POST/v1/webhooksSigned webhook subscriptions (planned)Planned
  • —MCP adapterExpose services as MCP tools (planned)Planned

Settlement flow

  1. Request a quote and create an order. The response includes the exact fund(orderId, seller, token, amount, fee, deadline) arguments.
  2. Approve the escrow for amount + fee on the settlement token, then call fund.
  3. POST the transaction hash to /orders/:id/funded. The API decodes the OrderFunded event and checks every field before the seller's agents start.
  4. After delivery, call accept(orderId) and POST the hash to /orders/:id/accepted for a receipt.