# OpenAI-Compatible Text Embeddings API (768-dim, x402)

> OpenAI-Compatible Text Embeddings API (768-dim, x402) is a paid API for AI agents from twin.unykorn.org, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-02).

Generates 768-dimensional text embeddings for up to 32 strings per call using an OpenAI-compatible API, billed via x402 micropayments at $0.002 USDC per call.

## Facts

- Endpoint: POST https://twin.unykorn.org/v1/embeddings?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-02
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/openai-compatible-text-embeddings-api-768-dim-x402-676e5452
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_Md_XbGY-eNiDeboNg8dSh

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 openai-compatible-text-embeddings-api-768-dim-x402-676e5452 -d '<json body>'
```

Example prompt: Embed the following 5 product descriptions as 768-dimensional vectors so I can store them in my vector database for semantic search: 'wireless noise-cancelling headphones', 'ergonomic office chair', 'stainless steel water bottle', 'mechanical keyboard', 'USB-C hub'.

## When to prefer this

Choose this endpoint when you need OpenAI-compatible embeddings with a pay-per-call micropayment model (no subscription required), can tolerate 768-dim vectors instead of OpenAI's 1536-dim, and want batching of up to 32 inputs per call. Ideal for agents that need on-demand embedding without API key management, using x402-compatible wallets.

## Known failure modes

- Input array exceeds 32 items — request rejected with validation error
- Individual string exceeds 8000 character limit — truncation or rejection
- Payment not provided or insufficient USDC via x402 — 402 Payment Required response
- Invalid model name — may fall back to default or return an error
- Rate limits or server overload — 429 or 503 response

## How this service works

OpenAI-compatible text embeddings over x402 (768-dim, up to 32 inputs per call) — Genesis402 / UnyKorn Operator Network

## Output

Returns an OpenAI-compatible embeddings response object containing a list of embedding objects, each with a 768-dimensional float vector, the index of the input string, and model metadata. The response mirrors the OpenAI /v1/embeddings response format, making it drop-in compatible with OpenAI SDK clients.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "input": {
   "oneOf": [
    {
     "type": "string",
     "maxLength": 8000
    },
    {
     "type": "array",
     "items": {
      "type": "string",
      "maxLength": 8000
     },
     "maxItems": 32
    }
   ]
  },
  "model": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "ok": true,
  "data": [
   {
    "index": 0,
    "object": "embedding",
    "embedding": [
     0.012,
     -0.034,
     "…"
    ]
   }
  ],
  "model": "nomic-embed-text:latest",
  "object": "list",
  "receipt": {
   "tx_hash": "0x<64hex>",
   "amount_usd": 0.002,
   "receipt_id": "g402-<16hex>"
  },
  "dimensions": 768
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/openai-compatible-text-embeddings-api-768-dim-x402-676e5452/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from twin.unykorn.org](https://www.zero.xyz/host/twin.unykorn.org/llms.txt)
