Skip to content

MCP (Model Context Protocol)

Add content moderation to Claude, Cursor, and any MCP-compatible AI tool.

What is MCP?

Model Context Protocol is an open standard that lets AI assistants connect to external tools and data sources. With the Vettly MCP server, any MCP-compatible tool can moderate content without writing integration code.

Installation

bash
npx @nextauralabs/vettly-mcp

Claude Desktop

Add to your claude_desktop_config.json:

json
{
  "mcpServers": {
    "vettly": {
      "command": "npx",
      "args": ["-y", "@nextauralabs/vettly-mcp"],
      "env": {
        "VETTLY_API_KEY": "vettly_live_xxx"
      }
    }
  }
}

Config file locations:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json

Restart Claude Desktop after updating the config.

Available Tools

ToolDescription
moderate_contentCheck text, image, or video against a moderation policy
validate_policyValidate policy YAML without saving
list_policiesList all available moderation policies
get_usage_statsGet usage statistics and costs
get_recent_decisionsReview recent moderation decisions

Usage Examples

Once configured, you can ask Claude to moderate content naturally:

"Moderate this comment: 'You're an idiot and I hate you'"

"Check if this text is safe for a kids app: 'Let's play a fun game!'"

"List my moderation policies"

"Show me my usage stats for the last 7 days"

"Get my last 10 flagged decisions"

Tool Reference

moderate_content

Check content against a moderation policy.

Parameters:

  • content (required) - The content to moderate
  • policyId (required) - Policy ID to use
  • contentType (optional) - text, image, or video (default: text)

Response:

json
{
  "decisionId": "dec_abc123",
  "safe": false,
  "flagged": true,
  "action": "block",
  "categories": [
    { "category": "harassment", "score": 0.92, "triggered": true }
  ]
}

validate_policy

Validate policy YAML syntax without saving.

Parameters:

  • yamlContent (required) - YAML policy content

Response:

json
{
  "valid": true
}

list_policies

List all available moderation policies.

Response:

json
{
  "policies": [
    { "id": "default", "name": "Default Policy" },
    { "id": "strict", "name": "Strict Moderation" }
  ]
}

get_usage_stats

Get usage statistics.

Parameters:

  • days (optional) - Days to include (1-365, default: 30)

get_recent_decisions

Get recent moderation decisions.

Parameters:

  • limit (optional) - Number of decisions (1-50, default: 10)
  • flagged (optional) - Filter by flagged status
  • policyId (optional) - Filter by policy
  • contentType (optional) - Filter by content type

Resources

The MCP server also exposes read-only resources:

  • vettly://policies - List of all policies
  • vettly://policies/{policyId} - Specific policy YAML

Programmatic Usage

You can also use the MCP server programmatically:

typescript
import { createVettlyMcpServer } from '@nextauralabs/vettly-mcp'

const server = createVettlyMcpServer({
  apiKey: process.env.VETTLY_API_KEY!,
})

// Connect to your transport
server.connect(transport)

Environment Variables

VariableRequiredDescription
VETTLY_API_KEYYesYour Vettly API key
VETTLY_API_URLNoAPI URL (default: https://api.vettly.dev)

Supported Platforms

Any tool that supports MCP can use the Vettly server:

  • Claude Desktop - Anthropic's desktop app
  • Claude Code - CLI for developers
  • Cursor - AI-powered code editor
  • Zed - Modern code editor with AI
  • Custom agents - Any MCP client implementation

Next Steps