Deploy your app or API on Deta Micros
A Deta Micro is a micro server where you can deploy your Python or Node web app without worrying about ops.
#
PythonMost Python micro frameworks are supported, like FastAPI and Flask. Deta should run both pure WSGI & ASGI apps without any issue. Full frameworks like Django are not fully supported yet, as they require various other commands.
For Deta to be able to run your code, you need to call your app instance app
and it has to be in a file called main.py
, which is the only required file for a Python Micro. Of course you could add more files and folders.
No need to use a server like uvicorn
, Deta has its own global server.
Make sure you have the framework in your requirements.txt
.
#
Example code#
FastAPI#
Bottlepy#
Flask#
Starlette#
Node.jsMost Node.js micro frameworks are supported, like Express, Koa, etc.
For Deta to be able to run your code, you need to call your app instance app
and it has to be in a file called index.js
, which is the only required file for a Node Micro. You also need to export app
. Of course you could add more files and folders.
Make sure you have the framework in your package.json
.
#
Example code#
Express.js#
Koa.js#
Fastify.js#
IssuesIf you run into any issues, consider reporting them in our Github Discussions.