TestPrivaTest.AccessControl.Cli.Commands
1.0.0
dotnet add package TestPrivaTest.AccessControl.Cli.Commands --version 1.0.0
NuGet\Install-Package TestPrivaTest.AccessControl.Cli.Commands -Version 1.0.0
<PackageReference Include="TestPrivaTest.AccessControl.Cli.Commands" Version="1.0.0" />
<PackageVersion Include="TestPrivaTest.AccessControl.Cli.Commands" Version="1.0.0" />
<PackageReference Include="TestPrivaTest.AccessControl.Cli.Commands" />
paket add TestPrivaTest.AccessControl.Cli.Commands --version 1.0.0
#r "nuget: TestPrivaTest.AccessControl.Cli.Commands, 1.0.0"
#:package TestPrivaTest.AccessControl.Cli.Commands@1.0.0
#addin nuget:?package=TestPrivaTest.AccessControl.Cli.Commands&version=1.0.0
#tool nuget:?package=TestPrivaTest.AccessControl.Cli.Commands&version=1.0.0
Priva.AccessControl.Cli.Commands
CLI extension package providing access control management commands for the Priva platform. This package integrates with the Priva CLI to enable remote management of users, clients, and roles through API calls.
Purpose & Scope
The CLI commands package enables:
- User Management: List users, manage admin accounts, and change account types
- Client Management: Create, update, delete, and manage OAuth2/OIDC client applications
- Role Management: Create roles, manage permissions, and link features to roles
- Administrative Operations: Bulk operations and system maintenance via remote API
Installation
This package provides a CLI extension for the Priva CLI platform.
Getting the Priva CLI
Download from Priva CDN:
# Windows (requires .NET 8.0 runtime)
curl https://privadevcdn.blob.core.windows.net/downloads/privacli/latest/priva.exe -o priva.exe
Installing the Extension
priva login
priva extensions add --name Priva.AccessControl.Cli.Commands
Prerequisites
- Priva CLI: Download and setup the Priva CLI executable
- Authentication: Login with
priva loginusing your My Priva credentials - Permissions: Appropriate access control permissions for user, client, and role management
Environment Configuration
By default, commands run against production. To target other environments:
priva global-config set -k Environment -v Integration # Available: Test, Integration, Production, Local
Available Commands
User Commands
priva access-control user list- List all users in the current tenantpriva access-control user retrieve-admin-emails- Retrieve admin email addresses of tenants with access to a featurepriva access-control user change-account-type- Change a user's account type
Client Commands
priva access-control client create- Create a new OAuth2/OIDC client applicationpriva access-control client list- List all registered client applicationspriva access-control client delete- Remove a client applicationpriva access-control client refresh-secret- Generate new client secretpriva access-control client update-permissions- Update client permissions
Role Commands
priva access-control role add(alias:create) - Create a new rolepriva access-control role delete(alias:remove) - Remove a rolepriva access-control role link-features- Link features to a role
All commands support --help for detailed syntax and options.
Command Examples
User Management
# List all users
priva access-control user list
# Retrieve admin emails for a specific feature
priva access-control user retrieve-admin-emails --feature "feature-name"
# Change user account type (requires user-id, email, and account type)
priva access-control user change-account-type --user-id "12345678-1234-1234-1234-123456789abc" --email "user@example.com" --type 1
Client Management
# Create a new client
priva access-control client create --name "MyApplication"
# Create client with permissions and assets
priva access-control client create --name "MyApp" --permissions "read write" --assets "12345678-1234-1234-1234-123456789abc 87654321-4321-4321-4321-cba987654321"
# List all clients
priva access-control client list
# Delete a client by name
priva access-control client delete --name "MyApp"
# Refresh client secret by name
priva access-control client refresh-secret --name "MyApp"
# Update client permissions
priva access-control client update-permissions --name "MyApp" --permissions "read write admin"
Role Management
# Create a new role (name is required)
priva access-control role add --name "DataReader" --description "Read-only access" --principal-type 1
# Delete a role by ID
priva access-control role delete --role-id "12345678-1234-1234-1234-123456789abc"
# Link features to a role
priva access-control role link-features --role-id "12345678-1234-1234-1234-123456789abc" --features "feature1 feature2"
# List available commands
priva access-control role --help
Authentication & Permissions
Commands require authentication via priva login and appropriate permissions within the Priva platform access control system.
Support
For issues and questions, contact Team Groot: https://dev.azure.com/privagroup/Documentation/_wiki/wikis/Documentation.wiki/3943/Groot
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net8.0
- Azure.Identity (>= 1.16.0)
- Priva.Authorization.Shared (>= 8000.0.157)
- Priva.Cli.Extensions (>= 1.1.283)
- Priva.Platform.Clients.AccessControlApi (>= 2.1.1582)
- Priva.Platform.Clients.TenantApi (>= 2.1.443)
- System.CommandLine (>= 2.0.0-beta4.22272.1)
- System.Text.Json (>= 8.0.6)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|