-
-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: Allow OPTIONS requests to RPC #1839
Conversation
Right now you're returning URIs in HTTP/REST should be completely replaceable - i.e. Right now, an This makes the whole thing a lot more complicated, because you need to take the actual arguments passed via query string into account. The routing-refactor will make this a lot easier, so I suggest we wait for that. |
So the assumption of the PR is that OPTIONS only identifies the URL-path( I guess the assumption comes from seeing examples in the wild, like this one from Spring REST: OPTIONS /SpringRestExample/api/rest/employee-management/employees/1
Allow: GET,DELETE,PUT,OPTIONS
This makes me realize that OPTIONS for our table/view paths are also incomplete, because currently: OPTIONS /projects?id=eq.1
Allow: OPTIONS,GET,HEAD,POST,PUT,PATCH,DELETE And the |
Thanks for putting it into much better words than I did :).
Uh. Absolutely right. And PUT should only be there, when the PK is given in the query string, too. |
According to the discussion above, the routing refactor is needed to fix the issue. Closing. |
This PR handles OPTIONS requests to functions, mentioned here: #1826
Won't add the 405 response to a GET for a volatile function feature due to the routing refactor as discussed here