Skip to main content

A Python library used to generate a backend for custom logic using Hasura as a Data-layer

Project description

# Pysura - BETA

### Hasura + Python = Pysura

`commandline pip install pysura pysura (pysura_cli) >>> setup_hasura `

## Requirements:

### To use Pysura to generate FastAPI microservices from Hasura metadata:

  • Bring your own Hasura

  • Python 3.6+

### To deploy Hasura with Pysura on Google and auto-deploy your microservices:

  • gcloud CLI

  • gcloud beta CLI

  • A billing account with Google Cloud

  • Docker

### To bake in Phone Auth (Requires deployment on Google):

  • Firebase CLI - For Backed in Auth

# What is Pysura?

Pysura is a CLI tool that’s designed to make building and deploying multi-tenant enterprise grade applications as easy as a freshman year algorithms class. It’s a highly opinionated way because it’s the right way.

It’s kind of like running npm init, if npm was for backends, it provides your backend, auth, and database for you in the cloud in a way that is infinitely scalable and uses zero-trust, with fully type-safe a type-safe GraphQL backend and a bring-your-own front-end with built-in support for Flutter.

## Do I need to deploy Hasura with Pysura to use it?

Nope! You can scaffold out all events, actions, and triggers with Pysura, but when you do… Auth won’t work unless you set it up yourself! Still useful for getting started with new projects though.

## Is this just a wrapper for the Hasura CLI?

Pysura does not use the Hasura CLI, and instead manages the metadata directly via retrieving it and overwriting it.

## Limitations:

Currently, this only supports a Google-based deployment/stack. Easily fixable. Just need a fellow AWS/Azure/Etc. wizard who can translate the gcloud commands. I think the portability is pretty high since everything is done from the CLI. The setup wizard is just curling everything.

## Neat! But it doesn’t support my cloud provider, when will you be adding AWS/Azure/Etc. support?

I won’t. You can. I built this because I needed it. If our stack changes providers, or potentially if someone was willing to pay for it, I’d be willing to add support for other providers. But as of now, the best bet would be to open a PR and add support for your provider of choice. I tried to design it to be pretty modular. The gcloud –format=json flag is what changed the game when I found it.

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

pysura-0.10.48.tar.gz (33.9 kB view details)

Uploaded Source

File details

Details for the file pysura-0.10.48.tar.gz.

File metadata

  • Download URL: pysura-0.10.48.tar.gz
  • Upload date:
  • Size: 33.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.4

File hashes

Hashes for pysura-0.10.48.tar.gz
Algorithm Hash digest
SHA256 13b4ed152f6f3b58ac4e01023d02515cf84a51afd3930582bdbb7efaf44a6459
MD5 0248fa76e7fb75b0f95900e1c3f550fe
BLAKE2b-256 9dc04972a137df60a127cb2e413934fe2da63de45a1eccb18e2ea3ca60a143be

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page