Courier icon

Courier

Interact with Courier Local or Cloud APIs

Courier

AI-generated

Summary

Send a chat completion request to Courier inference or OpenAI-compatible API using specified model and prompt/messages; return array of items with json fields containing response content, model, and usage metadata.

Inputs

  • main — Workflow items are processed independently; each item's parameters are read per item index.

Output shape

array

Each returned item contains a 'json' field. For openai provider: { content: string, output: string, model: string, usage: { prompt_tokens: number, completion_tokens: number }, generation_tokens: number, peak_memory: number }. For courier provider: spread of API responseData with optional output field if responseData.content is present.

Examples

Example 1: Text prompt to Courier API

apiProvider: courier, model: , promptType: text, prompt: user message, temperature: 0.2, webSearch: false, jsonSchema: {}

Example 2: Messages prompt to OpenAI-compatible endpoint

apiProvider: openai, model: , promptType: messages, messages: [{role: user, content: hello}], temperature: 0.7, webSearch: true, jsonSchema: {}}

Links

Discussion