# Spines MCP server

> Lets an AI assistant manage book collections, search for books, and recognize bookshelves from photos.

- Repository: https://github.com/GetSpines/mcp-server
- Page: https://hostedmcp.org/servers/getspines/mcp-server
- Transport: stdio
- Stars: 0
- License: MIT
- Latest version: 1.1.0

## Install

### Claude Code

```sh
claude mcp add --env 'SPINES_API_KEY=<YOUR_SPINES_API_KEY>' mcp-server -- npx -y @spines/mcp-server
```

### Cursor (`~/.cursor/mcp.json`)

```json
{
  "mcpServers": {
    "mcp-server": {
      "command": "npx",
      "args": [
        "-y",
        "@spines/mcp-server"
      ],
      "env": {
        "SPINES_API_KEY": "<YOUR_SPINES_API_KEY>"
      }
    }
  }
}
```

### VS Code (`.vscode/mcp.json`)

```json
{
  "servers": {
    "mcp-server": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@spines/mcp-server"
      ],
      "env": {
        "SPINES_API_KEY": "<YOUR_SPINES_API_KEY>"
      }
    }
  }
}
```

### VS Code CLI

```sh
code --add-mcp '{"name":"mcp-server","type":"stdio","command":"npx","args":["-y","@spines/mcp-server"],"env":{"SPINES_API_KEY":"<YOUR_SPINES_API_KEY>"}}'
```

### Claude Desktop (`claude_desktop_config.json`)

```json
{
  "mcpServers": {
    "mcp-server": {
      "command": "npx",
      "args": [
        "-y",
        "@spines/mcp-server"
      ],
      "env": {
        "SPINES_API_KEY": "<YOUR_SPINES_API_KEY>"
      }
    }
  }
}
```

### Codex

```sh
codex mcp add mcp-server --env 'SPINES_API_KEY=<YOUR_SPINES_API_KEY>' -- npx -y @spines/mcp-server
```

### Codex config.toml (`~/.codex/config.toml`)

```toml
[mcp_servers.mcp-server]
command = "npx"
args = ["-y", "@spines/mcp-server"]

[mcp_servers.mcp-server.env]
SPINES_API_KEY = "<YOUR_SPINES_API_KEY>"
```

### Gemini CLI

```sh
gemini mcp add -s user -e 'SPINES_API_KEY=<YOUR_SPINES_API_KEY>' mcp-server npx -- -y @spines/mcp-server
```

### Gemini settings.json (`~/.gemini/settings.json`)

```json
{
  "mcpServers": {
    "mcp-server": {
      "command": "npx",
      "args": [
        "-y",
        "@spines/mcp-server"
      ],
      "env": {
        "SPINES_API_KEY": "<YOUR_SPINES_API_KEY>"
      }
    }
  }
}
```

## Environment variables

| Name | Required | Secret | Description |
|---|---|---|---|
| `SPINES_API_KEY` | yes | yes | Your SPINES API key |

## Tools (11)

- `search_books`
- `get_book_details`
- `get_collection`
- `list_collections`
- `list_categories`
- `get_persona`
- `get_book_pairings`
- `check_credits`
- `add_to_reading_list`
- `remove_from_reading_list`
- `recognize_bookshelf`

## FAQ

### How can I recognize books from my bookshelf?

You can use the recognize_bookshelf tool to process one or more photos of a bookshelf and save them as a collection.

### Can I use my own LLM for bookshelf recognition to save credits?

Yes, if you set SPINES_LLM_PROVIDER to 'gemini' and provide a SPINES_LLM_API_KEY, recognition uses your key and no SPINES credits.

### How many photos can I upload at once for recognition?

You can upload up to 4 photos per request when using a regular key.
