mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 14:01:15 +02:00
Add api versionning
This commit is contained in:
1 parent
119bebee25
commit
08158884a4
3 files changed
+5
-4
No files matched your search
@@ -84,7 +84,8 @@ class Route(object):
|
||||
# This block is executed only the first time
|
||||
output_schema = kw.get("output", {})
|
||||
input_schema = kw.get("input", {})
|
||||
cls._path = path
|
||||
api_version = kw.get("version", 1)
|
||||
cls._path = "/v{version}{path}".format(path=path, version=api_version)
|
||||
cls._documentation.setdefault(cls._path, {"methods": []})
|
||||
|
||||
def register(func):
|
||||
|
||||
Reference in new issue
Block a user