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

# Setup skill

> Let your AI coding agent add Moderation API to your app with the moderation-api-setup skill.

The `moderation-api-setup` skill teaches your coding agent how to add Moderation API to an existing app. It follows the [Agent Skills](https://agentskills.io) format, so it works with Claude Code, Cursor, Codex and other agents that read skills.

## Install

```bash Any agent theme={"theme":"nord"}
npx skills add moderation-api/skills
```

```bash Claude Code plugin theme={"theme":"nord"}
/plugin marketplace add moderation-api/skills
/plugin install moderation-api@moderation-api
```

The Claude Code plugin also connects the [MCP server](https://docs.moderationapi.com/ai/mcp.md). The source is at [github.com/moderation-api/skills](https://github.com/moderation-api/skills).

Then ask your agent:

> Set up Moderation API in this app.

## What it does

The skill works in this order, and asks you before each change:

1. **Check.** Runs `modapi doctor`, asks you to sign in if needed, and looks for an existing integration.
2. **Plan.** Finds every place where users create content: messages, posts, comments, profiles, uploads. It proposes a [channel](https://docs.moderationapi.com/get-started/concepts.md) for each kind of content and what to do on `review` and `reject`, and waits for your approval.
3. **Project.** Links your project or creates a new one with `modapi init`, and creates the channels. Your keys go to your env file, never into the chat.
4. **Code.** Adds one moderation helper on your server and calls it from each place in the plan. It sends `authorId`, `conversationId` and `contentId`, so moderators get context and webhooks find the record.
5. **Result.** Acts on `recommendation.action`, saves masked text when the API masks contact details, and fails open when the API is not reachable.
6. **Webhooks.** Adds a route that verifies the signature and acts on decisions that moderators make later.
7. **Verify.** Checks the code against a list of common mistakes, runs `modapi doctor`, and sends a test.

## Shadow mode

The skill asks if you want to start in shadow mode. In shadow mode, Moderation API analyzes all content, and the dashboard and review queue show the real results, but every API response says `allow`. Your users see no change while you check the results.

When you trust the results, switch shadow mode off. No code change is needed:

```bash theme={"theme":"nord"}
modapi projects update <project-id> --global-flagging-mode ACTIVE
```

## Next

After setup, the agent tells you what you can do with the [MCP server](https://docs.moderationapi.com/ai/mcp.md), for example triage the review queue or tune policies. See [What your agent can do](https://docs.moderationapi.com/ai/examples.md).
