Skip to content

goserveGo REST API Framework

A robust framework for building efficient, reliable and scalable server-side applications

goserve mascot

Technology Stack โ€‹

goserve is built with industry-standard Go libraries:

  • Go 1.21+ - Modern, efficient programming language
  • Gin - Fast HTTP web framework
  • JWT (RS256) - Secure RSA-signed token-based authentication
  • pgx - PostgreSQL driver with connection pooling
  • MongoDB Driver - Official Go driver for MongoDB
  • go-redis - Redis client for caching and sessions
  • Validator - Request validation utilities
  • Viper - Configuration management
  • Crypto - Cryptographic utilities

Latest Version: v2.1.2

Why Choose goserve? โ€‹

  • โœ… Batteries Included: Everything you need for production REST APIs
  • โœ… Clean Architecture: Feature-based organization that scales
  • โœ… Easy Testing: Simplified patterns for unit and integration tests
  • โœ… Active Development: Regularly updated with latest Go best practices
  • โœ… Well Documented: Comprehensive examples and documentation
  • โœ… Open Source: Apache 2.0 licensed, free to use

๐Ÿ“š Documentation โ€‹

Getting Started โ€‹

Example Projects โ€‹

Learn by example with complete, production-ready implementations:

1. PostgreSQL Example โ€‹

Complete REST API with PostgreSQL, Redis, JWT authentication, role-based authorization, and comprehensive testing.

2. MongoDB Example โ€‹

Complete REST API with MongoDB, Redis, and JWT authentication.

3. Microservices (gomicro) โ€‹

Microservices architecture with Kong API gateway, NATS messaging, and Docker orchestration.

Quick Start โ€‹

Install goserve โ€‹

bash
go get github.com/afteracademy/goserve

Try the PostgreSQL Example โ€‹

The best way to get started is with the complete example project:

bash
git clone https://github.com/afteracademy/goserve-example-api-server-postgres.git
cd goserve-example-api-server-postgres
go run .tools/rsa/keygen.go && go run .tools/copy/envs.go
docker compose up --build -d
curl http://localhost:8080/health

See the PostgreSQL Example Documentation for detailed setup and usage.

Community & Resources โ€‹

License โ€‹

goserve is released under the Apache 2.0 License. See the LICENSE file for details.

Contributing โ€‹

Contributions are welcome! Please feel free to fork the repository and open a pull request. See the Contributing Guide for more details.


Find this project useful? โญ Star it on GitHub to show your support!

Released under the Apache 2.0 License