Quill SDK for Python.
Project description
Quill Python SDK
Quickstart
First, install the quillsql package by running:
$ pip install quillsql
Then, add a /quill
endpoint to your existing python server. For example, if
you were running a FASTAPI app, you would just add the endpoint like this:
from quillsql import Quill
from fastapi import FastAPI, Request
app = FastAPI()
quill = Quill(
private_key=<YOUR_PRIVATE_KEY_HERE>,
database_connection_string=<YOUR_DB_CONNECTION_STRING_HERE>,
)
# ... your existing endpoints here ...
@app.post("/quill")
async def quill_post(data: Request):
body = await data.json()
return quill.query(org_id="2", data=body)
Then you can run your app like normally. Pass in this route to our react library on the frontend and you all set!
For local testing (dev purposes only)
pipenv install
pipenv shell
uvicorn examples.fastapi-server.app:app --reload --port 3000
You are now ready to ping your local server at http://localhost:3000.
Troubleshooting
If you run into issues with Library not loaded: @rpath/libpq.5.dylib
or no LC_RPATH's found
, try uninstalling and reinstalling postgres on your machine. For example, using homebrew:
$ brew uninstall c
$ brew update
$ brew install postgresql
If you're still having this issue, this resource might also be useful for you: https://www.psycopg.org/docs/install.html.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file quillsql-2.1.6.tar.gz
.
File metadata
- Download URL: quillsql-2.1.6.tar.gz
- Upload date:
- Size: 13.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 684655ddbad0358db711b98f6d516c59109c6876fcdef2128e0e6b83c9829794 |
|
MD5 | 902ace9b99a756fb5caaff3b6b4c2919 |
|
BLAKE2b-256 | 4a7fd5768dd9cfae4a96d81bb73a54e521d73257be9ac69e6ae5bdb83bd5c331 |
File details
Details for the file quillsql-2.1.6-py3-none-any.whl
.
File metadata
- Download URL: quillsql-2.1.6-py3-none-any.whl
- Upload date:
- Size: 15.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 14b5a8140e955d7c3c6c8d711dec7b828b0f58df87c6182c9f419b38c5ca2ac4 |
|
MD5 | 1d7d32adda923c04da2fe1476dbb40b8 |
|
BLAKE2b-256 | 2c951e0ef485387ad616a1169a69252041be0a931f3ae7f3515d522a4ecc1369 |