You do not have permission to perform this action

curl --user uname:ppp this works but query doesn't
I added a new resource with the basic authentication with username: uname and password: ppp
then I created a new query using this resource but I am getting the following response when I run this query:
error:"{"detail":"You do not have permission to perform this action."}"
any ideas why?

This may or may not be your issue, but I had a similar problem (getting a 404 error on an API call that looked valid). Turned out that Retool would put a / at the end of the URL pattern if you set it up as a Resource (and that was an issue for our API), but if you created a query and coded the whole request into the REST query it would work fine and not insert the /.