Skip to content

Commit

Permalink
update open api doc,
Browse files Browse the repository at this point in the history
API/parameters should be equal over http verbs
  • Loading branch information
zingmane committed Oct 11, 2023
1 parent 6ff3a5b commit 42f494c
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 44 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/main_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,6 @@ jobs:
path: artifacts

- name: Publish Unit Test Results
uses: EnricoMi/publish-unit-test-result-action@v1
uses: EnricoMi/publish-unit-test-result-action@v2
with:
files: artifacts/test-results/**/*.xml
65 changes: 22 additions & 43 deletions src/main/resources/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -1750,7 +1750,7 @@
}
}
},
"/tables/{tableId}/rows/{rowId}/permissions/{rowPermission}": {
"/tables/{tableId}/rows/{rowId}/permissions": {
"parameters": [
{
"$ref": "#/parameters/tableId"
Expand All @@ -1759,16 +1759,16 @@
"$ref": "#/parameters/rowId"
},
{
"$ref": "#/parameters/rowPermission"
"$ref": "#/parameters/rowPermissionBody"
}
],
"patch": {
"summary": "Add a permission to this row.",
"description": "Adds a new permission to this row.",
"summary": "Add permissions to this row.",
"description": "Add permissions to this row.",
"tags": [
"permission"
],
"operationId": "add-row-permission",
"operationId": "add-row-permissions",
"responses": {
"200": {
"$ref": "#/responses/ok-empty-body"
Expand All @@ -1779,12 +1779,12 @@
}
},
"delete": {
"summary": "Delete a permission of this row.",
"description": "Deletes a permission of this row.",
"summary": "Deletes permissions of this row.",
"description": "Deletes permissions of this row.",
"tags": [
"permission"
],
"operationId": "clear-row-permission",
"operationId": "remove-row-permissions",
"responses": {
"200": {
"$ref": "#/responses/ok-empty-body"
Expand All @@ -1793,41 +1793,14 @@
"$ref": "#/responses/not-found-in-database"
}
}
}
},
"/tables/{tableId}/rows/{rowId}/permissions": {
"parameters": [
{
"$ref": "#/parameters/tableId"
},
{
"$ref": "#/parameters/rowId"
}
],
},
"put": {
"summary": "Replace permissions of this row.",
"description": "Replace current permissions of this row. This overwrites all permissions of this row with the new provided permission array.",
"tags": [
"permission"
],
"operationId": "replace-row-permissions",
"parameters": [
{
"name": "value",
"in": "body",
"required": true,
"schema": {
"type": "array",
"items": {
"type": "string"
},
"example": [
"onlyUserGroupA",
"onlyUserGroupB"
]
}
}
],
"responses": {
"200": {
"$ref": "#/responses/ok-empty-body"
Expand Down Expand Up @@ -3847,14 +3820,20 @@
"format": "int64",
"required": false
},
"rowPermission": {
"name": "rowPermission",
"description": "A row permission.",
"in": "path",
"rowPermissionBody": {
"name": "value",
"description": "An array of row permission to add, remove or replace.",
"in": "body",
"required": true,
"type": "string",
"items": {
"$ref": "#/definitions/RowPermission"
"schema": {
"type": "array",
"items": {
"type": "string"
},
"example": [
"onlyUserGroupA",
"onlyUserGroupB"
]
}
}
},
Expand Down

0 comments on commit 42f494c

Please sign in to comment.