Summary
The official OpenClaw plugin currently registers ZenMux only as an LLM provider. OpenClaw therefore cannot select ZenMux for its native image.generate capability, even though the ZenMux catalog includes image-output models such as google/gemini-3.1-flash-image.
Current behavior
After installing @zenmux/openclaw-plugin@0.1.2 and completing OAuth:
zenmux appears in the LLM provider registry.
- The plugin manifest does not declare
contracts.imageGenerationProviders.
- The plugin does not call
api.registerImageGenerationProvider(...).
- Configuring
agents.defaults.imageGenerationModel.primary as zenmux/google/gemini-3.1-flash-image does not work without an additional adapter.
Routing the model through an OpenAI-compatible /images/generations endpoint is also incorrect. The working ZenMux route is the Gemini/Vertex-compatible endpoint:
POST https://zenmux.ai/api/vertex-ai/v1/publishers/google/models/gemini-3.1-flash-image:generateContent
with generationConfig.responseModalities: ["TEXT", "IMAGE"]. Image bytes are returned in candidate content parts as inlineData / inline_data.
Expected behavior
The official plugin should expose ZenMux as an OpenClaw image-generation provider and reuse the existing ZenMux OAuth credential/refresh flow.
Suggested model reference:
zenmux/google/gemini-3.1-flash-image
Suggested implementation
- Add
imageGenerationProviders: ["zenmux"] to the plugin manifest contract.
- Register an image-generation provider with
api.registerImageGenerationProvider.
- Resolve request-ready credentials through OpenClaw runtime model auth so OAuth refresh remains provider-owned.
- Map OpenClaw prompt, input images, aspect ratio, resolution, and output format to ZenMux Vertex
generateContent.
- Parse base64 image parts from
candidates[].content.parts[].inlineData and inline_data.
- Keep response-size and timeout limits bounded.
- Add unit tests for request mapping, OAuth credential resolution, error responses, and image parsing.
Verification performed
A small local companion provider using the route above generated a real 1024×1024 PNG successfully with:
- provider:
zenmux
- model:
google/gemini-3.1-flash-image
- route:
vertex-generateContent
One earlier request returned a successful response without image data, so the implementation should surface that case clearly and allow OpenClaw's configured fallback chain to proceed.
Summary
The official OpenClaw plugin currently registers ZenMux only as an LLM provider. OpenClaw therefore cannot select ZenMux for its native
image.generatecapability, even though the ZenMux catalog includes image-output models such asgoogle/gemini-3.1-flash-image.Current behavior
After installing
@zenmux/openclaw-plugin@0.1.2and completing OAuth:zenmuxappears in the LLM provider registry.contracts.imageGenerationProviders.api.registerImageGenerationProvider(...).agents.defaults.imageGenerationModel.primaryaszenmux/google/gemini-3.1-flash-imagedoes not work without an additional adapter.Routing the model through an OpenAI-compatible
/images/generationsendpoint is also incorrect. The working ZenMux route is the Gemini/Vertex-compatible endpoint:with
generationConfig.responseModalities: ["TEXT", "IMAGE"]. Image bytes are returned in candidate content parts asinlineData/inline_data.Expected behavior
The official plugin should expose ZenMux as an OpenClaw image-generation provider and reuse the existing ZenMux OAuth credential/refresh flow.
Suggested model reference:
Suggested implementation
imageGenerationProviders: ["zenmux"]to the plugin manifest contract.api.registerImageGenerationProvider.generateContent.candidates[].content.parts[].inlineDataandinline_data.Verification performed
A small local companion provider using the route above generated a real 1024×1024 PNG successfully with:
zenmuxgoogle/gemini-3.1-flash-imagevertex-generateContentOne earlier request returned a successful response without image data, so the implementation should surface that case clearly and allow OpenClaw's configured fallback chain to proceed.