Security and Access
hdxcli v1.0.83
User⚓︎
This command handles the administration of user accounts. Provides functionality to list, show, delete, and manage roles for existing users, and to manage their invitations.
Usage
Options
| Option | Description |
|---|---|
--user TEXT |
Perform operation on the passed user. |
Assign Role⚓︎
Assign one or more roles to a user. This command adds roles to an existing user.
Usage
Options
| Option | Description |
|---|---|
-r, --role TEXT |
Role to assign. Can be used multiple times. [required] |
Examples
Delete⚓︎
Permanently deletes the specified user. This action is irreversible.
Usage
Options
| Option | Description |
|---|---|
--disable-confirmation-prompt |
Suppress confirmation to delete the user. |
Examples
List⚓︎
List all users.
Displays a list of all users, excluding service accounts. The output includes the user's email and their assigned roles.
Usage
Examples
Remove Role⚓︎
Remove one or more roles from a user. This command removes existing roles from a user.
Usage
Options
| Option | Description |
|---|---|
-r, --role TEXT |
Role to remove. Can be used multiple times. [required] |
Examples
Show⚓︎
Show details for a specific user.
Displays the full configuration of a specific user. It will use the invite specified with the --user option.
Usage
Options
| Option | Description |
|---|---|
-i, --indent |
Output in indented JSON format. |
Examples
Invite⚓︎
Provides commands for managing user invitations. Includes commands to send, resend, list, show, and delete user invitations.
Usage
Options
| Option | Description |
|---|---|
--invite USER_EMAIL |
Perform operation on the passed user. |
Delete⚓︎
Permanently deletes the specified invite. This action is irreversible.
Usage
Options
| Option | Description |
|---|---|
--disable-confirmation-prompt |
Suppress confirmation to delete the invite. |
Examples
List⚓︎
List all invites.
Displays a list of all user invitations, showing their email and status. The list can be filtered for only pending invitations with the --pending flag.
Usage
Options
| Option | Description |
|---|---|
-p, --pending |
List only pending invitations. |
Examples
Resend⚓︎
Resend an existing invite. Resends an invitation to a user, typically when the original invitation has expired or was not received.
Usage
Examples
Send⚓︎
Create and send a new invite. Sends an email invitation to a new user with a specific set of roles.
Usage
Options
| Option | Description |
|---|---|
-r, --role TEXT |
Role to assign to the new user. Can be used multiple times. [required] |
Examples
Show⚓︎
Show details for a specific invite.
Displays the full configuration of a specific invite. It will use the invite specified with the --invite option.
Usage
Options
| Option | Description |
|---|---|
-i, --indent |
Output in indented JSON format. |
Examples
Service-Account⚓︎
Service accounts are non-human users designed for programmatic API access. This includes creating, listing, deleting, and managing roles and tokens for them.
Usage
Options
| Option | Description |
|---|---|
--service-account, --sa TEXT |
Perform an operation on the specified service account. |
Assign Role⚓︎
Assign one or more roles to a service account.
Usage
Options
| Option | Description |
|---|---|
-r, --role ROLE |
Role(s) to assign. Can be used multiple times. [required] |
Examples
Create⚓︎
This command creates a new service account and assigns one or more roles to it. An access token can be generated immediately by using the --generate-token flag.
Usage
Options
| Option | Description |
|---|---|
-r, --role ROLE |
Role to assign. Can be specified multiple times. [required] |
--generate-token [DURATION] |
Generate a token after creation. Optionally, provide a duration (for example, '30d', '1y'). |
--set-as-auth |
Set the generated token as the authentication method for the current profile. This will overwrite any existing credentials. |
Examples
Delete⚓︎
Delete a specific service account.
This is a permanent action and cannot be undone. You will be prompted for confirmation unless --disable-confirmation-prompt is used.
Usage
Options
| Option | Description |
|---|---|
--disable-confirmation-prompt |
Suppress confirmation to delete service account. |
Examples
Generate Token⚓︎
Generate a new access token for a service account. The service account name can be specified via argument or the global --sa option.
Usage
Options
| Option | Description |
|---|---|
--duration DURATION |
Set token lifetime (for example, '30d', '12h', '1y'). If not set, the API default is used. |
--json |
Display the full token response in JSON format. |
--set-as-auth |
Set the generated token as the authentication method for the current profile. This will overwrite any existing credentials. |
Examples
List⚓︎
List all available service accounts. Displays a table with the names of all service accounts and the roles assigned to them.
Usage
Examples
Remove Role⚓︎
Remove one or more roles from a service account.
Usage
Options
| Option | Description |
|---|---|
-r, --role ROLE |
Role(s) to remove. Can be used multiple times. [required] |
Examples
Revoke Tokens⚓︎
Revoke all active tokens for a service account.
This is a security-sensitive operation that invalidates all existing tokens for the specified service account, forcing any application using them to re-authenticate with a new token.
Usage
Options
| Option | Description |
|---|---|
--yes |
Bypass the confirmation prompt. |
Examples
Show⚓︎
Show details for a specific service account.
Retrieves and displays the settings of a single service account. If no name is provided, the default service account will be used if exists.
Usage
Options
| Option | Description |
|---|---|
-i, --indent |
Indent the output. |
Examples
Role⚓︎
Commands to create, edit, and manage user roles and their permissions.
Usage
Options
| Option | Description |
|---|---|
--role ROLE_NAME |
Perform operation on the passed role. |
Add User⚓︎
Add one or more users to a role.
Usage
Options
| Option | Description |
|---|---|
-u, --user TEXT |
Specify users to add to a role (can be used multiple times). [required] |
Examples
Create⚓︎
Create a new role. This command supports two modes for creating a role:
- Command-Line: Define a single policy by providing its details as options.
- Interactive: Use the
--interactiveflag for a guided setup.
Usage
Options
| Option | Description |
|---|---|
-t, --scope-type TEXT |
Type of scope for the role. |
-i, --scope-id TEXT |
Identifier for the scope (UUID). |
-p, --permission TEXT |
Specify permissions for the new role (can be used multiple times). |
--interactive |
Enter interactive mode to be guided through role creation. |
Examples
Delete⚓︎
Delete a specific role.
This is a permanent action and cannot be undone. You will be prompted for confirmation unless --disable-confirmation-prompt is used.
Usage
Options
| Option | Description |
|---|---|
--disable-confirmation-prompt |
Suppress confirmation to delete role. |
Examples
Edit⚓︎
Modify an existing role interactively.
This command starts an interactive session to guide you through modifying a role, including its name and policies.
Usage
Examples
List⚓︎
List all available roles.
Retrieves a list of all roles you have access to. Pagination options (--page, --page-size) are available if supported by the API.
Usage
Options
| Option | Description |
|---|---|
-p, --page INTEGER |
Page number. |
-s, --page-size INTEGER |
Number of items per page. |
Examples
List Permissions⚓︎
Lists all available permissions that can be assigned to a role, optionally filtered by a scope type.
Usage
Options
| Option | Description |
|---|---|
-t, --scope-type SCOPE_TYPE |
Filter the permissions by a specific scope type. |
Examples
Remove User⚓︎
Remove one or more users from a role.
Usage
Options
| Option | Description |
|---|---|
-u, --user TEXT |
Specify users to remove from a role (can be used multiple times). [required] |
Examples
Show⚓︎
Show details for a specific role.
Retrieves and displays the settings of a single role. If no name is provided, the default role will be used if exists.
Usage
Options
| Option | Description |
|---|---|
-i, --indent |
Indent the output. |
Examples
Row-Policy⚓︎
Manages Row-Level security policies for tables.
This command group provides functionality to create, list, show, delete, and manage roles for row policies, allowing for fine-grained access control over the data within a table.
Usage
Options
| Option | Description |
|---|---|
--project PROJECT_NAME |
Use or override project set in the profile. |
--table TABLE_NAME |
Use or override table set in the profile. |
--row-policy ROW_POLICY_NAME |
Explicitly pass the row policy name. |
Add Role⚓︎
Adds one or more roles to an existing row policy. This command associates roles with a row policy, granting the permissions defined by that row policy to users who have those roles.
Usage
Options
| Option | Description |
|---|---|
--role ROLE_NAME |
Role to add. Can be specified multiple times. [required] |
Examples
Create⚓︎
Creates a new row policy for the specified table. A row policy filters the data that users can see based on a filter expression. It must be associated with at least one role to take effect.
Usage
Options
| Option | Description |
|---|---|
--filter FILTER_EXPRESSION |
The filter expression for the policy (for example, '"claimed"=false'). [required] |
--restrictive |
Set the policy as restrictive. Default is permissive. |
--role ROLE_NAME |
Role to associate with this policy. Can be specified multiple times. |
Examples
Delete⚓︎
Delete a specific row policy.
This is a permanent action and cannot be undone. You will be prompted for confirmation unless --disable-confirmation-prompt is used.
Usage
Options
| Option | Description |
|---|---|
--disable-confirmation-prompt |
Suppress confirmation to delete row policy. |
Examples
List⚓︎
Lists all row policies for a given table. Displays a summary of all row policies, including their name, filter expression, whether they are restrictive, and their associated roles.
Usage
Examples
Remove Role⚓︎
Removes one or more roles from an existing row policy. This command disassociates roles from a row policy, revoking the permissions defined by that row policy from users who have those roles.
Usage
Options
| Option | Description |
|---|---|
--role ROLE_NAME |
Role to remove. Can be specified multiple times. [required] |
Examples
Settings⚓︎
List, get, or set key-value settings for a specific row policy.
This command operates in three modes: - LIST: Invoked with no arguments, it lists all settings. - GET: Invoked with only a KEY, it retrieves the value of that setting. - SET: Invoked with a KEY and a VALUE, it sets the value for that setting.
The VALUE can be a string, a number, or a JSON-formatted string for lists/objects. When setting a value, the --force-operation option may be required for certain resource.
Usage
Options
| Option | Description |
|---|---|
-F, --force |
This flag allows adding the force_operation parameter to the request. |
Examples
Show⚓︎
Show details for a specific row policy.
Retrieves and displays the settings of a single row policy. If no name is provided, the default row policy will be used if exists.
Usage
Options
| Option | Description |
|---|---|
-i, --indent |
Indent the output. |
Examples
Credential⚓︎
Provides commands to create, list, show, and delete credentials. It also includes a command to list all available credential types which is useful before creating a new one.
Usage
Options
| Option | Description |
|---|---|
--credential CREDENTIAL_NAME |
Perform operation on the passed credential. |
Create⚓︎
Create a new credential. The command prompts for any required details not provided as options. For fully non-interactive use, all details must be specified using the --detail option.
Usage
Options
| Option | Description |
|---|---|
--description TEXT |
Credential description. |
--detail TEXT... |
A key-value pair for a credential detail. Use multiple times for multiple details. |
Examples
Delete⚓︎
Delete a specific credential.
This is a permanent action and cannot be undone. You will be prompted for confirmation unless --disable-confirmation-prompt is used.
Usage
Options
| Option | Description |
|---|---|
--disable-confirmation-prompt |
Suppress confirmation to delete credential. |
Examples
List⚓︎
List all available credentials.
Retrieves a list of all credentials you have access to. Pagination options (--page, --page-size) are available if supported by the API.
Usage
Options
| Option | Description |
|---|---|
-p, --page INTEGER |
Page number. |
-s, --page-size INTEGER |
Number of items per page. |
Examples
List Types⚓︎
List available credential types.
Usage
Options
| Option | Description |
|---|---|
-c, --cloud CLOUD |
Filter the credential types by a specific cloud. |
Examples
Settings⚓︎
List, get, or set key-value settings for a specific credential.
This command operates in three modes: - LIST: Invoked with no arguments, it lists all settings. - GET: Invoked with only a KEY, it retrieves the value of that setting. - SET: Invoked with a KEY and a VALUE, it sets the value for that setting.
The VALUE can be a string, a number, or a JSON-formatted string for lists/objects. When setting a value, the --force-operation option may be required for certain resource.
Usage
Options
| Option | Description |
|---|---|
-F, --force |
This flag allows adding the force_operation parameter to the request. |
Examples
Show⚓︎
Show details for a specific credential.
Retrieves and displays the settings of a single credential. If no name is provided, the default credential will be used if exists.
Usage
Options
| Option | Description |
|---|---|
-i, --indent |
Indent the output. |
Examples