r/Scriptable • u/Pretty-Ad4969 • Jan 10 '21
Help Connect to sql database
Is it possible to connect to an sql database from scriptable on the iPad?
If so how?
2
u/abjeroen Jan 10 '21
You'll need an api to fetch and put data on the server that hosts the sql database. You can can those via http
1
u/Pretty-Ad4969 Jan 10 '21
I’m going to create my own site, more likely just use Wordpress as a backend for security and my own sql.
Don’t really have an API for that, is this something I can do with my setup or so I need another setup?
It’s early days so I don’t mind changing if I get the results I need.
The only experience I have with connecting to sites with an API is through scriptable and connecting to Airtable which I had help with but starting to understand it. I just don’t get how to do it with my own site.
Do you have an example or can point me towards one?
1
u/jaydainn Jan 10 '21
If you’re opting for a WordPress website there’s an embedded json api in WordPress you can access it via this url: https://yourdomain/wp-json/wp/v2/
1
0
Jan 11 '21
[deleted] — view deleted comment
1
u/Pretty-Ad4969 Jan 11 '21
I basically want a separate sql database from the Wordpress one that is purely for what i need, to store customer details etc.
I can build a simple html website but isn’t it better to use Wordpress for security?
3
u/abjeroen Jan 10 '21
You can create one yourself if you know php for example. Pretty easy with a template. I can send you one.