Skip to content

Add Swagger Documentation & API Logging#7

Open
Krishna-sm wants to merge 2 commits intocodersgyan:masterfrom
Krishna-sm:swagger-doc
Open

Add Swagger Documentation & API Logging#7
Krishna-sm wants to merge 2 commits intocodersgyan:masterfrom
Krishna-sm:swagger-doc

Conversation

@Krishna-sm
Copy link

Here’s a clean, professional, ready-to-paste PR description for your contribution.


🚀 PR: Add Swagger Documentation, Env Setup, API Logging & Air Dev Setup

🔧 Summary

This pull request introduces multiple improvements to the project’s development experience and API structure.

✅ What’s Added

  • Swagger API Documentation
    Added full Swagger setup to auto-generate interactive API docs.
image
  • Environment Variables Setup
    Introduced .env.example and environment variable loading system for better config management.
image
  • New ServeMux + API Logging Middleware
    Implemented a custom ServeMux along with structured API request/response logs.
image
  • Air Integration for Development
    Added Air config to enable live reload during development.
image

🎯 Why These Changes

  • Improves API discoverability
  • Standardizes config handling
  • Makes debugging easier
  • Speeds up local development workflow
  • Moves the project toward a cleaner, production-ready structure

📁 Files Updated

  • .air.toml
  • .env.example
  • main.go
  • Swagger docs & handlers
  • Logging middleware

📝 Notes

This PR does not change any existing API functionality — it only introduces tooling, structure, and developer-experience improvements.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant