# `tartan device`

_For tartan 0.9.36._

## `tartan device approve`

approve a pending or dormant device

```
tartan device approve --org <string> --device <string>
```

**Role:** tech · **Writes:** yes · **Steps up:** always · **Dry run:** `--dry-run` · **Batch:** may share one passkey prompt

**Person acts:** passkey prompt: the person approves this exact write with their passkey, after the CLI shows it in words; it can share one passkey prompt with other writes (tartan batch run)

| Flag | Type | Required | What |
|---|---|---|---|
| `--org` | string | yes | org handle or id |
| `--device` | string | yes | device id |

## `tartan device deny`

deny a pending device's join request (never held a cert): the same key may join again with a new code. A deny blocks nothing and ends no session; `device revoke` is the permanent block

```
tartan device deny --org <string> --device <string>
```

**Role:** tech · **Writes:** yes · **Steps up:** always · **Dry run:** `--dry-run` · **Batch:** may share one passkey prompt

**Person acts:** passkey prompt: the person approves this exact write with their passkey, after the CLI shows it in words; it can share one passkey prompt with other writes (tartan batch run)

| Flag | Type | Required | What |
|---|---|---|---|
| `--org` | string | yes | org handle or id |
| `--device` | string | yes | device id |

## `tartan device forget`

archive a device (never with a live cert)

```
tartan device forget --org <string> --device <string>
```

**Role:** tech · **Writes:** yes · **Steps up:** always · **Dry run:** `--dry-run` · **Batch:** may share one passkey prompt

**Person acts:** passkey prompt: the person approves this exact write with their passkey, after the CLI shows it in words; it can share one passkey prompt with other writes (tartan batch run)

| Flag | Type | Required | What |
|---|---|---|---|
| `--org` | string | yes | org handle or id |
| `--device` | string | yes | device id |

## `tartan device forgotten`

the org's forgotten devices, newest first, and whether each can still be restored

```
tartan device forgotten --org <string>
```

**Role:** viewer · **Writes:** no · **Steps up:** never

| Flag | Type | Required | What |
|---|---|---|---|
| `--org` | string | yes | org handle or id |
| `--before` | string | no | a forgotten device's id: page back from that row |
| `--limit` | int | no | default 100, max 1000 |

## `tartan device list`

the org's devices

```
tartan device list --org <string>
```

**Role:** viewer · **Writes:** no · **Steps up:** never

