Skip to main content

Streams

Streams

@toothfairyai/sdk@latest…

Accessed via client.streams.

Methods

MethodHTTPEndpoint
getGETGET /stream/get/{id}
listGETGET /stream/list

get

async get(id: string)

Endpoint: GET /stream/get/{id} · API service

Response fields

FieldTypeDescription
idstringUnique identifier for the output stream
contentstringGenerated output content text
t_contentstringTranslated version of the output content
promptstringThe prompt that generated this output
t_promptstringTranslated version of the prompt
workspaceIDstringUnique workspace identifier (UUID v4)
typestringType classification (free-form string identifier)

Allowed: translator, answerer, parser, tokenizer, embedder, detector, questioner, generator, chatter, planner, analyser | | status | string | Current status of the resource

Allowed: success, failed, timeout, fulfilled, pending, inProgress, cancelled, awaitingUserInput, continued, ingested | | humanFeedback | string | Human feedback on the message: positive, negative, or neutral

Allowed: positive, negative, neutral | | humanFeedbackComment | string | Comment accompanying the human feedback | | humanFeedbackType | string | Type of human feedback: multilanguage, documentation, reasoning, images, charting, api, code, math, or moderation

Allowed: multilanguage, documentation, reasoning, images, charting, api, code, math, moderation | | humanFeedbackSubType | string | Sub-type of human feedback (varies by parent type) | | humanFeedbackProvidedBy | string | User who provided the human feedback | | adminResolution | string | Admin resolution notes for the feedback | | adminChecked | boolean | Whether an admin has reviewed this message | | autoTune | boolean | Whether auto-tuning from feedback is enabled | | scoring | integer | JSON-encoded quality scoring for the message | | metadata | object | Arbitrary metadata key-value pairs (JSON) | | createdBy | string | User ID who created the stream | | updatedBy | string | User ID who last updated the stream | | createdAt | string | Timestamp when this resource was created | | updatedAt | string | Timestamp when this resource was last updated |

Example

const result = await client.streams.get('agent-id');

list

async list(limit?: number)

Endpoint: GET /stream/list · API service

Example

const result = await client.streams.list();