diff options
author | Gabor Somogyi <Gabor_Somogyi@epam.com> | 2016-05-04 14:36:18 +0200 |
---|---|---|
committer | Gabor Somogyi <Gabor_Somogyi@epam.com> | 2016-05-04 14:39:03 +0200 |
commit | 516ef6a30eb59e1b9c3aa297e3595c5acf665530 (patch) | |
tree | 2bed5e621be4786816bbf3d6adabe41d2d43fbdb /swagger.json | |
parent | 5bf82eff1ecac7b23661cea14be26aa7a3e4d09a (diff) | |
parent | 59f466092c9c875c2bbcb70a2a402aad0edd7639 (diff) | |
download | trackermap-server-516ef6a30eb59e1b9c3aa297e3595c5acf665530.tar.gz trackermap-server-516ef6a30eb59e1b9c3aa297e3595c5acf665530.tar.bz2 trackermap-server-516ef6a30eb59e1b9c3aa297e3595c5acf665530.zip |
Merge branch 'master' into command_framework
Diffstat (limited to 'swagger.json')
-rw-r--r-- | swagger.json | 225 |
1 files changed, 209 insertions, 16 deletions
diff --git a/swagger.json b/swagger.json index f8269a2da..12b5020c7 100644 --- a/swagger.json +++ b/swagger.json @@ -1,7 +1,7 @@ { "swagger": "2.0", "info": { - "version": "3.3", + "version": "3.5", "title": "traccar" }, "host": "traccar.org", @@ -159,7 +159,180 @@ } } }, - "/permissions": { + "/groups": { + "get": { + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "all", + "in": "query", + "required": true, + "type": "boolean" + }, + { + "name": "userId", + "in": "query", + "required": true, + "type": "integer" + } + ], + "responses": { + "200": { + "description": "OK", + "headers": {}, + "schema": { + "type": "array", + "items": { + "$ref": "#/definitions/Group" + } + } + } + } + }, + "post": { + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/Group" + } + } + ], + "responses": { + "200": { + "description": "OK", + "headers": {}, + "schema": { + "$ref": "#/definitions/Group" + } + } + } + } + }, + "/groups/{id}": { + "put": { + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "id", + "in": "path", + "required": true, + "type": "integer" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/Group" + } + } + ], + "responses": { + "200": { + "description": "OK", + "headers": {}, + "schema": { + "$ref": "#/definitions/Group" + } + } + } + }, + "delete": { + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "id", + "in": "path", + "required": true, + "type": "integer" + } + ], + "responses": { + "204": { + "description": "No Content", + "headers": {} + } + } + } + }, + "/permissions/devices": { + "post": { + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/DevicePermission" + } + } + ], + "responses": { + "200": { + "description": "OK", + "headers": {}, + "schema": { + "$ref": "#/definitions/DevicePermission" + } + } + } + }, + "delete": { + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/DevicePermission" + } + } + ], + "responses": { + "204": { + "description": "No Content", + "headers": {} + } + } + } + }, + "/permissions/groups": { "post": { "consumes": [ "application/json" @@ -173,7 +346,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/Permission" + "$ref": "#/definitions/GroupPermission" } } ], @@ -182,7 +355,7 @@ "description": "OK", "headers": {}, "schema": { - "$ref": "#/definitions/Permission" + "$ref": "#/definitions/GroupPermission" } } } @@ -200,7 +373,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/Permission" + "$ref": "#/definitions/GroupPermission" } } ], @@ -556,13 +729,7 @@ "password": { "type": "string" }, - "hashedPassword": { - "type": "string" - }, - "salt": { - "type": "string" - }, - "passwordValid": { + "twelveHourFormat": { "type": "boolean" } } @@ -587,9 +754,6 @@ "mapUrl": { "type": "string" }, - "language": { - "type": "string" - }, "distanceUnit": { "type": "string" }, @@ -604,6 +768,9 @@ }, "zoom": { "type": "number" + }, + "twelveHourFormat": { + "type": "boolean" } } }, @@ -629,10 +796,26 @@ }, "positionId": { "type": "number" + }, + "groupId": { + "type": "number" + } + } + }, + "Group": { + "properties": { + "id": { + "type": "number" + }, + "name": { + "type": "string" + }, + "groupId": { + "type": "number" } } }, - "Permission": { + "DevicePermission": { "properties": { "userId": { "type": "number" @@ -641,6 +824,16 @@ "type": "number" } } + }, + "GroupPermission": { + "properties": { + "userId": { + "type": "number" + }, + "groupId": { + "type": "number" + } + } } } } |