# PrimeAPI AI Similarity

> PrimeAPI AI Similarity is a paid API for AI agents from prime-api-seven.vercel.app, paid per call via x402, $0.097567/call, status unknown (last checked 2026-10-23).

Computes semantic similarity between a query string and other content, returning a similarity score or ranked results.

## Facts

- Endpoint: POST https://prime-api-seven.vercel.app/api/ai/similarity?utm_source=zero.xyz
- Price: $0.097567/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-23
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/primeapi-ai-similarity-50b0d55f
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_gA46MSu-Nxwib03v0CJAo

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 primeapi-ai-similarity-50b0d55f -d '<json body>'
```

Example prompt: How similar are these two sentences semantically: 'The stock market crashed today' and 'Equity prices fell sharply this morning'? Use the AI similarity endpoint to score them.

## When to prefer this

Choose this endpoint when you need a quick, pay-per-call semantic similarity computation without managing API keys or embeddings infrastructure. Best for lightweight agent workflows that need similarity scoring on demand in USDC on Base.

## Known failure modes

- Empty or missing query field returns a validation error
- Overly long query string may be truncated or rejected
- Payment failure in USDC on Base results in 402 response
- Ambiguous or very short queries may yield low-confidence similarity scores
- Service downtime on Vercel returns 503

## How this service works

Crypto, AI, Social Media, Finance, Weather, Tools &amp; more. Pay per call in USDC on Base. No API keys.

## Output

Returns a similarity score or ranked similarity results indicating how semantically close the query is to other content, likely as a numeric value between 0 and 1.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "query": {
   "type": "string",
   "description": "Search query or input parameter"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "description": "API response data"
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/primeapi-ai-similarity-50b0d55f/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from prime-api-seven.vercel.app](https://www.zero.xyz/host/prime-api-seven.vercel.app/llms.txt)
