mirror of
https://github.com/marcogll/telegram_expenses_controller.git
synced 2026-01-13 21:35:15 +00:00
feat: Initial project structure for expense tracker
This commit introduces the initial project structure for the expense tracker application. It includes the basic directory layout, configuration files, a FastAPI server with a `/process-expense` endpoint for n8n integration, and a `.gitignore` file to ensure a clean repository. This completes Phase 1 of the development plan.
This commit is contained in:
0
src/__init__.py
Normal file
0
src/__init__.py
Normal file
0
src/data_models.py
Normal file
0
src/data_models.py
Normal file
21
src/main.py
Normal file
21
src/main.py
Normal file
@@ -0,0 +1,21 @@
|
||||
from fastapi import FastAPI, Request
|
||||
import logging
|
||||
|
||||
# Configure logging
|
||||
logging.basicConfig(level=logging.INFO)
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
app = FastAPI()
|
||||
|
||||
@app.get("/")
|
||||
async def root():
|
||||
return {"message": "Expense Tracker API is running."}
|
||||
|
||||
@app.post("/process-expense")
|
||||
async def process_expense(request: Request):
|
||||
"""
|
||||
Receives expense data from n8n, logs it, and returns a confirmation.
|
||||
"""
|
||||
payload = await request.json()
|
||||
logger.info(f"Received expense data: {payload}")
|
||||
return {"status": "received", "data": payload}
|
||||
0
src/modules/__init__.py
Normal file
0
src/modules/__init__.py
Normal file
0
src/modules/ai_agents.py
Normal file
0
src/modules/ai_agents.py
Normal file
0
src/modules/config_loader.py
Normal file
0
src/modules/config_loader.py
Normal file
0
src/modules/data_manager.py
Normal file
0
src/modules/data_manager.py
Normal file
0
src/modules/input_handler.py
Normal file
0
src/modules/input_handler.py
Normal file
0
src/prompts/analyst_prompt.txt
Normal file
0
src/prompts/analyst_prompt.txt
Normal file
0
src/prompts/auditor_prompt.txt
Normal file
0
src/prompts/auditor_prompt.txt
Normal file
Reference in New Issue
Block a user