---
title: Accounts CLI reference
description: Manage Honeybadger accounts, users, and invitations from the command line.
url: https://docs.honeybadger.io/tools/cli/accounts/
---

The `accounts` command lets you manage Honeybadger accounts, users, and invitations.

## List accounts

```shell
hb accounts list
hb accounts list --output json
```

**Optional flags:**

* `-o, --output` — Output format: `table` or `json` (default: `table`)

## Get account details

```shell
hb accounts get --id 12345
```

**Required flags:**

* `--id` — Account ID

**Optional flags:**

* `-o, --output` — Output format: `text` or `json` (default: `text`)

***

## Managing users

### List users for an account

```shell
hb accounts users list --account-id 12345
```

**Required flags:**

* `--account-id` — Account ID

**Optional flags:**

* `-o, --output` — Output format: `table` or `json` (default: `table`)

### Get a specific user

```shell
hb accounts users get --account-id 12345 --user-id 67890
```

**Required flags:**

* `--account-id` — Account ID
* `--user-id` — User ID

**Optional flags:**

* `-o, --output` — Output format: `text` or `json` (default: `text`)

### Update a user’s role

```shell
hb accounts users update --account-id 12345 --user-id 67890 --role Admin
```

**Required flags:**

* `--account-id` — Account ID
* `--user-id` — User ID
* `--role` — New role: `Member`, `Billing`, `Admin`, or `Owner`

**Optional flags:**

* `-o, --output` — Output format: `text` or `json` (default: `text`)

### Remove a user from an account

```shell
hb accounts users remove --account-id 12345 --user-id 67890
```

**Required flags:**

* `--account-id` — Account ID
* `--user-id` — User ID

***

## Managing invitations

### List invitations

```shell
hb accounts invitations list --account-id 12345
```

**Required flags:**

* `--account-id` — Account ID

**Optional flags:**

* `-o, --output` — Output format: `table` or `json` (default: `table`)

### Get an invitation

```shell
hb accounts invitations get --account-id 12345 --invitation-id 11111
```

**Required flags:**

* `--account-id` — Account ID
* `--invitation-id` — Invitation ID

**Optional flags:**

* `-o, --output` — Output format: `text` or `json` (default: `text`)

### Create an invitation

```shell
hb accounts invitations create --account-id 12345 --cli-input-json '{
  "email": "user@example.com",
  "role": "Member",
  "team_ids": [111, 222]
}'
```

**Required flags:**

* `--account-id` — Account ID
* `--cli-input-json` — JSON payload (inline string or `file://path`)

**JSON fields:**

* `email` — Email address to invite
* `role` — Role for the new user: `Member`, `Billing`, `Admin`, or `Owner`
* `team_ids` — Optional array of team IDs to add the user to

**Optional flags:**

* `-o, --output` — Output format: `text` or `json` (default: `text`)

### Update an invitation

```shell
hb accounts invitations update --account-id 12345 --invitation-id 11111 --cli-input-json '{"role": "Admin"}'
```

**Required flags:**

* `--account-id` — Account ID
* `--invitation-id` — Invitation ID
* `--cli-input-json` — JSON payload with fields to update

**Optional flags:**

* `-o, --output` — Output format: `text` or `json` (default: `text`)

### Delete an invitation

```shell
hb accounts invitations delete --account-id 12345 --invitation-id 11111
```

**Required flags:**

* `--account-id` — Account ID
* `--invitation-id` — Invitation ID

---

## Try Honeybadger for FREE

Intelligent logging, error tracking, and Just Enough APM™ in one dev-friendly platform. Find and fix problems before users notice.

[Start free trial](https://app.honeybadger.io/users/sign_up)

[See plans and pricing](https://www.honeybadger.io/plans/)
