# momoAI Code Review

> momoAI Code Review is a paid API for AI agents from aimomo.vercel.app, paid per call via x402, $0.08/call, status unknown (last checked 2026-09-15).

Submits source code for AI-powered review, returning a quality score, identified issues, and improvement suggestions.

## Facts

- Endpoint: POST https://aimomo.vercel.app/api/code
- Price: $0.08/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/momoai-code-review-76edc3cb
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_ZDOWR--MvxgDMUeAj-GyG

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability momoai-code-review-76edc3cb -d '<json body>'
```

Example prompt: Can you review this Python function for me and score it — focus on security issues: `def login(user, pw): return db.query(f'SELECT * FROM users WHERE user={user} AND pw={pw}')`?

## When to prefer this

Use this endpoint when you need a structured, scored code review with explicit issues and suggestions returned as machine-readable JSON, especially in automated pipelines or agents that need to programmatically act on review results. Prefer over general-purpose LLM chat endpoints when you want a consistent review schema with a numeric quality score.

## Known failure modes

- Missing required 'code' field returns validation error
- Payment failure or insufficient USDC balance prevents execution
- Unsupported or ambiguous language may reduce review accuracy
- Very large code inputs may be truncated or rejected
- Network timeout on Vercel serverless cold starts

## How this service works

Pay-per-use LLM API. Chat, reasoning, code review, translation, summarization, data extraction, and more. Pay with USDC on Base.

## Output

Returns a JSON object with a success flag, a review object containing an integer quality score (0-100), an array of identified issues, a summary string, and an array of suggestions, plus metadata including the detected or specified language, focus area, price paid, and timestamp.

## Example request

```json
{
 "code": "def calculate_sum(numbers):\n    total = 0\n    for num in numbers:\n        total += num\n    return total\n\nresult = calculate_sum([1, 2, 3, 4, 5])\nprint(result)",
 "focus": "code quality and best practices",
 "language": "python"
}
```

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "code"
 ],
 "properties": {
  "code": {
   "type": "string",
   "description": "Source code to review"
  },
  "focus": {
   "type": "string"
  },
  "language": {
   "type": "string",
   "description": "Programming language (auto-detect if omitted)"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "data": {
   "type": "object",
   "properties": {
    "model": {
     "type": "string"
    },
    "usage": {
     "type": "object"
    },
    "review": {
     "type": "object",
     "properties": {
      "score": {
       "type": "integer"
      },
      "issues": {
       "type": "array"
      },
      "summary": {
       "type": "string"
      },
      "suggestions": {
       "type": "array"
      }
     }
    }
   }
  },
  "meta": {
   "type": "object",
   "properties": {
    "focus": {
     "type": "string"
    },
    "price": {
     "type": "string"
    },
    "endpoint": {
     "type": "string"
    },
    "language": {
     "type": "string"
    },
    "timestamp": {
     "type": "string"
    }
   }
  },
  "success": {
   "type": "boolean"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/momoai-code-review-76edc3cb/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from aimomo.vercel.app](https://www.zero.xyz/host/aimomo.vercel.app/llms.txt)
