# mcp-legiti

Connects Legiti fraud detection tools to an AI coding assistant for transaction risk analysis. The package is marked deprecated because its default host cannot be resolved via DNS.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 274
- Author: codespar
- License: MIT · policy=link-only · description only; the file stays with the author
- Source: https://github.com/codespar/mcp-dev-latam/tree/HEAD/packages/fraud/legiti
- Updated: 2026-09-27
- HTML: https://affpapa.org/en/nevibecode/mcp/mcp-legiti

## What it does

This MCP server exposes 18 tools for interacting with Legiti, a Brazilian risk scoring engine built for ticketing platforms and retail. It submits purchase payloads for immediate synchronous evaluation, returning verdicts like `approve`, `reject`, or `manual`. It also logs user actions, including login attempts, account profile edits, and ticket viewing events.

Authentication relies on a JWT bearer token supplied via `LEGITI_API_KEY`. Legiti provides separate keys for sandbox testing and production environments to prevent test events from degrading live predictive scoring. Synchronous evaluation requests can take up to 20 seconds.

The package is deprecated because its built-in endpoint `collection-prod.inspcdn.net` fails DNS resolution. The server will not reach any backend service unless a valid alternative URL is specified in `LEGITI_BASE_URL`.

## Requirements
- Needs: Node.js (commands run via npx)
- Environment variables: `LEGITI_API_KEY`, `LEGITI_BASE_URL` — keys and tokens: ask the human for the values, never commit them or put them in shared files.

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add --env LEGITI_API_KEY=<LEGITI_API_KEY> --env LEGITI_BASE_URL=<LEGITI_BASE_URL> --transport stdio legiti -- npx -y @codespar/mcp-legiti
```
Replace <…> with your own values

### Codex

**Platform CLI**
```bash
codex mcp add legiti --env LEGITI_API_KEY=<LEGITI_API_KEY> --env LEGITI_BASE_URL=<LEGITI_BASE_URL> -- npx -y @codespar/mcp-legiti
```
Replace <…> with your own values

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "legiti": {
            "command": "npx",
            "args": [
                "-y",
                "@codespar/mcp-legiti"
            ],
            "env": {
                "LEGITI_API_KEY": "<LEGITI_API_KEY>",
                "LEGITI_BASE_URL": "<LEGITI_BASE_URL>"
            }
        }
    }
}
```
Replace <…> with your own values

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "legiti": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "@codespar/mcp-legiti"
            ],
            "env": {
                "LEGITI_API_KEY": "<LEGITI_API_KEY>",
                "LEGITI_BASE_URL": "<LEGITI_BASE_URL>"
            }
        }
    }
}
```
Replace <…> with your own values

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add -e LEGITI_API_KEY=<LEGITI_API_KEY> -e LEGITI_BASE_URL=<LEGITI_BASE_URL> legiti npx -y @codespar/mcp-legiti
```
Replace <…> with your own values

## When to use it
- evaluate order fraud risk synchronously before fulfillment
- report confirmed chargebacks back to the scoring engine
- record authentication and credential reset events to spot account takeovers
- track event and ticket sales lifecycle changes

## Example prompts
- Check risk for this order via evaluate_order with the customer CPF and card payload
- Report a confirmed chargeback for this purchase using mark_order_fraudulent
- Log a failed authentication attempt using track_login

## Similar
- [REA](https://affpapa.org/en/nevibecode/mcp/rea.md) — MCP server · ★ 386989
- [World Monitor](https://affpapa.org/en/nevibecode/mcp/world-monitor.md) — MCP server · ★ 89408
- [mcp](https://affpapa.org/en/nevibecode/mcp/kubeshark-mcp.md) — MCP server · ★ 12109
- [Robin: AI-Powered Dark Web OSINT](https://affpapa.org/en/nevibecode/mcp/robin-ai-powered-dark-web-osint.md) — MCP server · ★ 7658
- [jshookmcp](https://affpapa.org/en/nevibecode/mcp/jshookmcp.md) — MCP server · ★ 2061
- [OpenOSINT](https://affpapa.org/en/nevibecode/mcp/openosint.md) — MCP server · ★ 1802

From the same set: [codespar/mcp-dev-latam](https://affpapa.org/en/nevibecode/by/codespar/mcp-dev-latam.md) — 124 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
