Skip to content

spo serviceprincipal grant revoke

Revokes the specified set of permissions granted to the service principal

Usage

spo serviceprincipal grant revoke [options]

Alias

spo sp grant revoke

Options

Option Description
--help output usage information
-i, --grantId <grantId> ObjectId of the permission grant to revoke
-o, --output [output] Output type. json|text. Default text
--verbose Runs command with verbose logging
--debug Runs command with debug logging

Important

To use this command you have to have permissions to access the tenant admin site.

Remarks

The permission grant you want to revoke is denoted using its ObjectId. You can retrieve it using the spo serviceprincipal grant list command.

Examples

Revoke permission grant with ObjectId 50NAzUm3C0K9B6p8ORLtIsQccg4rMERGvFGRtBsk2fA

spo serviceprincipal grant revoke --grantId 50NAzUm3C0K9B6p8ORLtIsQccg4rMERGvFGRtBsk2fA