Can i send sql queries to database using http? (rest api)
Hey, I'm trying to create a custom chatgpt which should take data from supabase.
I want it to perform complex queries and advanced analysis.
But chatgpt can only send http requests.
So how to setup so that supabase can receive sql queries through http (rest api) .
Also, please let me know if supabase allows creating custom endpoints for restful API (crud)
If yes, how to do that.
Thanks
3 Replies
You could use edge functions for your endpoints? And you can also simply run database functions using supabaseClient.rpc('function'). These two features may be what your looking for.
Hey @Ryann
I will check out edge functions.
Yes rpc I tried, but for some reason it doesn't work.
Can you tell me what will be the correct url and path for rpc requests
When you create your postgres function if you go the dashboard api tab you can see your functions and then there will be an option to see js call or BASH which will show you the http direct REST call.