https://github.com/nuuner/timeline-generator
Minimalistic SVG timeline generator built with FastAPI and drawsvg
https://github.com/nuuner/timeline-generator
drawsvg fastapi python svg
Last synced: about 1 month ago
JSON representation
Minimalistic SVG timeline generator built with FastAPI and drawsvg
- Host: GitHub
- URL: https://github.com/nuuner/timeline-generator
- Owner: nuuner
- License: gpl-3.0
- Created: 2024-11-17T18:42:25.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2024-11-17T19:38:21.000Z (over 1 year ago)
- Last Synced: 2025-01-23T13:33:16.701Z (over 1 year ago)
- Topics: drawsvg, fastapi, python, svg
- Language: Python
- Homepage: https://timeline-generator.freknu.com/docs
- Size: 29.3 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Timeline Generator
A FastAPI service that generates minimalistic vertical SVG timelines from event data.
## Quick Start with Docker
```bash
docker compose up -d
```
The service will be available at http://localhost:3000
## Example
Input events:
```json
[
{
"title": "Project Kickoff Meeting",
"date": "2024-03-01 09:00",
"color": "blue"
},
{
"title": "Design Review",
"date": "2024-03-01 14:30",
"color": "purple"
},
{
"title": "Client Presentation",
"date": "2024-03-03 11:00",
"color": "green"
},
{
"title": "Team Workshop",
"date": "2024-03-07 13:00",
"color": "orange"
},
{
"title": "Project Deadline",
"date": "2024-03-15 17:00",
"color": "red"
}
]
```
Output:

## Local Development
Install dependencies:
```bash
poetry install
```
Start the development server:
```bash
poetry run uvicorn src.timeline_generator.main:app --reload
```
## Usage
Generate a timeline by making a GET request to `/timeline.svg` with your events as a JSON string:
```bash
curl "http://localhost:3000/timeline.svg?events=[{\"title\":\"Event 1\",\"date\":\"2024-02-15 09:30\",\"color\":\"blue\"}]" > timeline.svg
```
## API Documentation
- Swagger UI: http://localhost:3000/docs
- ReDoc: http://localhost:3000/redoc
## License
GNU General Public License v3.0 - See LICENSE file for details