Wappler 7 AI Agent via OpenRouter Cannot Complete Actions

hi @Teodor
I am testing the AI feature within Wappler version 7. I created a api key from OpenRouter and added it to the necessary places within Wappler. I am currently able to receive responses to the questions I ask. However, while using the agent feature, I encountered several issues with many models, such as "400 provider error", "Tool not found: null", "Error: An array has an empty value when tool_calls are constructed. tool_calls: [object Object]; tool: [object Object]", or the process being interrupted while the agent is running. I haven't been able to successfully complete even a single operation yet. I need your help to clarify the error further and to find a solution.

  • By the way, hello to everyone after a long time :slight_smile:

Hi Serhat,

Could you provide more info about which model are you using with OpenRouter?
And when do you get those errors, maybe a screenshot?

Anyway I would suggest to use github copilot as more fixed cost solution to get you started.

Hi George ,

I did some testing with a few models on OpenRouter:

  1. Anthropic Claude Sonnet 4
  2. DeepSeek R3 Free
  3. Google: Gemini 2.5 Pro Preview 06-05

These are the ones I use the most, but I’ve tested many other models as well and experienced similar issues with all of them. Thinking the problem might be related to OpenRouter, I also did new tests using Claude and OpenAI API keys, but unfortunately I encountered similar problems each time.

Apart from that, as you can also see in the screenshot, the input field that should appear at the bottom of the left chat panel disappears, and I have to restart Wappler.

ah yes I see there are known issues with Claude and OpenRouter, seems it is not handled well.

Also Claude is there the most expensive model, so it will cost you way too much money for few questions.

As I suggested it is better to use github copilot instead of openrouter as it is much more reliable

1 Like

thanks @George I’m expecting good news from you regarding the solution to the issue. Good luck!