^^ in query
^^ in debug
Which fails when triggered because the API expects an object not stringified object.
^^ in query
^^ in debug
Which fails when triggered because the API expects an object not stringified object.
Hey @pckilgore!
Would you mind sharing the specific error you're seeing from your API? Retool will often display stringified bodies that are interpreted as the endpoints as objects so I just want to make sure there isn't something else going on here and it would be helpful to get more context.
This also looks like it's an OpenAPI resource is that correct? Could you share the relevant part of your spec?
The error was roughly "failed to marshal string into struct" with the struct being the exact one I saw as a string in the debug console, so I stopped investigating there.
The real issue was actually a field on that struct should have been either undefined or an array, but was being passed as a string by retool. I guess the golang error gets reported based on the struct the field is a part of not the field itself.
When I fixed that and started passing an empty array not an empty string retool worked fine.
Feedback
relevant piece of spec (for both here and my other issue):
Ah! Nice find
Thanks for both pieces of feedback, will pass them along and we'll notify you in each thread with updates!