{"slug": "show-hn-an-openai-compatible-model-agnostic-agent-api", "title": "Show HN: An OpenAI-compatible, model-agnostic agent API", "summary": "Rebyte launched an OpenAI-compatible, model-agnostic Agents API at https://api.rebyte.ai/v1, letting developers call a managed agent runtime using the official OpenAI client (openai 7.15.0) on Node.js 22+ with a Rebyte API key. The API provides durable sessions, managed environments, live event streaming with active-Turn input queuing, HTTP and stdio MCP support, encrypted Vaults for service credentials, and a Dynamic Workflow feature available via API and CLI 0.2.3+. Rebyte also published a Rebyte Agent SDK and a commerce-agent-starter demo on GitHub.", "body_md": "[Developer documentation](https://rebyte.ai/docs/agents-api/overview)/Agents API\n\n# Build with Rebyte.\n\nBuild applications with a managed agent runtime, durable sessions, and tools.\n\n## Start building\n\n```\npnpm add openai@7.15.0\n```\n\nUse Node.js 22+ and the official OpenAI client. Configure `apiKey` with your `REBYTE_API_KEY` and `baseURL` as `https://api.rebyte.ai/v1`. See the [Quickstart](https://rebyte.ai/docs/agents-api/quickstart) for a complete example.\n\nOur two application repositories serve different purposes:\n\n[SDK](https://github.com/ReByteAI/rebyte-agent-sdk)\n\n**Rebyte Agent SDK** React hooks, chat UI, server adapter, CLI and Rebyte extensions. Uses the official OpenAI client.\n[Demo](https://github.com/ReByteAI/commerce-agent-starter)\n\n**commerce-agent-starter** A complete commerce demo with catalog, cart and client functions. Clone it to run or customize the storefront.\n- The official OpenAI client\n- Call the Agents API with the official openai package, your Rebyte API key and the Rebyte endpoint. [View supported features](#current-availability) \n- Trace execution\n- Follow model calls, tool activity and token usage with execution traces tied to each session and turn. [Explore observability](https://rebyte.ai/docs/agents-api/observability) \n- Control access\n- Isolate session files, restrict sandbox network access and keep service MCP credentials outside the sandbox in encrypted Vaults. [Runtime security](https://rebyte.ai/docs/agents-api/environments/security) \n\n## Core concepts\n\n| Concept | Purpose | \n|---|---|\n| **Agent** | Reusable configuration: model, instructions, tools, and generation settings. | \n| **Environment** | Optional compute and filesystem used by a session. | \n| **Session** | Persistent execution and conversation state, with a resolved copy of the agent configuration. | \n| **Events and items** | Events communicate inputs and progress; items retain messages and execution output. | \n\nA **Turn** tracks one unit of work inside a session. An **Artifact** is an immutable deliverable produced by a completed turn. A saved Agent can be reused across Sessions; each managed Session owns its own environment.\n\n## From input to result\n\n1. Create a Session with an inline Agent definition or a saved Agent ID.\n2. Provide input at creation or submit it through the Session events endpoint.\n3. Receive text, tool activity, and lifecycle events as the runtime works.\n4. Read the resulting Items, Turn status, and Artifacts.\n5. Continue the Session with another task, or queue another task behind its active Turn.\n\nYour application handles its UI and function tools. Rebyte manages execution and the Session's hosted environment. See [Architecture](https://rebyte.ai/docs/agents-api/architecture).\n\n## Current availability\n\nThe production endpoint is `https://api.rebyte.ai/v1`. Use `http://127.0.0.1:34567/v1` only with a running local Relay and a key for its local organization.\n\n| Capability | Current implementation | \n|---|---|\n| Agents, Sessions, Turns, Items | Implemented | \n| Live event streaming and input queuing | Implemented; historical events are not replayed; active-Turn input queues | \n| Managed environments, inline files, Artifacts | Implemented | \n| Functions, HTTP and stdio MCP, Vaults | Implemented with documented limits | \n| [Platform connections](https://rebyte.ai/docs/agents-api/tools/platform-connections) | Add existing Personal or Organization accounts to API Agents; platform-managed authentication | \n| Tool search | Deferred client functions with explicit `tool_search` ; automatic MCP discovery with a short-lived catalog cache | \n| [Dynamic Workflow](https://rebyte.ai/docs/agents-api/tools/dynamic-workflow) | Available through the API; CLI 0.2.3+ supports the declaration. Model-generated JavaScript composes Session tools and application functions, with durable function handoffs. | \n| Web search | Implemented; `cached` mode runs as live, no location targeting | \n| Inline ZIP skills, plus Rebyte's GitHub-sourced skills | Implemented in managed environments; capability directories are auto-scanned for `SKILL.md` once the Sandbox is available | \n| [Webhooks](https://rebyte.ai/docs/agents-api/sessions/webhooks) | Signed Session, Turn, Workflow Run and Schedule Run notifications with retries and function handoffs | \n| Plugins | Not yet supported | \n| Execution tracing | Implemented through Langfuse; view Agent, Session and Turn traces in Platform | \n| Multi-agent | Not yet supported | \n| Automatic context compaction | Not yet supported | \n\nThe navigation follows OpenAI's guide with additional pages for Rebyte-specific features. A hollow dot marks an unsupported capability. Compatibility is defined by the implemented fields and behavior, not by the presence of a page in this guide.\n\nSee [OpenAI compatibility](https://rebyte.ai/docs/agents-api/compatibility) for a dated comparison\nof implemented features, missing endpoints and behavior differences.\n\n## Official OpenAI SDK\n\nUse the official `openai` package with Rebyte's endpoint and organization API key.\nAgents API methods, types, pagination and SSE handling come from that dependency.\n\n```\npnpm add openai@7.15.0\npython\nimport OpenAI from 'openai';\n\nconst client = new OpenAI({\n  apiKey: process.env.REBYTE_API_KEY,\n  baseURL: 'https://api.rebyte.ai/v1',\n  maxRetries: 0,\n});\nconst session = await client.beta.agents.sessions.create({\n  agent: { model: 'gpt-6-luna', instructions: 'Help the user.' },\n  environment: { type: 'openai_hosted' },\n  input: 'Hello!',\n});\n```\n\nThe `openai_hosted` protocol value selects Rebyte-managed compute at this endpoint.\nOmit `environment` for chat, service MCP and client functions without a Sandbox.\nThe official SDK adds `OpenAI-Beta: agents=v1`; raw HTTP clients must provide it.\nThe verified TypeScript dependency is `openai@7.15.0`. Python applications can use\n`openai==3.13.0` with the same endpoint. See [Quickstart](https://rebyte.ai/docs/agents-api/quickstart).\n\nWorkflow Agents and Schedules are Rebyte extensions. Use their HTTP APIs or the\nsmall `@rebyteai/agent-extensions@0.3.0` npm package with an existing official client.\nThey are not methods on the official `OpenAI` class.\n[Current availability](#current-availability) describes server support.\n\n## SDK and example application\n\n| Repository | What it provides | How to use it | \n|---|---|---|\n| [rebyte-agent-sdk](https://github.com/ReByteAI/rebyte-agent-sdk) | Rebyte Agent SDK: API extensions, React/UI, server adapter, CLI and examples. | Install packages from npm. Clone only to run the complete examples or contribute source changes. | \n| [commerce-agent-starter](https://github.com/ReByteAI/commerce-agent-starter) | A complete commerce demo with catalog, cart, Skills and client functions. | Clone it to run or customize the example storefront. | \n\n### Rebyte Agent SDK\n\n[Rebyte Agent SDK](https://github.com/ReByteAI/rebyte-agent-sdk) is Rebyte's\nSDK, maintained in the **rebyte-agent-sdk** repository. It includes the official\n`openai` API client, Rebyte extensions and runnable examples, plus\n`@rebyteai/agent-react` for React session state, `@rebyteai/agent-ui` for a ready-made\nchat interface, `@rebyteai/agent-server` for the server adapter, and a configuration CLI.\n\nStart with the [Node application](https://github.com/ReByteAI/rebyte-agent-sdk/tree/main/examples/react-chat)\nor [Cloudflare application](https://github.com/ReByteAI/rebyte-agent-sdk/tree/main/examples/react-chat-cloudflare).\nThe [Agents API recipes](https://github.com/ReByteAI/rebyte-agent-sdk/tree/main/examples/agents-api)\ncover Agent creation, independent Sessions, streaming, files and client functions.\nInstall only the packages your application needs:\n\n| npm package | Purpose | \n|---|---|\n| `openai` | Official API client for Agents, Sessions, streaming and Artifacts. | \n| `@rebyteai/agent-extensions` | Optional Rebyte Workflow and Schedule resources. | \n| `@rebyteai/agent-react` | React hooks and session state. | \n| `@rebyteai/agent-ui` | Ready-made React chat interface and styles. | \n| `@rebyteai/agent-server` | Server adapter that keeps your Rebyte API key out of the browser. | \n| `@rebyteai/cli` | Create, update, validate and export Agent configuration from the terminal. | \n\n```\npnpm add openai@7.15.0\n```\n\nThe current npm release, 0.3.0, uses the official client. The 0.4.0 source adds\nfunction-wait support while its npm publication is pending. Follow the\n[SDK guide](https://rebyte.ai/docs/agents-api/sdk) to install the packages or run a template.\nExisting 0.2.x packages still use the old fork. Follow the [0.3.0 migration guide](https://rebyte.ai/docs/agents-api/sdk-migration) to upgrade. Standard API integrations need only `openai`.\n\n### Commerce Agent\n\n[Commerce Agent](https://github.com/ReByteAI/commerce-agent-starter) is a complete\nexample storefront. Its Python host implements catalog, cart and presentation\nfunctions with on-demand discovery, with a separate API Session for each conversation and per-Session Skills.\nFollow the [Rebyte integration guide](https://github.com/ReByteAI/commerce-agent-starter/tree/main/rebyte)\nfor setup and the execution flow.\n\nThe SDK’s TypeScript examples use the official client. Commerce uses the official Python client. Both connect to the same Rebyte Agents API.\n\nAPI Agents appear in Platform. They are independent of product UI Agent Profiles and Workspaces. A Session never inherits another Session's Sandbox or Artifacts because it uses the same saved Agent.\n\nTo list your organization's saved API Agents, use `GET /v1/agents` or\n`client.beta.agents.list()`. See [Agent listing and pagination](https://rebyte.ai/docs/agents-api/configuration#list-agents)\nfor authentication, a cURL request, and an SDK example that retrieves every page.\n\n## Fixed Workflow Agents\n\n[Workflow Agents](https://rebyte.ai/docs/agents-api/workflow-agents) execute saved JavaScript directly. Create a draft in the console or API, test it, then explicitly publish a fixed version for API callers.\n\n[Scheduled Agents](https://rebyte.ai/docs/agents-api/schedules) run an Agent on a recurring or one-time schedule. Choose a continuous Session for context across runs, independent Sessions for isolated tasks, or a pinned published Workflow version.\n\n[OpenAI Agents API ↗](https://developers.openai.com/api/docs/guides/agents-api/overview)", "url": "https://wpnews.pro/news/show-hn-an-openai-compatible-model-agnostic-agent-api", "canonical_source": "https://rebyte.ai/docs/agents-api/overview", "published_at": "2026-09-27 11:35:48+00:00", "updated_at": "2026-09-27 12:01:48.822842+00:00", "lang": "en", "topics": ["ai-agents", "ai-tools", "developer-tools", "agent-protocols", "ai-infrastructure"], "entities": ["Rebyte", "OpenAI", "Rebyte Agent SDK", "commerce-agent-starter", "GitHub", "Node.js"], "also_reported_by": [], "alternates": {"html": "https://wpnews.pro/news/show-hn-an-openai-compatible-model-agnostic-agent-api", "markdown": "https://wpnews.pro/news/show-hn-an-openai-compatible-model-agnostic-agent-api.md", "text": "https://wpnews.pro/news/show-hn-an-openai-compatible-model-agnostic-agent-api.txt", "jsonld": "https://wpnews.pro/news/show-hn-an-openai-compatible-model-agnostic-agent-api.jsonld"}}