https://github.com/masterivanic/lato-full-api
This using lato micro framework
https://github.com/masterivanic/lato-full-api
Last synced: 12 months ago
JSON representation
This using lato micro framework
- Host: GitHub
- URL: https://github.com/masterivanic/lato-full-api
- Owner: masterivanic
- Created: 2024-08-04T20:43:13.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2025-03-22T22:18:44.000Z (over 1 year ago)
- Last Synced: 2025-03-22T23:20:05.983Z (over 1 year ago)
- Language: Python
- Size: 16.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# TODO Application With Lato 🚀
This is a sample application built using the Lato microframework for Python. It demonstrates basic usage of Lato, including creating an application, defining commands, and implementing command handlers.
## Introduction
[Lato](https://lato.readthedocs.io/en/latest/) is a microframework for building modular Python applications. It provides a simple and flexible way to organize your code into reusable components. This example showcases how to use Lato to create a simple greeting application.
## Features
* Uses the Lato microframework.
* Demonstrates defining commands and handlers.
* Includes dependency injection.
* Provides a basic command-line interface.
## Installation
1. Make sure you have Python 3.11 or higher installed.
2. Install Lato:
```
poetry install
```
## Usage
1. Save the code above as `main.py`.
2. Run the application from your terminal:
```
uvicorn api:api --reload
```
## Test API Endpoint
To test the API endpoint, you can use the following `curl` command:
```bash
curl -X 'GET'
'http://localhost:8000/'
-H 'accept: application/json'
```