Skip to content

Conversation

@meysam
Copy link

@meysam meysam commented Mar 11, 2024

Overview

This PR integrates Swagger into our project to significantly enhance our API documentation and testing capabilities. It aims to provide a more comprehensive and accessible way for developers to understand and interact with our API.

Key Changes

  • Swagger Integration: We've introduced Swagger to generate interactive API documentation. This includes configuring Swagger to create an XML comment file, which offers detailed insights into our API endpoints.
  • Update to BaseController Access Levels: To ensure better encapsulation and cleaner code structure, access levels for certain methods within the BaseController class have been changed from public to protected. This adjustment aligns with best practices for method visibility. The changes in method access levels have been specifically designed to enhance method management within Swagger.

meysam added 6 commits March 11, 2024 11:45
The target framework of the 'AuthorizationServer' project has been updated from 'netcoreapp2.0' to 'net8.0'. As a part of this update, several unnecessary package references have been removed and the 'Authlete.Authlete' package has been upgraded to version '1.5.0'. Additionally, 'ImplicitUsings' and 'Nullable' were also enabled.
The commit introduces Microsoft.Extensions.Hosting library into the AuthorizationServer's Startup.cs. It also replaces services.AddMvc().AddWebApiConventions() with services.AddControllers() and modifies the Configure method to accommodate these changes. Lastly, it updates the application's routing to use app.UseRouting() and configures endpoints specifically for controllers.
…vels

This commit introduces Swagger to enhance the API documentation and testing capabilities of the project. It also configures the generation of an XML comment file, offering detailed insights into the API endpoints. The Swagger UI is now accessible from the application's root URL. Additionally, access levels for certain methods within the BaseController class have been changed from public to protected to improve encapsulation. This adjustment ensures better method management in Swagger, allowing protected methods to be handled appropriately without requiring REST attributes.
…onventions` method, previously added by `WebApiCompatShim`, has been removed.
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.

2 participants