# Perplexity Context Embeddings via Locus x402

> Perplexity Context Embeddings via Locus x402 is a paid API for AI agents from perplexity.x402.paywithlocus.com, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-15).

Generates context-aware embeddings for text chunks using a shared parent document as grounding context, via Perplexity's contextualized embedding models.

## Facts

- Endpoint: POST https://perplexity.x402.paywithlocus.com/perplexity/context-embed
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/perplexity-context-embeddings-via-locus-x402-4f4662b4
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_XbtI_XM5Egs4EL_nXrGWc

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 perplexity-context-embeddings-via-locus-x402-4f4662b4 -d '<json body>'
```

Example prompt: Use Perplexity's context embedding model 'pplx-embed-context-v1-4b' to embed these three paragraph chunks from my research paper, using the full paper text as the shared document context so the embeddings capture the whole document's meaning.

## When to prefer this

Choose this endpoint when you need embeddings that are grounded in a shared parent document context — ideal for RAG pipelines where chunk meaning depends heavily on surrounding content. Prefer it over standard embedding APIs when document-level context significantly affects the semantics of individual chunks, such as legal documents, academic papers, or technical manuals. The pay-per-call x402 model makes it accessible without subscription commitments.

## Known failure modes

- Invalid model name returns an error — only 'pplx-embed-context-v1-0.6b' and 'pplx-embed-context-v1-4b' are valid
- Empty or malformed chunks array may result in empty embeddings or a 400 error
- Payment failure or insufficient USDC balance will block the request
- Excessively long document or chunk arrays may exceed token limits
- Missing required fields (model, chunks, or document) will cause a request error

## How this service works

AI-powered search — Sonar chat with real-time web grounding, web search, and embeddings.

## Output

Returns a JSON object with an embedding data payload (vectors for each chunk), a payment confirmation showing 0.001 USDC settled, and a request ID with a status URL for tracking the request.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "model": {
   "type": "string"
  },
  "chunks": {
   "type": "array",
   "items": {
    "type": "string"
   }
  },
  "document": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "data": {},
  "payment": {
   "scheme": "exact",
   "settledUsdc": "0.001000",
   "authorizedMaxUsdc": "0.001000"
  },
  "request": {
   "id": "00000000-0000-4000-8000-000000000000",
   "statusUrl": "/requests/00000000-0000-4000-8000-000000000000"
  },
  "success": true
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/perplexity-context-embeddings-via-locus-x402-4f4662b4/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from perplexity.x402.paywithlocus.com](https://www.zero.xyz/host/perplexity.x402.paywithlocus.com/llms.txt)
