From 4ab66ababad12b2972a31fb947d1675617ab10f2 Mon Sep 17 00:00:00 2001 From: Guilhem Bonnefille Date: Tue, 28 Jul 2020 23:17:44 +0200 Subject: [PATCH] Add get_version endpoint --- openkarotz-openapi.json | 41 ++++++++++++++++++++++++++++++++++++++++- 1 file changed, 40 insertions(+), 1 deletion(-) diff --git a/openkarotz-openapi.json b/openkarotz-openapi.json index a7d3273..fb5b90c 100644 --- a/openkarotz-openapi.json +++ b/openkarotz-openapi.json @@ -100,6 +100,45 @@ } } } + }, + "/cgi-bin/get_version": { + "summary": "get_version", + "description": "Renvoi les versions des différents composants", + "get": { + "summary": "get version", + "responses": { + "200": { + "description": "Renvoi les versions des différents composants", + "content": { + "application/json": { + "schema":{ + "type": "object", + "title": "versions", + "properties": { + "version" : { + "type": "string", + "description": "version des scripts installée." + }, + "rootfs_version" : { + "type": "string", + "description": "version du firmware" + }, + "patch_version" : { + "type": "string", + "description": "version des patchs installés" + }, + "serial" : { + "type": "string", + "description": "Numéro de série du lapin (Unique)" + } + } + }, + "example":{"version":"210","rootfs_version":"2.0.r8","patch_version":"213","serial":"61xxxxxxxxx8926xxxxxxxxxx016","return":"0"} + } + } + } + } + } } } -} \ No newline at end of file +}