Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add server URL to OpenAPI schema #16089

Open
abhi1693 opened this issue May 11, 2024 · 0 comments
Open

Add server URL to OpenAPI schema #16089

abhi1693 opened this issue May 11, 2024 · 0 comments
Labels
complexity: low Requires minimal effort to implement status: under review Further discussion is needed to determine this issue's scope and/or implementation type: feature Introduction of new functionality to the application

Comments

@abhi1693
Copy link
Member

NetBox version

v3.7.8

Feature type

Change to existing functionality

Proposed functionality

Incorporate the server's base URL into the OpenAPI schema by adding it to the 'servers' object. This modification will automate the configuration of the base URL for API clients. Specifically, this change should include:

  • Definition of a default server URL in the OpenAPI configuration.
  • Ensuring that this URL is referenced as the base path for all API calls within the NetBox API documentation and schema.
  • Providing flexibility for users to override the default URL if their deployment requires a different configuration.

This update will streamline the API client setup process by pre-defining the server URL, thereby eliminating the need for users to manually specify this setting during client configuration.

Use case

Adding the server URL to the 'servers' object in the OpenAPI schema enhances the utility of the NetBox API by explicitly defining the base URL for all API endpoints. This change addresses the issue where clients of the NetBox API need to manually configure the base URL, which can lead to errors and inconsistencies, especially in environments where NetBox instances are dynamically created and managed. By specifying the server URL in the schema, client applications can automatically adapt to changes in the server's location without requiring manual updates. This makes the API more robust and easier to integrate with, improving user experience and supporting more dynamic, cloud-based environments where the URL might change frequently.

Database changes

No response

External dependencies

No response

@abhi1693 abhi1693 added type: feature Introduction of new functionality to the application status: under review Further discussion is needed to determine this issue's scope and/or implementation labels May 11, 2024
@jeremystretch jeremystretch added the complexity: low Requires minimal effort to implement label May 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
complexity: low Requires minimal effort to implement status: under review Further discussion is needed to determine this issue's scope and/or implementation type: feature Introduction of new functionality to the application
Projects
None yet
Development

No branches or pull requests

2 participants