diff --git a/src/api/resources/openApi.json b/src/api/resources/openApi.json index e0f69ed49..220fd3c43 100644 --- a/src/api/resources/openApi.json +++ b/src/api/resources/openApi.json @@ -475,16 +475,14 @@ "type": { "type": "string", "description": "Source type of map data.", - "enum": ["tilejson", "wms", "wmts"], - "default": "wms", - "example": "wms" + "enum": ["tilejson", "WMS", "WMTS", "mapboxstyle", "S-57"], + "example": "WMTS" } } }, "Chart": { "description": "Signal K Chart resource", "type": "object", - "required": ["identifier"], "properties": { "identifier": { "type": "string", @@ -1399,6 +1397,29 @@ } } } + }, + "post": { + "tags": ["charts"], + "summary": "Add a new Chart source", + "requestBody": { + "description": "Chart resource entry", + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Chart" + } + } + } + }, + "responses": { + "200": { + "$ref": "#/components/responses/200ActionResponse" + }, + "default": { + "$ref": "#/components/responses/ErrorResponse" + } + } } }, "/resources/charts/{id}": { @@ -1418,7 +1439,7 @@ ], "get": { "tags": ["charts"], - "summary": "Retrieve chart with supplied id", + "summary": "Retrieve chart metadata for the supplied id", "responses": { "200": { "$ref": "#/components/responses/ChartResponse" @@ -1430,7 +1451,7 @@ }, "put": { "tags": ["charts"], - "summary": "Add / update a new Chart with supplied id", + "summary": "Add / update a new Chart source with supplied id", "requestBody": { "description": "Chart resource entry", "required": true, @@ -1450,6 +1471,18 @@ "$ref": "#/components/responses/ErrorResponse" } } + }, + "delete": { + "tags": ["charts"], + "summary": "Remove Chart source with supplied id", + "responses": { + "200": { + "$ref": "#/components/responses/200ActionResponse" + }, + "default": { + "$ref": "#/components/responses/ErrorResponse" + } + } } } }