Skip to main content

A FastAPI/ASGI bridge for Appwrite Functions

Project description

APPyWrite 🚀

APPyWrite is a lightweight bridge that allows you to run FastAPI (or any ASGI-compatible application) inside Appwrite Functions.

Features

  • ASGI Bridge: Seamlessly translates Appwrite context.req to ASGI Scope.
  • Async Support: Built for Appwrite's latest async runtimes.
  • Automatic Mapping: Translates FastAPI responses back to context.res (JSON, Text, etc.).

Installation

pip install appywrite

Quick Start

Create a main.py for your Appwrite function:

from fastapi import FastAPI
from appywrite import AppyWriteBridge

app = FastAPI()

@app.get("/")
async def hello():
    return {"message": "Hello from FastAPI on Appwrite!"}

bridge = AppyWriteBridge(app)

# This is the entry point for Appwrite
async def main(context):
    return await bridge.handle(context)

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

appywrite-0.1.0.tar.gz (36.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

appywrite-0.1.0-py2.py3-none-any.whl (2.8 kB view details)

Uploaded Python 2Python 3

File details

Details for the file appywrite-0.1.0.tar.gz.

File metadata

  • Download URL: appywrite-0.1.0.tar.gz
  • Upload date:
  • Size: 36.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.12

File hashes

Hashes for appywrite-0.1.0.tar.gz
Algorithm Hash digest
SHA256 df29b811a8a5403931ef75c25b9e3c53d30c7d926051faeea9a0cded5028da00
MD5 00950c260deca3d9188aea896a3769e2
BLAKE2b-256 46c3cb1a504e38541824ec190141ac7e90a71be327d023dd659c0a3e564cfdfc

See more details on using hashes here.

File details

Details for the file appywrite-0.1.0-py2.py3-none-any.whl.

File metadata

  • Download URL: appywrite-0.1.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 2.8 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.12

File hashes

Hashes for appywrite-0.1.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 816feb9c827c92b85eb6856384d387b8be0b6727e8ed8b933a8259ca50b40e86
MD5 ce8c8df4febc8e093289f9782a7b876b
BLAKE2b-256 a738088ba50a13032ae244afd400129f392a70e8cd9227a2bc5c047e33032aca

See more details on using hashes here.

Supported by

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