Skip to content

Conversation

@pocketarc
Copy link
Contributor

The OpenRouter provider had video support, but the payload format was incorrect. It was using input_video with a data/format structure, but OpenRouter's API expects video_url with a url field (either a direct URL or a base64 data URL).

Before

['type' => 'input_video', 'input_video' => ['data' => '...', 'format' => 'mp4']]

After

['type' => 'video_url', 'video_url' => ['url' => 'data:video/mp4;base64,...']]

I've updated the mapper to match the OpenRouter video documentation, added documentation, and included tests. Also added support for passing video URLs directly (e.g., YouTube links for Gemini models).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant