From d802589cc6a84fbb9fb55c841936e1cea4d07f7f Mon Sep 17 00:00:00 2001 From: Xinyi Joffre Date: Fri, 11 Dec 2020 16:04:46 -0800 Subject: [PATCH] Add and remove owner for service principals --- .../stable/1.6/graphrbac.json | 86 +++++++++++++++++++ 1 file changed, 86 insertions(+) diff --git a/specification/graphrbac/data-plane/Microsoft.GraphRbac/stable/1.6/graphrbac.json b/specification/graphrbac/data-plane/Microsoft.GraphRbac/stable/1.6/graphrbac.json index 37e9a5185c2b..975f870575d1 100644 --- a/specification/graphrbac/data-plane/Microsoft.GraphRbac/stable/1.6/graphrbac.json +++ b/specification/graphrbac/data-plane/Microsoft.GraphRbac/stable/1.6/graphrbac.json @@ -1477,6 +1477,92 @@ } } }, + "/{tenantID}/servicePrincipals/{objectId}/$links/owners": { + "post": { + "tags": [ + "ServicePrincipalOwners" + ], + "operationId": "ServicePrincipals_AddOwner", + "description": "Add an owner to a service principal.", + "parameters": [ + { + "name": "objectId", + "in": "path", + "required": true, + "type": "string", + "description": "The object ID of the service principal to which to add the owner." + }, + { + "name": "parameters", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/AddOwnerParameters" + }, + "description": "The URL of the owner object, such as https://graph.windows.net/0b1f9851-1bf0-433f-aec3-cb9272f093dc/directoryObjects/f260bbc4-c254-447b-94cf-293b5ec434dd." + }, + { + "$ref": "#/parameters/ApiVersionParameter" + }, + { + "$ref": "#/parameters/tenantIDInPath" + } + ], + "responses": { + "204": { + "description": "No Content. Indicates success. No response body is returned." + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "#/definitions/GraphError" + } + } + } + } + }, + "/{tenantID}/servicePrincipals/{objectId}/$links/owners/{ownerObjectId}": { + "delete": { + "tags": [ + "ServicePrincipalOwners" + ], + "operationId": "ServicePrincipals_RemoveOwner", + "description": "Remove a member from owners.", + "parameters": [ + { + "name": "objectId", + "in": "path", + "required": true, + "type": "string", + "description": "The object ID of the service principal from which to remove the owner." + }, + { + "name": "ownerObjectId", + "in": "path", + "required": true, + "type": "string", + "description": "Owner object id" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + }, + { + "$ref": "#/parameters/tenantIDInPath" + } + ], + "responses": { + "204": { + "description": "No Content. Indicates success. No response body is returned." + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "#/definitions/GraphError" + } + } + } + } + }, "/{tenantID}/servicePrincipals/{objectId}/keyCredentials": { "get": { "tags": [