A FastAPI application for managing meetings, notes, and tasks.
Implement all endpoints through a service layer and write it to the database, then assert that you can read it again.
To do this:
- Add authentication. Do this however you would like (external libraries are allowed). Keep it as simple as possible though.
- Create a service per resource that all implement a base service class.
- Put all of the services into a service mesh. Call's between each service should route through the mesh.
- The service mesh is user specific, and should should support caching.
- The mesh should support local development, and cloud development, and should be composable in order to accomplish this. Ie, local development is in memory, but in production the service mesh might allow gRPC connections between services seamlessly in production. Note you do not need to support gRPC for this task - but design this in such a way that the communication mode between services is easily interchangeable.
- Create a decorator that can be placed on each service. This decorator allows us to call service_mesh.get_tools(), which can be passed onwards to an LLM.
- The service mesh (and the services within in) should only be able to access resources that only the user making the request.
- Users: Create and manage users who attend meetings
- Meetings: Schedule meetings with attendees
- Notes: Add notes to meetings
- Tasks: Create tasks due at specific meetings
- Install dependencies:
pip install -r requirements.txt- Run the application:
uvicorn main:app --reloadThe API will be available at http://localhost:8000
Once the server is running, you can access:
- Interactive API docs (Swagger UI):
http://localhost:8000/docs - Alternative API docs (ReDoc):
http://localhost:8000/redoc - OpenAPI schema:
http://localhost:8000/openapi.json
POST /users/- Create a new userGET /users/- List all usersGET /users/{user_id}- Get a specific user
POST /meetings/- Create a new meeting with attendeesGET /meetings/- List all meetingsGET /meetings/{meeting_id}- Get a specific meeting with detailsPUT /meetings/{meeting_id}- Update a meetingDELETE /meetings/{meeting_id}- Delete a meeting
POST /notes/- Create a new note for a meetingGET /notes/- List all notes (can filter by meeting_id)GET /notes/{note_id}- Get a specific note
POST /tasks/- Create a new task due at a meetingGET /tasks/- List all tasks (can filter by meeting_id or status)GET /tasks/{task_id}- Get a specific taskPUT /tasks/{task_id}- Update a task (change status, reassign to different meeting)DELETE /tasks/{task_id}- Delete a task
curl -X POST http://localhost:8000/users/ \
-H "Content-Type: application/json" \
-d '{"name": "John Doe", "email": "john@example.com"}'curl -X POST http://localhost:8000/meetings/ \
-H "Content-Type: application/json" \
-d '{
"title": "Sprint Planning",
"description": "Q1 Sprint Planning",
"scheduled_time": "2024-01-15T10:00:00",
"attendee_ids": [1, 2]
}'curl -X POST http://localhost:8000/tasks/ \
-H "Content-Type: application/json" \
-d '{
"title": "Implement feature X",
"description": "Complete implementation",
"due_meeting_id": 1
}'curl -X POST http://localhost:8000/notes/ \
-H "Content-Type: application/json" \
-d '{
"content": "This is a meeting note",
"meeting_id": 1
}'main.py- FastAPI application with stubbed endpointsmodels.py- SQLAlchemy database modelsschemas.py- Pydantic schemas for request/response validationdatabase.py- Database configuration and session managementrequirements.txt- Python dependencies
The current implementation has stubbed endpoints that return mock data. Database integration is prepared but not yet connected to the endpoints.