> ## Documentation Index
> Fetch the complete documentation index at: https://magic-book.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# AI providers

> Save, test, replace and remove the API keys for the eight AI providers MagicBook calls directly.

**AI → AI Providers** holds the API key for each AI company. MagicBook calls each provider directly with its key. Nothing goes through a gateway or a third-party router.

## The providers

Each provider has one card. A provider can do one or more jobs:

| Provider | Jobs | Used for |
| - | - | - |
| **OpenAI** | Writing, pictures, moderation | GPT models for writing and planning, GPT Image for pictures, and the free safety check. |
| **Anthropic** | Writing | Claude models for long-form prose and editing. |
| **Google Gemini** | Writing, pictures | Gemini models for writing, and image models that keep characters consistent. |
| **xAI Grok** | Writing | Grok models for writing and planning. |
| **Black Forest Labs (FLUX)** | Pictures | Illustrations, with reference images for consistent characters. |
| **Ideogram** | Pictures | Covers and lettering. |
| **Recraft** | Pictures | Covers, vector art and line art. |
| **ElevenLabs** | Voice | Narration and voice input. |

Each card links to the page where you create a key. See [Integrations](https://magic-book.mintlify.site/integrations/overview.md).

## Save a key

**1. Open the card**

Find the provider's card. Its status says **Not set** until you save a key.

**2. Paste the key**

Press **Add key**, paste the key into **API key**, and press **Save and test**. MagicBook saves the key and makes a test call. The status becomes **Saved, not tested** before the test and then a result.

**3. Test again when needed**

**Test connection** makes a test call at any time, for example after you change a plan at the provider.

## Replace or remove a key

* **Replace** swaps the saved key for a new one. You cannot read the old key back.
* **Remove** deletes the key. The models that use it stop working until you add a key again. The models stay in their lists, but show **No key**.

Keys are stored encrypted in the database. The page never shows a saved key again, so keep your own copy in a password manager.

## After you save keys

Enable the models that use the keys:

* [Text models](https://magic-book.mintlify.site/admin/text-models.md) for writing.
* [Image models](https://magic-book.mintlify.site/admin/image-models.md) for pictures.
* [Voices](https://magic-book.mintlify.site/admin/voices.md) for narration and voice input.

Safety checks use the OpenAI key. See [Safety](https://magic-book.mintlify.site/admin/safety.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.