Name collision for /version endpoint
See original GitHub issueAnother small issue I encountered: It is currently not possible to have a /version
endpoint, because of a name collision with the internal version
variable. For example:
---
openapi: 3.0.0
info:
title: SomeAPI
paths:
"/version":
get:
responses:
'200':
description:
content:
application/json:
schema:
type: string
Relevant parts of generated code:
export class Api<SecurityDataType> {
public baseUrl = "";
public title = "SomeAPI";
public version = "";
// and later
version = {
/**
* @name versionList
* @request GET:/version
*/
versionList: (params?: RequestParams) => this.request<string, any>(`/version`, "GET", params, null),
};
Error:
Duplicate identifier 'version'.ts(2300)
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (4 by maintainers)
Top Results From Across the Web
Name Collision in the DNS - icann
The potential for name collision with proposed new gTLDs is substantial. ... there is no policy-mandated endpoint for risks resulting from.
Read more >REST API: endpoint name conflicts and prefixes / namespaces ...
To change the endpoint name: /api/1/users /api/1/groups /api/1/items /api/1/item_groups. To modify path by adding some prefix or namespace ...
Read more >When domain names attack: the WPAD name collision ...
Poorly configured networks and new rules on internet domain names are giving cybercriminals a powerful new attack tool.
Read more >Conflict Detection and Sync - AWS AppSync
In this scenario, a conflict will be detected due to the version mismatch. Automerge adheres to its properties and rejects the name change...
Read more >Rename Endpoint - Interface Refactoring Catalog
Instructions (Steps) · Discuss alternative new names and decide for one. · Apply code-level rename refactorings, for instance for the controller ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Works perfectly, thanks!
Should be fixed in release 1.7.0