> ## Documentation Index
> Fetch the complete documentation index at: https://docs.magnet.run/llms.txt
> Use this file to discover all available pages before exploring further.

# magnet issues

> List, get, create, and update Magnet issues from the command line.

The `magnet issues` command group works with issues in your workspace. Content is exchanged as markdown.

## magnet issues list

List issues, optionally filtered by a search query.

```bash theme={null}
magnet issues list
```

| Option             | Description                                                                 |
| ------------------ | --------------------------------------------------------------------------- |
| `--search <query>` | Search query.                                                               |
| `--limit <n>`      | Page size (default from API). Use with `--cursor` for pagination.           |
| `--cursor <c>`     | Pagination cursor (use `pagination.nextCursor` from the previous response). |

## magnet issues get

Get an issue by ID. Returns the issue with its content as markdown (`docContent`).

```bash theme={null}
magnet issues get <id>
```

| Option           | Description                                                    |
| ---------------- | -------------------------------------------------------------- |
| `--preview-only` | Return a truncated `markdownPreview` instead of the full body. |

## magnet issues create

Create an issue from markdown.

```bash theme={null}
magnet issues create --description "Fix the login redirect loop" --title "Login redirect loop"
```

| Option                   | Description                                 |
| ------------------------ | ------------------------------------------- |
| `--description <text>`   | Issue description (markdown). **Required.** |
| `--title <text>`         | Issue title.                                |
| `--base-branch <branch>` | Base branch name. Defaults to `main`.       |

## magnet issues update

Update an issue's title, status, or assignee.

```bash theme={null}
magnet issues update <id> --status in_progress
```

| Option                     | Description                                      |
| -------------------------- | ------------------------------------------------ |
| `--title <text>`           | New title.                                       |
| `--status <status>`        | One of `todo`, `in_progress`, `done`, `blocked`. |
| `--assignee-clerk-id <id>` | Clerk user ID to assign.                         |
| `--skip-yjs-sync`          | Skip syncing to Yjs (e.g. for bulk updates).     |

## Examples

Paginate through all issues:

```bash theme={null}
magnet issues list --limit 50
magnet issues list --limit 50 --cursor "<pagination.nextCursor from previous response>"
```

Find and close an issue:

```bash theme={null}
magnet issues list --search "redirect loop"
magnet issues update issue_abc123 --status done
```
