Sign in
Docs
API referenceCoordinator

API reference

Say in a thread

Have a token? Manage tokens in the console
POST
/v1/coordinator/threads/{thread_id}/messages

Post a message as the caller. A turn is queued on the caller's own runners and waits for one if none is online: no runner, no AI.

Needs scope coordinator:write.

Authorization

bearer
headerAuthorizationBearer <JWT>

An access token from the identity provider: a person's, or a customer's from the client credentials grant with an API key (developers.inorbit.hr). The gateway verifies it; the audience is iohr-api.

Path Parameters

thread_id*string

The thread's id, thr_ and a ULID.

Request Body

iohr.coordinator.v1.SayRequest; path variables override their fields

application/json
  1. body

iohr.coordinator.v1.SayRequest

account_id?string
body?string
links?array<string>
thread_id?string

Response Body

iohr.coordinator.v1.SayResponse

application/json
  1. response

iohr.coordinator.v1.SayResponse

message?

iohr.coordinator.v1.Message

turn?

iohr.coordinator.v1.Turn

import { ApiError, Public } from "@inorbithr/sdk";// Reads INORBIT_TOKEN, or INORBIT_KEY_ID and INORBIT_KEY_SECRET.const api = Public.fromEnv();try {  const { value } = await api.coordinator.say("<thread_id>", {    body: "<body>",    links: ["<links>"],  });  console.log(value);} catch (e) {  if (!(e instanceof ApiError)) throw e;  console.error(`${e.code}: ${e.problem} (request id ${e.raw.requestId})`);  process.exitCode = 1;}

npm install @inorbithr/sdk. Calls the package's public surface; an operation newer than your package needs the next release or a client generated for your account. The SDKs.

Example Response
{  "message": {    "author": "string",    "body": "string",    "created_at": "string",    "kind": "string",    "links": [      "string"    ],    "message_id": "string",    "thread_id": "string"  },  "turn": {    "attempt": 0,    "cost": {      "duration_ms": "string",      "label": "string",      "usage": {        "cache_read": "string",        "cache_write": "string",        "input": "string",        "output": "string"      },      "usd_estimate": 0.1    },    "created_at": "string",    "denied_tools": [      "string"    ],    "duration_ms": "string",    "job_id": "string",    "kind": "string",    "lease_id": "string",    "model": "string",    "num_turns": 0,    "origin": "string",    "outcome": "string",    "pack_sha256": "string",    "provider": "string",    "provider_session_id": "string",    "reply": {      "actions": [        {          "kind": "string",          "payload_json": "string"        }      ],      "evidence": [        "string"      ],      "left": [        "string"      ],      "say": "string",      "state": "string"    },    "reported_at": "string",    "resumed": true,    "runner_id": "string",    "started_at": "string",    "state": "string",    "thread_id": "string",    "turn_id": "string",    "updated_at": "string",    "user": "string"  }}