| Flag | Type | Required | What |
|---|---|---|---|
| `--org` | string | yes | org handle or id |
| `--schema` | string | no | answer in a versioned shape: tartan.device.v1 (default: the stored device row, its join_code cut to the hash's first 6 bytes) |

## `tartan device reap`

the stale-device reaper: --plan writes a plan; --apply --run &lt;id> applies one, including forgets over the cap

```
tartan device reap --org <string>
```

**Role:** admin · **Writes:** yes · **Steps up:** always

**Person acts:** passkey prompt: the person approves this exact write with their passkey, after the CLI shows it in words

| Flag | Type | Required | What |
|---|---|---|---|
| `--org` | string | yes | org handle or id |
| `--plan` | bool | no | write a plan of what the reaper would do (a run id), changing nothing |
| `--apply` | bool | no | apply the plan --run names |
| `--run` | string | no | the plan's run id (with --apply) |

## `tartan device release`

release a revoked or suspended device for reuse: its key is retired for good, and the machine joins again with a new code and a fresh key it makes itself

```
tartan device release --org <string> --device <string>
```

**Role:** admin · **Writes:** yes · **Steps up:** always

**Person acts:** passkey prompt: the person approves this exact write with their passkey, after the CLI shows it in words

| Flag | Type | Required | What |
|---|---|---|---|
| `--org` | string | yes | org handle or id |
| `--device` | string | yes | device id |

## `tartan device restore`

bring a forgotten device back (until its address is released)

```
tartan device restore --org <string> --device <string>
```

**Role:** tech · **Writes:** yes · **Steps up:** always · **Dry run:** `--dry-run` · **Batch:** may share one passkey prompt

**Person acts:** passkey prompt: the person approves this exact write with their passkey, after the CLI shows it in words; it can share one passkey prompt with other writes (tartan batch run)

| Flag | Type | Required | What |
|---|---|---|---|
| `--org` | string | yes | org handle or id |
| `--device` | string | yes | device id |

## `tartan device resume`

resume a suspended device

```
tartan device resume --org <string> --device <string>
```

**Role:** tech · **Writes:** yes · **Steps up:** always · **Dry run:** `--dry-run` · **Batch:** may share one passkey prompt

**Person acts:** passkey prompt: the person approves this exact write with their passkey, after the CLI shows it in words; it can share one passkey prompt with other writes (tartan batch run)

| Flag | Type | Required | What |
|---|---|---|---|
| `--org` | string | yes | org handle or id |
| `--device` | string | yes | device id |

## `tartan device revoke`

revoke a device (permanent: certs blocklisted, addresses held)

```
tartan device revoke --org <string> --device <string>
```

**Role:** tech · **Writes:** yes · **Steps up:** always · **Dry run:** `--dry-run` · **Batch:** may share one passkey prompt

**Person acts:** passkey prompt: the person approves this exact write with their passkey, after the CLI shows it in words; it can share one passkey prompt with other writes (tartan batch run)

| Flag | Type | Required | What |
|---|---|---|---|
| `--org` | string | yes | org handle or id |
| `--device` | string | yes | device id |

## `tartan device set`

groups, zone, posture, profiles, name, tls_serving, allow_rekey, site, ring, public (a Tech: groups within tech_mintable, never the ring or a relay's address)

```
tartan device set --org <string> --device <string>
```

**Role:** tech · **Writes:** yes · **Steps up:** some · **Dry run:** `--dry-run` · **Batch:** may share one passkey prompt

**Step-up exempt:** a rename is a label

**Person acts:** passkey prompt for most requests (step_up_exempt names the ones without): the person approves the exact write with their passkey; it can share one passkey prompt with other writes (tartan batch run)

| Flag | Type | Required | What |
|---|---|---|---|
| `--org` | string | yes | org handle or id |
| `--device` | string | yes | device id |
| `--groups` | list | no | the device's tags (replaces them) |
| `--zone` | string | no | the device's zone |
| `--posture` | string | no | the device's posture label |
| `--profiles` | list | no | the device's port profiles (replaces them; empty clears) |
| `--name` | string | no | the device's name (a label: no step-up on its own) |
| `--tls_serving` | bool | no | the device serves HTTPS under its Tartan name (Tartan gets it a certificate) |
| `--allow_rekey` | bool | no | approve the device's next host key: its next certificate is issued for the new key |
| `--site` | string | no | the site's id or name (stored as the id; empty clears) |
| `--ring` | string | no | the device's own update ring: canary \| early \| main \| late, or follow (clear it: the device follows the org's ring; default = main) (Owner or Admin; its own step-up) |
| `--public` | string | no | a site relay's public ip:port (e.g. 203.0.113.7:4242): the site's edge router forwards that WAN UDP port to the relay's LAN address, UDP port 4242 (where a site relay listens); peers are told this address, and control probes it from outside; empty clears |

## `tartan device show`

one device

```
tartan device show --org <string> --device <string>
```

**Role:** viewer · **Writes:** no · **Steps up:** never

| Flag | Type | Required | What |
|---|---|---|---|
| `--org` | string | yes | org handle or id |
| `--device` | string | yes | device id |
| `--schema` | string | no | answer in a versioned shape: tartan.device.v1 (default: the stored device row, its join_code cut to the hash's first 6 bytes) |

## `tartan device suspend`

suspend a device (reversible)

```
tartan device suspend --org <string> --device <string>
```

**Role:** tech · **Writes:** yes · **Steps up:** always · **Dry run:** `--dry-run` · **Batch:** may share one passkey prompt

**Person acts:** passkey prompt: the person approves this exact write with their passkey, after the CLI shows it in words; it can share one passkey prompt with other writes (tartan batch run)

| Flag | Type | Required | What |
|---|---|---|---|
| `--org` | string | yes | org handle or id |
| `--device` | string | yes | device id |
