Skip to content

Bregann/Orbit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

170 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Orbit

A comprehensive personal finance management application built with .NET and Next.js

Orbit is a full-stack finance tracker that helps you manage transactions, budgets, savings, and gain deep insights into your spending habits through powerful analytics and visualizations.


✨ Features

πŸ’° Finance Management

  • Open Banking Integration: Automatic transaction imports via GoCardless and Monzo APIs
  • Transaction Management: Categorize and organize all your spending
  • Budget Pots: Create customizable spending categories with limits
  • Savings Pots: Set and track savings goals with progress monitoring
  • Subscription Tracking: Monitor recurring payments and billing cycles
  • Historic Analytics: Detailed spending analysis with 12-month trends

πŸ“Š Analytics & Insights

  • Monthly spending breakdowns by category
  • Top merchants and transaction analysis
  • Daily spending patterns
  • Year-on-year comparisons
  • Interactive charts and visualizations

πŸ“ Productivity Suite

  • Journal: Daily entries with mood tracking
  • Notes: Rich text editor with folder organization
  • Tasks: Todo management with priorities and categories
  • Calendar: Event scheduling with recurring event support
  • Shopping Lists: Organize shopping with quick-add common items

πŸ“„ Document Management

  • Upload and categorize important documents
  • Full-text search capabilities
  • Secure storage and retrieval

πŸ—οΈ Architecture

Tech Stack

Backend (Orbit.Core & Orbit.Domain)

  • Framework: .NET 10
  • Language: C# 13
  • Database: PostgreSQL (production) / SQLite (development)
  • ORM: Entity Framework Core 10
  • API: RESTful with JWT authentication
  • Background Jobs: Hangfire for scheduled tasks
  • Logging: Serilog with Seq integration

Frontend (orbit.web)

  • Framework: Next.js 16 (App Router)
  • Language: TypeScript
  • UI Library: Mantine v8
  • State: TanStack Query (React Query)
  • Charts: Recharts via Mantine Charts

πŸ“ Project Structure

Orbit/
β”œβ”€β”€ .github/workflows/           # CI/CD pipelines
β”œβ”€β”€ Orbit.Core/                  # API Layer
β”‚   β”œβ”€β”€ Controllers/             # API endpoints
β”‚   β”‚   β”œβ”€β”€ AuthController.cs
β”‚   β”‚   β”œβ”€β”€ TransactionsController.cs
β”‚   β”‚   β”œβ”€β”€ PotsController.cs
β”‚   β”‚   β”œβ”€β”€ HistoricMonthController.cs
β”‚   β”‚   β”œβ”€β”€ CalendarController.cs
β”‚   β”‚   β”œβ”€β”€ DocumentsController.cs
β”‚   β”‚   β”œβ”€β”€ JournalController.cs
β”‚   β”‚   β”œβ”€β”€ NotesController.cs
β”‚   β”‚   β”œβ”€β”€ ShoppingController.cs
β”‚   β”‚   └── TasksController.cs
β”‚   β”œβ”€β”€ Properties/
β”‚   β”œβ”€β”€ Program.cs               # Application entry point
β”‚   β”œβ”€β”€ appsettings.json         # Configuration
β”‚   └── Dockerfile
β”‚
β”œβ”€β”€ Orbit.Domain/                # Business Logic Layer
β”‚   β”œβ”€β”€ Database/
β”‚   β”‚   β”œβ”€β”€ Context/
β”‚   β”‚   β”‚   └── AppDbContext.cs  # EF Core DbContext
β”‚   β”‚   β”œβ”€β”€ Migrations/          # Database migrations
β”‚   β”‚   └── Models/              # Entity models
β”‚   β”‚       β”œβ”€β”€ Transactions.cs
β”‚   β”‚       β”œβ”€β”€ SpendingPot.cs
β”‚   β”‚       β”œβ”€β”€ SavingsPot.cs
β”‚   β”‚       β”œβ”€β”€ HistoricData.cs
β”‚   β”‚       β”œβ”€β”€ CalendarEvent.cs
β”‚   β”‚       β”œβ”€β”€ Document.cs
β”‚   β”‚       β”œβ”€β”€ JournalEntry.cs
β”‚   β”‚       β”œβ”€β”€ NotePage.cs
β”‚   β”‚       β”œβ”€β”€ ShoppingListItem.cs
β”‚   β”‚       └── TaskItem.cs
β”‚   β”‚
β”‚   β”œβ”€β”€ DTOs/                    # Data Transfer Objects
β”‚   β”‚   β”œβ”€β”€ Auth/
β”‚   β”‚   β”œβ”€β”€ Calendar/
β”‚   β”‚   β”œβ”€β”€ Documents/
β”‚   β”‚   β”œβ”€β”€ Finance/
β”‚   β”‚   β”‚   β”œβ”€β”€ HistoricData/
β”‚   β”‚   β”‚   β”œβ”€β”€ Pots/
β”‚   β”‚   β”‚   β”œβ”€β”€ Subscriptions/
β”‚   β”‚   β”‚   └── Transactions/
β”‚   β”‚   β”œβ”€β”€ Journal/
β”‚   β”‚   β”œβ”€β”€ Notes/
β”‚   β”‚   β”œβ”€β”€ Shopping/
β”‚   β”‚   └── Tasks/
β”‚   β”‚
β”‚   β”œβ”€β”€ Services/                # Business logic implementation
β”‚   β”‚   β”œβ”€β”€ AuthService.cs
β”‚   β”‚   β”œβ”€β”€ Finance/
β”‚   β”‚   β”‚   β”œβ”€β”€ TransactionsService.cs
β”‚   β”‚   β”‚   β”œβ”€β”€ PotsService.cs
β”‚   β”‚   β”‚   β”œβ”€β”€ SubscriptionsService.cs
β”‚   β”‚   β”‚   β”œβ”€β”€ HistoricDataService.cs
β”‚   β”‚   β”‚   └── MonthService.cs
β”‚   β”‚   β”œβ”€β”€ Calendar/
β”‚   β”‚   β”‚   └── CalendarService.cs
β”‚   β”‚   β”œβ”€β”€ Documents/
β”‚   β”‚   β”‚   └── DocumentsService.cs
β”‚   β”‚   β”œβ”€β”€ Journal/
β”‚   β”‚   β”‚   └── JournalService.cs
β”‚   β”‚   β”œβ”€β”€ Notes/
β”‚   β”‚   β”‚   └── NotesService.cs
β”‚   β”‚   β”œβ”€β”€ Shopping/
β”‚   β”‚   β”‚   └── ShoppingService.cs
β”‚   β”‚   └── Tasks/
β”‚   β”‚       └── TasksService.cs
β”‚   β”‚
β”‚   β”œβ”€β”€ Interfaces/              # Service contracts
β”‚   β”‚   └── Api/                 # API service interfaces
β”‚   β”‚
β”‚   β”œβ”€β”€ Helpers/                 # Utility classes
β”‚   β”‚   β”œβ”€β”€ BankApiHelper.cs     # Bank API integration
β”‚   β”‚   β”œβ”€β”€ CommsSenderClient.cs # Email/notifications
β”‚   β”‚   β”œβ”€β”€ DatabaseSeedHelper.cs
β”‚   β”‚   β”œβ”€β”€ EnvironmentalSettingHelper.cs
β”‚   β”‚   β”œβ”€β”€ HangfireJobSetup.cs
β”‚   β”‚   └── UserContextHelper.cs
β”‚   β”‚
β”‚   └── Enums/                   # Shared enumerations
β”‚
β”œβ”€β”€ orbit.web/                   # Frontend Next.js application
β”‚   └── (See orbit.web/README.md for details)
β”‚
└── Orbit.sln                    # Solution file

πŸš€ Getting Started

Prerequisites

  • .NET 10 SDK or later
  • Node.js 20 or later
  • PostgreSQL 15+ (for production)
  • Docker

Database Providers

  • Development: TestContainers (Docker required)
  • Production: PostgreSQL (scalable, production-ready)

The provider is automatically selected based on the environment.

πŸ” Authentication

JWT-based authentication with the following endpoints:

  • POST /api/Auth/Login - Authenticate user
  • POST /api/Auth/Register - Create new account
  • POST /api/Auth/RefreshToken - Refresh access token

All API endpoints (except auth) require a valid JWT token in the Authorization header:

Authorization: Bearer <token>

πŸ“‘ API Documentation

Key Endpoints

Finance

  • GET /api/Transactions/GetTransactionsForMonth - Monthly transactions
  • GET /api/Pots/GetAllPotData - Budget and savings pots
  • GET /api/HistoricMonth/GetHistoricMonthData - Historic analytics
  • GET /api/Subscriptions/GetSubscriptions - Recurring payments

Productivity

  • GET /api/Tasks/GetTasks - Task list
  • GET /api/Calendar/GetCalendarEvents - Calendar events
  • GET /api/Journal/GetJournalEntries - Journal entries
  • GET /api/Notes/GetNotePagesAndFolders - Notes structure
  • GET /api/Shopping/GetShoppingListItems - Shopping list

Documents

  • GET /api/Documents/GetAllDocuments - Document list
  • POST /api/Documents/UploadDocument - Upload file
  • GET /api/Documents/DownloadDocument - Download file

Swagger Documentation: Available at /swagger in development mode


πŸ”„ Background Jobs (Hangfire)

Automated tasks running on schedules:

  • Bank Sync: Hourly transaction imports from connected banks
  • Subscription Processing: Daily check for due subscriptions
  • Data Archival: Monthly historic data generation
  • Cleanup: Regular maintenance tasks

Hangfire Dashboard: Available at /hangfire (requires authentication)


πŸ›οΈ Architecture Patterns

Clean Architecture

  • Orbit.Core: Presentation layer (Controllers, API)
  • Orbit.Domain: Business logic, data access, services
  • Separation of Concerns: Clear boundaries between layers

Design Patterns Used

  • Service Layer Pattern: Business logic encapsulation in dedicated service classes
  • Dependency Injection: Constructor injection for loose coupling and testability
  • DTO Pattern: Data transfer objects for API communication
  • Direct DbContext Access: Services directly use EF Core DbContext (no repository abstraction)
  • Interface Segregation: Service interfaces define contracts for each domain area

Database Design

  • Normalized Schema: Minimize data redundancy
  • Foreign Keys: Referential integrity
  • Indexes: Optimized query performance
  • Soft Deletes: Data recovery capability (where applicable)

πŸ§ͺ Testing

To be added

πŸ“Š Logging & Monitoring

Serilog Configuration

Logs are written to:

  • Console: For development debugging
  • File: Rolling daily logs in /app/Logs/
  • Seq: Centralized log aggregation (optional)

Log Levels

  • Information: Normal operations
  • Warning: Potential issues
  • Error: Handled exceptions
  • Critical: Unhandled exceptions, system failures

🀝 Contributing

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/amazing-feature
  3. Commit changes: git commit -m 'Add amazing feature'
  4. Push to branch: git push origin feature/amazing-feature
  5. Open a Pull Request

Coding Standards

  • Follow C# coding conventions
  • Use meaningful variable and method names
  • Keep methods focused and concise

πŸ”— Resources


Built with ❀️ using .NET and Next.js

About

Life tracker for managing finances, to do lists, shopping lists, document storage, journaling and notes

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages