Skip to content

diangogav/evolution-api

Repository files navigation

Evolution API

Bun ElysiaJS PostgreSQL TypeORM

The official backend API for the Evolution Yu-Gi-Oh! platform.

About

Evolution API is a high-performance backend built with Bun and ElysiaJS, serving as the core infrastructure for the Evolution competitive Yu-Gi-Oh! platform. It manages tournaments, player rankings, ban lists, and detailed match statistics to provide a seamless experience for players and organizers.

Key Features

  • 🏆 Tournament Management: Create, manage, and track competitive tournaments with automated bracket generation.
  • 📊 Real-time Leaderboards: Dynamic ranking systems based on match performance.
  • 🚫 Ban List Management: Maintain and enforce custom card ban lists for different formats.
  • 📈 Comprehensive Scatistics: Detailed player stats, match history, and performance analytics.
  • 🎁 Season Wrapped: Generate personalized season summaries for players.
  • 🔒 Secure Authentication: Robust JWT-based authentication for user accounts.

Tech Stack

  • Runtime: Bun - Fast all-in-one JavaScript runtime.
  • Framework: ElysiaJS - Ergonomic web framework for Bun.
  • Database: PostgreSQL - Powerful open-source relational database.
  • ORM: TypeORM - Data mapping for TypeScript.
  • Validation: TypeBox (integrated with Elysia).

Architecture

This project follows Hexagonal Architecture (Ports and Adapters) and Domain-Driven Design (DDD) principles to ensure scalability, maintainability, and testability.

  • Domain Layer: Contains the core business logic, entities, and value objects.
  • Application Layer: Orchestrates use cases and application flow.
  • Infrastructure Layer: Handles external concerns like database access, API routes, and third-party services.

Note

For a detailed breakdown of our architectural patterns and available development skills, please refer to AGENTS.md.

Getting Started

Prerequisites

  • Bun (v1.0.0 or later)
  • Docker (optional, for containerized database)

Installation

  1. Clone the repository:

    git clone https://github.com/diangogav/evolution-api.git
    cd evolution-api
  2. Install dependencies:

    bun install
  3. Environment Setup: Copy the example environment file and configure it:

    cp .env.example .env

    Update the .env file with your database credentials and other configuration settings.

Running the Application

Development Mode:

bun run dev

Production Build:

bun run build
bun start

API Documentation

The API documentation is automatically generated using Swagger.

  1. Start the server (bun run dev).
  2. Navigate to http://localhost:3000/swagger in your browser.

Contributing

We welcome contributions! Please check our AGENTS.md for coding standards and architectural guidelines before submitting a Pull Request.

License

This project is licensed under the MIT License.

About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages