Skip to content

Commit

Permalink
[Synapse] - Add missing API version parameter (Azure#11751)
Browse files Browse the repository at this point in the history
* [Synapse] - Add missing API version parameter and pageable

* Fix lint

* Fix recent found issues

* Fix lint error

* Fix model validation errors

* Remove x-ms-pageable

* Rename Action to RequiredAction

* Revert x-ms-pageable and AccessDecisions

* Update description for AccessDecisions

* Update checkAccessSynapseRbac.json

Slight wording fix

Co-authored-by: Dongwei Wang <dongwwa@microsoft.com>
Co-authored-by: Jonathan Turner <jonathandturner@users.noreply.github.com>
  • Loading branch information
3 people authored and giromm2ms committed Dec 20, 2020
1 parent 1909492 commit 1a81dfb
Show file tree
Hide file tree
Showing 4 changed files with 43 additions and 29 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"tags": [
"CheckPrincipalAccess"
],
"operationId": "CheckPrincipalAccess",
"operationId": "RoleAssignments_CheckPrincipalAccess",
"description": "Check if the given principalId has access to perform list of actions at a given scope.",
"x-ms-examples": {
"Check access": {
Expand Down Expand Up @@ -141,7 +141,7 @@
"description": "List of actions.",
"type": "array",
"items": {
"$ref": "#/definitions/Action"
"$ref": "#/definitions/RequiredAction"
}
},
"scope": {
Expand All @@ -150,7 +150,7 @@
}
}
},
"Action": {
"RequiredAction": {
"description": "Action Info",
"type": "object",
"required": [
Expand All @@ -170,9 +170,15 @@
},
"CheckPrincipalAccessResponse": {
"description": "Check access response details",
"type": "array",
"items": {
"$ref": "#/definitions/CheckAccessDecision"
"type": "object",
"properties": {
"AccessDecisions": {
"description": "To check if the current user, group, or service principal has permission to read artifacts in the specified workspace.",
"type": "array",
"items": {
"$ref": "#/definitions/CheckAccessDecision"
}
}
}
},
"SubjectInfo": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,30 +25,32 @@
},
"responses": {
"200": {
"body": [
{
"accessDecision": "Allowed || NotAllowed",
"actionId": "Action 1",
"roleAssignment": {
"id": "00000000-0000-0000-0000-000000000000",
"roleDefinitionId": "00000000-0000-0000-0000-000000000000",
"principalId": "00000000-0000-0000-0000-000000000000",
"scope": "workspaces/exampleWorkspace",
"principalType": "User || Group || ServicePrincipal"
}
},
{
"accessDecision": "Allowed || NotAllowed",
"actionId": "Action 1",
"roleAssignment": {
"id": "00000000-0000-0000-0000-000000000000",
"roleDefinitionId": "00000000-0000-0000-0000-000000000000",
"principalId": "00000000-0000-0000-0000-000000000000",
"scope": "workspaces/exampleWorkspace",
"principalType": "User || Group || ServicePrincipal"
"body": {
"accessDecisions": [
{
"accessDecision": "Allowed || NotAllowed",
"actionId": "Action 1",
"roleAssignment": {
"id": "00000000-0000-0000-0000-000000000000",
"roleDefinitionId": "00000000-0000-0000-0000-000000000000",
"principalId": "00000000-0000-0000-0000-000000000000",
"scope": "workspaces/exampleWorkspace",
"principalType": "User || Group || ServicePrincipal"
}
},
{
"accessDecision": "Allowed || NotAllowed",
"actionId": "Action 1",
"roleAssignment": {
"id": "00000000-0000-0000-0000-000000000000",
"roleDefinitionId": "00000000-0000-0000-0000-000000000000",
"principalId": "00000000-0000-0000-0000-000000000000",
"scope": "workspaces/exampleWorkspace",
"principalType": "User || Group || ServicePrincipal"
}
}
}
]
]
}
},
"default": {
"body": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,9 @@
},
{
"$ref": "#/parameters/RoleAssignmentIdParameter"
},
{
"$ref": "#/parameters/ScopeParameter"
}
],
"responses": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,9 @@
"text/json"
],
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/RoleDefinitionIdParameter"
}
Expand Down

0 comments on commit 1a81dfb

Please sign in to comment.