Skip to content

worked - #656

Merged
Smartdevs17 merged 1 commit into
Smartdevs17:mainfrom
bytebenders1:wilfred
Jul 28, 2026
Merged

worked#656
Smartdevs17 merged 1 commit into
Smartdevs17:mainfrom
bytebenders1:wilfred

Conversation

@Wilfred007

Copy link
Copy Markdown
Contributor

What this PR does

Implementation Summary

  1. TSOA Configuration
    Installed tsoa and @tsoa/runtime for decorator-based OpenAPI generation
    Configured tsoa.json for OpenAPI 3.1 spec generation with controller path globs
    Updated tsconfig.json with experimentalDecorators and emitDecoratorMetadata
  2. Controller Classes
    Created HealthController (src/controllers/health.controller.ts) with TSOA decorators
    Created GasController (src/controllers/gas.controller.ts) with comprehensive gas estimation endpoints
    Both controllers use proper TypeScript types and return types for automatic schema generation
  3. OpenAPI Spec Generation
    Updated package.json with tsoa spec command for OpenAPI generation
    Successfully generates OpenAPI 3.1 spec to docs/api/openapi/swagger.json
    Spec includes security schemes, tags, and proper response schemas
  4. Swagger UI Integration
    Installed swagger-ui-express and type definitions
    Created swaggerRouter (src/routes/swagger.ts) with:
    Interactive Swagger UI at /swagger
    Raw JSON spec at /swagger/swagger.json
    YAML export at /swagger/swagger.yaml
    Custom styling and authentication configuration
    Integrated into main application at /swagger route
  5. API Versioning Strategy
    Existing URL-based versioning (/api/v1) already implemented
    Header-based versioning support via versionMiddleware
    Version detection from multiple headers: API-Version, X-API-Version, Accept-Version
  6. SDK Generation Configuration
    Installed @openapitools/openapi-generator-cli
    Created openapi-generator.config.json with configurations for:
    TypeScript (axios)
    Python
    Go
    Updated npm scripts for multi-language SDK generation
  7. CI/CD Workflow
    Created .github/workflows/sdk-generation.yml with:
    OpenAPI spec generation job
    Breaking change detection using oasdiff
    Multi-language SDK generation (TypeScript, Python, Go)
    Automated npm publishing for TypeScript SDK
    API changelog generation
    PR comments for breaking changes
  8. Breaking Change Detection
    Integrated oasdiff for automated breaking change detection
    Compares new OpenAPI spec against previous version
    Posts comments on PRs when breaking changes are detected
  9. API Changelog
    Integrated conventional-changelog-cli for automated changelog generation
    Runs as part of CI workflow
    Available Commands
    bash

Generate OpenAPI spec

npm run openapi:generate

Generate SDKs

npm run sdk:generate # TypeScript
npm run sdk:generate:python # Python
npm run sdk:generate:go # Go
Access Points
Swagger UI: http://localhost:3001/swagger
OpenAPI Spec: http://localhost:3001/swagger/swagger.json
API Endpoints: http://localhost:3001/api/v1

Changes

  • List of notable files and modules touched (monorepo wiring, Sentry integration, dashboards, etc.)
  • Notes about the Turborepo configuration, shared packages, and ESLint/TS config

Why

  • Rationale for the changes and how they solve the Acceptance Criteria

How to test

  • Steps to reproduce locally, including commands to run build/test
  • Any environment variables needed (e.g., SENTRY_DSN)
  • How to verify the dashboards/alerts configuration (stubs or real)

Notes

@vercel

vercel Bot commented Jul 28, 2026

Copy link
Copy Markdown

Someone is attempting to deploy a commit to the smartdevs17's projects Team on Vercel.

A member of the Team first needs to authorize it.

@drips-wave

drips-wave Bot commented Jul 28, 2026

Copy link
Copy Markdown

@Wilfred007 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@Smartdevs17
Smartdevs17 merged commit 12444a3 into Smartdevs17:main Jul 28, 2026
6 of 9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment