Skip to content

avr group

Build and manage the organization's group tree.

Terminal window
avr group [OPTIONS] COMMAND [ARGS]...

Groups hold members, service tokens and vCPU limits. Organization members manage them while signed in (avr auth device-login or avr auth login); a scoped or service token cannot. What you may change depends on the groups you administer: avr org governance shows it.

Create a group below a parent group.

Terminal window
avr group create [OPTIONS] NAME

NAME is the new group's name, unique below its parent. --parent names the parent like GROUP in other group commands; the root group, Organization unless renamed, takes groups at the top of the tree.

Each create sends an idempotency key, printed to standard error before the request. If the response is lost, rerun the same command with --idempotency-key KEY: it returns the group that create made instead of making a second one. A key belongs to one parent, name and label.

Terminal window
Examples:
avr group create Platform --parent Organization
avr group create CI --parent Organization/Platform --label runners
Terminal window
JSON FIELDS
created_at, display_name, group_id, idempotency_key, label, member_count,
ownership, parent_id, soft_deleted_at, state, suspension_reason,
updated_at

Arguments

  • NAME

Options

  • --org, -o <TEXT> — Organization ID or slug. Uses default org if not specified (see: avr config set org).
  • --parent <TEXT> — The group to create it below. (required)
  • --label <TEXT> — A short label shown with the group.
  • --idempotency-key <UUID> — Resume an earlier create with the key it printed.
  • --json <TEXT> — Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.
  • -q, --jq <TEXT> — Filter --json output through a jq expression.

Delete an empty group.

Terminal window
avr group delete [OPTIONS] GROUP

GROUP is a group ID (grp-...), the group's path from the root group, such as Organization/Platform/CI, or the end of a path when only one group has it, such as Platform/CI.

Asks first unless --yes is passed. A group that still has subgroups, members, a service token that is not revoked or expired, VMs its service tokens created, a vCPU limit, suspended members or workflows whose jobs are charged to it is not deleted; the error names what to clear, at most 100 workflows at a time.

Deleting a group also removes the resource access it grants, and stops charging it for workflows of repositories that are no longer installed.

Terminal window
Examples:
avr group delete Platform/CI
avr group delete grp-0123456789abcdef0123456789abcdef --yes
Terminal window
JSON FIELDS
deleted, group_id, path

Arguments

  • GROUP

Options

  • --org, -o <TEXT> — Organization ID or slug. Uses default org if not specified (see: avr config set org).
  • -y, --yes — Delete without asking.
  • --json <TEXT> — Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.
  • -q, --jq <TEXT> — Filter --json output through a jq expression.

Rename a group or change its label.

Terminal window
avr group edit [OPTIONS] GROUP

GROUP is a group ID (grp-...), the group's path from the root group, such as Organization/Platform/CI, or the end of a path when only one group has it, such as Platform/CI.

Only the options you pass change; --label '' clears the label.

Terminal window
Examples:
avr group edit Platform/CI --name Builds
avr group edit Platform/CI --label ''
Terminal window
JSON FIELDS
created_at, display_name, group_id, label, member_count, ownership,
parent_id, soft_deleted_at, state, suspension_reason, updated_at

Arguments

  • GROUP

Options

  • --org, -o <TEXT> — Organization ID or slug. Uses default org if not specified (see: avr config set org).
  • --name <TEXT> — The group's new name.
  • --label <TEXT> — The group's new label; an empty value clears it.
  • --json <TEXT> — Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.
  • -q, --jq <TEXT> — Filter --json output through a jq expression.

Show, set and clear a group's vCPU limit.

Terminal window
avr group limit [OPTIONS] COMMAND [ARGS]...

A group's vCPU limit caps the vCPU that the group and its subgroups use at once. Limits on parent groups apply too: a job starts only when it fits under every limit on its group's path, counting what the other groups below each one already use.

Remove a group's own vCPU limit.

Terminal window
avr group limit clear [OPTIONS] GROUP

GROUP is a group ID (grp-...), the group's path from the root group, such as Organization/Platform/CI, or the end of a path when only one group has it, such as Platform/CI.

Asks first unless --yes is passed. Limits on parent groups still apply.

Terminal window
Examples:
avr group limit clear Platform/CI --yes
Terminal window
JSON FIELDS
cleared, group_id, limit_key

Arguments

  • GROUP

Options

  • --org, -o <TEXT> — Organization ID or slug. Uses default org if not specified (see: avr config set org).
  • -y, --yes — Clear without asking.
  • --json <TEXT> — Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.
  • -q, --jq <TEXT> — Filter --json output through a jq expression.

Show the limits that apply to a group, its own and inherited.

Terminal window
avr group limit list [OPTIONS] GROUP

GROUP is a group ID (grp-...), the group's path from the root group, such as Organization/Platform/CI, or the end of a path when only one group has it, such as Platform/CI.

Terminal window
Examples:
avr group limit list Platform/CI
Terminal window
JSON FIELDS
group_id, inherited, kind, limit_key, limit_type, period, timezone,
value

Arguments

  • GROUP

Options

  • --org, -o <TEXT> — Organization ID or slug. Uses default org if not specified (see: avr config set org).
  • --json <TEXT> — Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.
  • -q, --jq <TEXT> — Filter --json output through a jq expression.

Set a group's own vCPU limit.

Terminal window
avr group limit set [OPTIONS] GROUP

GROUP is a group ID (grp-...), the group's path from the root group, such as Organization/Platform/CI, or the end of a path when only one group has it, such as Platform/CI.

Asks first unless --yes is passed or the change raises or keeps the group's own limit: a first limit or a lower one can make new jobs wait. Running jobs keep running.

Terminal window
Examples:
avr group limit set Platform/CI --max-vcpu 64
Terminal window
JSON FIELDS
group_id, inherited, kind, limit_key, limit_type, period, previous_value,
timezone, value

Arguments

  • GROUP

Options

  • --org, -o <TEXT> — Organization ID or slug. Uses default org if not specified (see: avr config set org).
  • --max-vcpu <INTEGER> — The most vCPU the group and its subgroups may use at once. (required)
  • -y, --yes — Set the limit without asking.
  • --json <TEXT> — Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.
  • -q, --jq <TEXT> — Filter --json output through a jq expression.

List the organization's groups by path.

Terminal window
avr group list [OPTIONS]

A group's path is the display names from the root group down, joined with /, such as Organization/Platform/CI; a parent is listed before its children. Pass a group's ID or path to --group when you create or list service tokens.

Terminal window
Examples:
avr group list
avr group list --json group_id,path --jq '.[].path'
Terminal window
JSON FIELDS
created_at, display_name, group_id, label, member_count, ownership,
parent_id, path, soft_deleted_at, state, suspension_reason, updated_at

Options

  • --org, -o <TEXT> — Organization ID or slug. Uses default org if not specified (see: avr config set org).
  • -L, --limit <INTEGER RANGE> — Max groups to return. (default: 50)
  • --json <TEXT> — Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.
  • -q, --jq <TEXT> — Filter --json output through a jq expression.

List, add and remove a group's members.

Terminal window
avr group member [OPTIONS] COMMAND [ARGS]...

A change names each MEMBER by user ID (usr-...), @me for yourself, or an email address the member verified. Display names are not accepted: members choose them, so one can match the wrong person. avr auth status shows your user ID.

Add members to a group.

Terminal window
avr group member add [OPTIONS] GROUP [MEMBER]...

GROUP is a group ID (grp-...), the group's path from the root group, such as Organization/Platform/CI, or the end of a path when only one group has it, such as Platform/CI.

Name each MEMBER by user ID (usr-...), @me or a verified email address, as arguments or one per line with --file, where a line starting with # is a comment unless it is an email address, such as #ops@example.com. The command adds them all in one change, up to 250, and reports each member's result; a member already in the state asked for counts as done, so a rerun is safe.

Terminal window
Examples:
avr group member add Platform/CI @me
avr group member add Platform/CI usr-0123456789abcdef0123456789abcdef
avr group member add Platform/CI --file members.txt
Terminal window
JSON FIELDS
action, detail, member, status, user_id

Arguments

  • GROUP
  • [MEMBER...]

Options

  • --org, -o <TEXT> — Organization ID or slug. Uses default org if not specified (see: avr config set org).
  • --file <TEXT> — Read members from a file, one per line; - reads standard input.
  • --json <TEXT> — Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.
  • -q, --jq <TEXT> — Filter --json output through a jq expression.

List a group's direct members.

Terminal window
avr group member list [OPTIONS] GROUP

GROUP is a group ID (grp-...), the group's path from the root group, such as Organization/Platform/CI, or the end of a path when only one group has it, such as Platform/CI.

Members of subgroups are listed with the subgroup.

Terminal window
Examples:
avr group member list Platform/CI
avr group member list Platform/CI -L 1000 --json user_id,email
Terminal window
JSON FIELDS
added_at, email, name, source, stale_sources, user_id

Arguments

  • GROUP

Options

  • --org, -o <TEXT> — Organization ID or slug. Uses default org if not specified (see: avr config set org).
  • -L, --limit <INTEGER RANGE> — Max members to return. (default: 100)
  • --json <TEXT> — Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.
  • -q, --jq <TEXT> — Filter --json output through a jq expression.

Remove members from a group.

Terminal window
avr group member remove [OPTIONS] GROUP [MEMBER]...

GROUP is a group ID (grp-...), the group's path from the root group, such as Organization/Platform/CI, or the end of a path when only one group has it, such as Platform/CI.

Name each MEMBER by user ID (usr-...), @me or a verified email address, as arguments or one per line with --file, where a line starting with # is a comment unless it is an email address, such as #ops@example.com. The command removes them all in one change, up to 250, and reports each member's result; a member already in the state asked for counts as done, so a rerun is safe. Lists the members and asks first unless --yes is passed; reading members from standard input (--file -) needs --yes.

Terminal window
Examples:
avr group member remove Platform/CI @me
avr group member remove Platform/CI usr-0123456789abcdef0123456789abcdef
avr group member remove Platform/CI --file members.txt
Terminal window
JSON FIELDS
action, detail, member, status, user_id

Arguments

  • GROUP
  • [MEMBER...]

Options

  • --org, -o <TEXT> — Organization ID or slug. Uses default org if not specified (see: avr config set org).
  • --file <TEXT> — Read members from a file, one per line; - reads standard input.
  • -y, --yes — Remove without asking.
  • --json <TEXT> — Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.
  • -q, --jq <TEXT> — Filter --json output through a jq expression.

Show the vCPU a group uses and the limits on its path.

Terminal window
avr group usage [OPTIONS] GROUP

GROUP is a group ID (grp-...), the group's path from the root group, such as Organization/Platform/CI, or the end of a path when only one group has it, such as Platform/CI.

Usage counts the group and its subgroups.

Terminal window
Examples:
avr group usage Platform
avr group usage Platform --json used_vcpu,pools
Terminal window
JSON FIELDS
group_id, group_state, measured_at, pools, used_vcpu

Arguments

  • GROUP

Options

  • --org, -o <TEXT> — Organization ID or slug. Uses default org if not specified (see: avr config set org).
  • --json <TEXT> — Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.
  • -q, --jq <TEXT> — Filter --json output through a jq expression.

Show a group's details and path.

Terminal window
avr group view [OPTIONS] GROUP

GROUP is a group ID (grp-...), the group's path from the root group, such as Organization/Platform/CI, or the end of a path when only one group has it, such as Platform/CI.

Terminal window
Examples:
avr group view Organization/Platform
avr group view Platform/CI --json group_id,member_count
Terminal window
JSON FIELDS
created_at, display_name, group_id, label, member_count, ownership,
parent_id, path, soft_deleted_at, state, suspension_reason, updated_at

Arguments

  • GROUP

Options

  • --org, -o <TEXT> — Organization ID or slug. Uses default org if not specified (see: avr config set org).
  • --json <TEXT> — Output JSON. Pass comma-separated field names, "*" for all fields, or "?" to list available fields.
  • -q, --jq <TEXT> — Filter --json output through a jq expression.