You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
TypeScript guides have diverged from the current SDK request shapes #238
The current SDK expects requestBody and object arguments such as { hash }.
STT and TTS examples pass their request bodies at the top level. The current SDK requires sttRequest and speechRequest.
The Agent SDK migration guide recommends:
import { OpenRouter } from '@openrouter/agent/client';
However, @openrouter/agent@0.9.0 does not export the ./client subpath. The package root and @openrouter/agent/openrouter resolve successfully.
The Agent SDK API reference lists ToolContextMap and ToolExecuteContext as exports from @openrouter/agent, but both types are currently available from @openrouter/agent/tool-types instead.
Representative compiler errors include TS2769, TS2353, TS2345, TS2339, and TS2307.
I reproduced each pattern and verified that corrected request/import shapes compile.
I also have the complete page inventory, compiler output, and corrected examples available.
Expected content
The TypeScript guides should use the request wrappers and import paths exposed by the currently published packages:
chatRequest for chat.send()
input for Agent SDK callModel()
requestBody for embeddings and API-key creation
object arguments such as { hash } for API-key operations
sttRequest and speechRequest for audio operations
@openrouter/agent or @openrouter/agent/openrouter for the Agent client
@openrouter/agent/tool-types for ToolContextMap and ToolExecuteContext, unless those types are intentionally re-exported from the package root
Activity