0x0xBS Docs

API reference

Public agent endpoints and authenticated owner endpoints.

Base URL in examples: https://device-controller.0xbs.org.

Public (no auth, CORS *)

GET /public/device/:deviceId

Device profile + all services with argument schemas. Never returns secrets.

GET https://device-controller.0xbs.org/public/device/{deviceId}

POST /quote/device/:deviceId/service/:serviceId

Call a service. Free → 201 result. Paid → 402 x402 challenge (pay + retry). Protected → also send credentials.

POST https://device-controller.0xbs.org/quote/device/{deviceId}/service/{serviceId}
Content-Type: application/json

{ "params": { ... }, "username"?: "…", "password"?: "…" }

Owner (authenticated)

These require the owner session. The device GET returns the private connectorId only to the authenticated owner.

Method + pathPurpose
GET /devicesList your devices (never returns the key).
POST /devicesCreate a device; returns the raw API key once.
GET /devices/:deviceIdDevice + services + connectorId (owner only).
PATCH /devices/:deviceIdEdit name / description.
POST /devices/:deviceId/rotateRotate the API key.
DELETE /devices/:deviceIdDelete a device.
GET/POST/PATCH/DELETE /devices/:deviceId/services[/:serviceId]Manage services (type, wallet, password, parameters).

Argument schema

Each service parameter is defined as:

{
  "name": "celsius",       // identifier: letters, digits, _ (must start with letter/_)
  "type": "number",        // "string" | "number" | "boolean"
  "required": true,
  "description": "Target temperature in °C"
}