A couple of demos:
I built a separate tool on top of pandas which can mass-convert CSVs to SQLite - https://github.com/simonw/csvs-to-sqlite - so building the database for https://fivethirtyeight.datasettes.com/ is now a one-liner:
https://parlgov.datasettes.com/ uses the SQLite database from http://www.parlgov.org/ - this is a more interesting demo as it includes things like SQL views - e.g. https://parlgov.datasettes.com/parlgov/view_election
csvs-to-sqlite ~/fivethirtyeight/data fivethirtyeight.db
Both of these demos are served through Cloudflare - since the URL to each database incorporates a sha256 hash of the database contents, I can send a far-future cache expiry header on everything.
See also: PostgREST, which turns a PostgreSQL database into a rest API.
Shameless plug: I made something similar a while back - https://github.com/assafmo/SQLiteProxy
Not as fancy as OP's, but runs great in production since last June :-)
Click is nice, but for my money, Fire is what Click should have been. https://github.com/google/python-fire
shameless plug (for MySql) : https://github.com/o1lab/xmysql
XMYSQL : One command to generate REST APIs for any MySql Database. > 20+ releases to npm in last 2 weeks. > Have added 'a ton' of features since last shown on HN.
Asynchronous, easily configurable at runtime, and an exemplar of Python code by one of the creators of Django. Quite a treat.
Does Commodore own the trademark for the Datasette name?
Any examples of how it handles pagination? Couldn't find it in the README.md
Nice! Congrats on shipping. Any particular reason it's tied closely together with sqlite rather sqlalchemy which could potentially enable a range of backends? I guess to ensure immutability?
This is really cool! It'd be fun to have a GraphQL variant of this.
Congrats on shipping!
I have a sqlite DB with historical Visa data, and I want to expose it as an API (like your software does), but with API key. Not a python user here, can you tell me about the following?
1. Is it possible to put some security behind the API? So only queries with a key can access it?
2. How would I host this API? Where would the SQLite DB reside?
3. I understand the API is read-only, which is great and works for my use case! Can I also do read-writes to the database from a separate application that will keep updating the database on a nightly basis?
Congrats for the launch! I was searching for such tool exact yesterday:)
I understand the benefits of Immutable pattern, but it'll be nice if datasettle could provide interface with single non-frequent writer(for example, most FRED data is updated seasonally, some of them updates daily) so the pipeline pulling data from some source could be automated
Cool little utility. Like the fact you can pass SQL in the query string. Have to look for a use for this. Maybe internal use apps that update SQLite periodically from a larger database and just need a view of data. Thanks for sharing.
Disappointed this doesn't work on Windows, looks really cool.
The name is brilliant.
This looks great except for the fact that it runs through cloudflare, that's a big negative for me and will restrict a little my ability to deploy this. However, I can still see some great applications of this that I can't wait to try out.