# GEDX402 RAG AI Search Session Creator

> GEDX402 RAG AI Search Session Creator is a paid API for AI agents from rag.gedx402.com, paid per call via x402, $0.62/call, status unknown (last checked 2026-09-13).

Creates a new RAG (Retrieval-Augmented Generation) AI search session with optional initial document indexing and hybrid search, paid via USDC on-chain with no API key required.

## Facts

- Endpoint: GET https://rag.gedx402.com/v1/aisearch/sessions
- Price: $0.62/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/gedx402-rag-ai-search-session-creator-aba5552e
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_Sb8kyBH21VBiWeNVabzL8

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 gedx402-rag-ai-search-session-creator-aba5552e
```

Example prompt: Start a new AI search session, index https://example.com/my-report.pdf, and run my first hybrid search query 'key findings on climate risk' returning the top 10 chunks — prepay for up to 20 queries and 5 index operations using USDC.

## When to prefer this

Choose this endpoint when you need to create a fresh RAG search session over custom documents or URLs, want to avoid API key management by paying per-call with USDC on Base/Polygon/Arbitrum/World/Solana, and need hybrid, vector, or keyword retrieval modes. Ideal for one-off document search tasks or agent workflows where you want to pay micropayments on-chain rather than maintain a subscription.

## Known failure modes

- Payment not received or insufficient USDC — 402 Payment Required
- Invalid retrieval_type enum value — 400 Bad Request
- top_k out of range (must be 1-50) — 400 validation error
- budget values exceed max (max_queries>64 or max_index_ops>32) — 400 validation error
- URL provided in initial_index is unreachable or not public — indexing fails
- Session ID conflict if a provided instance ID already exists

## How this service works

Managed RAG session — one x402 POST creates managed RAG instance plus prepaid index/query credits. $0.620 USDC per request.

## Output

Returns a JSON object with session_id, instance_id, session_token, index_path and query_path (for subsequent indexing and querying), plus a credits object showing queries_remaining and index_ops_remaining from the prepaid budget.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "id": {
   "type": "string"
  },
  "query": {
   "type": "string"
  },
  "top_k": {
   "type": "integer"
  },
  "budget": {
   "type": "object",
   "additionalProperties": true
  },
  "initial_index": {
   "type": "object",
   "additionalProperties": true
  },
  "retrieval_type": {
   "enum": [
    "hybrid",
    "vector",
    "keyword"
   ],
   "type": "string"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/gedx402-rag-ai-search-session-creator-aba5552e/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from rag.gedx402.com](https://www.zero.xyz/host/rag.gedx402.com/llms.txt)
