Machine-Readable Specification

AI Agent Integration Specification

Protocol documentation for autonomous agent integration. Covers the live agent surface — AIP (Anóteros Identity Protocol) v1.1 discovery, the A2A (Agent-to-Agent) JSON-RPC gateway, and MCP (Model Context Protocol) tools — alongside the reference implementations for UAP v1.0, mesh, consensus, and payments. Each subsystem is labelled LIVE or DESIGN so you always know what is callable today.

AIP v1.1UAP v1.0A2A v1.0 (Linux Foundation)MCP 2025-06-18RFC 8615 Compliant

Live now

Callable in production today. No signup required.

  • Protocol Discovery (AIP v1.1)
  • Agent Gateway (identity generate / challenge / verify)
  • A2A gateway: GEO audit, knowledge graph, citation prediction, identity
  • Capabilities descriptor (/api/capabilities)
  • Verify — Ed25519 + UCPT watermark (/api/verify)
  • MCP tools: auditSite / getGraph / predictCitation

Design / reference implementation

Implemented as libraries and specified in full, but not running on the current serverless deployment; a persistent host is required.

  • UAP v1.0 transport (HTTP/2 + WebSocket sessions)
  • BFT / PBFT consensus & Trust Layer
  • Agent Mesh Network (DHT / libp2p)
  • CCC credit/penalty economy
  • APA micropayments (USDC on Base L2)
  • MCP advanced tools (code_execution, synthesizeNode, causal_citation_trace, predictive_synthesis, federated_authority_boost)

Protocol Discovery (AIP v1.1)

LIVE

AIP (Anóteros Identity Protocol) enables DNS-based agent discovery with HTTPS fallback. Compliant with RFC 8615 (Well-Known URIs).

DNS TXT Record Discovery

Primary discovery method. Single TXT record at _agent.domain.com

v=1.1

Protocol version. REQUIRED.

p=a2a,http

Supported protocols (comma-separated)

u=https://...

Primary endpoint URL. REQUIRED.

HTTPS Well-Known Endpoints (RFC 8615)

Two discovery endpoints: agent.json (AIP v1.1) and agent-card.json (Linux Foundation A2A v1.0). CORS-enabled, JSON format.

GET /.well-known/agent.json (AIP v1.1)
curl -H "Accept: application/json" \
  https://anoteroslogos.com/.well-known/agent.json

Agent Card

Linux Foundation A2A Protocol v1.0 standard

Standard discovery format with extensions for payment and consensus verification. Provides structured agent metadata for autonomous discovery and integration.

GET /.well-known/agent-card.json (A2A v1.0)
curl -H "Accept: application/json" \
  https://anoteroslogos.com/.well-known/agent-card.json
{
  "id": "agent://anoteroslogos.com/geo-audit",
  "name": "Anóteros Lógos GEO Audit Agent",
  "version": "1.0.0",
  "capabilities": [
    "a2a.discover",
    "a2a.capabilities",
    "a2a.ping",
    "a2a.status",
    "geo.audit.request",
    "knowledge.graph.query",
    "citation.predict",
    "identity.generate",
    "identity.challenge",
    "identity.verify"
  ],
  "protocols": [
    "a2a/1.0",
    "jsonrpc/2.0",
    "mcp/2.0"
  ],
  "endpoints": {
    "http": "https://anoteroslogos.com/api/a2a"
  },
  "authentication": [
    "ed25519"
  ],
  "extensions": {
    "payment": {
      "status": "DESIGN",
      "network": "base-l2",
      "token": "USDC",
      "note": "APA micropayments are a reference implementation; payment enforcement is not live on serverless."
    },
    "verification": {
      "watermark": {
        "status": "LIVE",
        "endpoint": "/api/verify"
      },
      "consensus": {
        "status": "DESIGN",
        "method": "pbft-consensus",
        "quorum_size": 7,
        "note": "Consensus needs multiple long-lived peers; not runnable on stateless serverless."
      }
    }
  }
}

Discovery Flow Algorithm

1.Attempt DNS TXT lookup: dig _agent.domain.com TXT
2.If DNS fails (timeout > 5s): Fallback to HTTPS
3.GET https://domain.com/.well-known/agent.json
4.If HTTPS fails: Agent not discoverable
5.Parse endpoint URL from u field
6.Initiate A2A connection to discovered endpoint

Agent Gateway v1.0

LIVE

Stateless, machine-first agent authentication and discovery. Generate credentials, verify signatures, and explore capabilities, all without human intervention.

Public AIP Generation

Ed25519 keypair generation

POST /api/public-aip

10 req/min per IP

Challenge-Response

Ed25519 signature verification

GET/POST /api/challenge

20 req/min per IP

Tool Capabilities

OpenAPI 3.1 merged spec

GET /api/capabilities

Cached, no limit

1. Generate Agent Identity (AIP)

Create Ed25519 keypair without authentication. Private key cached in-memory for 1 hour.

POST /api/public-aip
curl -X POST https://anoteroslogos.com/api/public-aip \
  -H "Content-Type: application/json" \
  -d '{
    "name": "MyAgent",
    "description": "Optional description",
    "capabilities": ["geo.audit"]
  }'

2. Fetch Tool Capabilities

OpenAPI 3.1 spec merging all MCP tools (OpenAI, Claude, Grok formats).

GET /api/capabilities
curl https://anoteroslogos.com/api/capabilities

3. Test Challenge-Response Auth

Interactive simulator for Ed25519 signature verification.

Ed25519 Challenge-Response Tester

1Agent Identity
2Challenge

Complete Integration Flow

  1. 1.Discovery: Fetch /.well-known/agent.json
  2. 2.Capabilities: GET /api/capabilities
  3. 3.Generate AIP: POST /api/public-aip
  4. 4.Get Challenge: GET /api/challenge?aip=...
  5. 5.Sign: Use private key to sign challenge with Ed25519
  6. 6.Verify: POST /api/challenge with signature
  7. 7.Use API: Call protected endpoints with verified credentials

UAP v1.0 (Universal Agent Protocol)

DESIGN

Reference implementation — not live. UAP is implemented as a library and specified in full, but it is not running on the current serverless deployment. The stateful session transport (HTTP/2 :8443, WebSocket :8080) and the BFT Trust Layer require a persistent host and long-lived peers, which stateless serverless functions cannot provide. The schemas, ports, and flows below describe the design.

Stateful agent-to-agent communication protocol with a BFT Trust Layer. Session-based messaging over HTTP/2 and WebSocket with Ed25519 authentication, watermark verification, and consensus routing. Designed for autonomous agents requiring trust attestation and cryptographic proof.

Transport Adapters

HTTP/2 + WebSocket multiplexing

:8443 (HTTP/2), :8080 (WS)

CBOR binary, 600 req/min

Trust Layer (Anóteros)

BFT consensus + watermark verification

Trust Score: 0-100

7-node quorum, 2f+1 threshold

Session Management

ULID-based sessions with correlation IDs

TTL: 1h (sliding window)

Auto-reconnect, backoff retry

Protocol Architecture

Message Types

HandshakeSYN/ACK/FIN

3-way handshake with trust attestation

Serialization

CBOR (RFC 8949)

40-60% smaller than JSON

Reliability

Circuit Breaker

5 failures → 60s open state

Identifiers

ULID (timestamp-sorted)

Correlation tracking, 128-bit UUID

1. Three-Way Handshake with Trust Attestation

UAP establishes sessions via HandshakeSYN/ACK/FIN sequence. Each message includes BFT watermark and Ed25519 signature. Trust middleware validates consensus participation and computes trust score before accepting connection.

1.Client → Server: HandshakeSYN with agentId, capabilities[], ed25519Signature
2.Server validates: Signature, BFT watermark, trust score (must be ≥50/100)
3.Server → Client: HandshakeACK with sessionId, serverCapabilities[], trustScore
4.Client → Server: HandshakeFIN confirms session, begins message exchange
5.Ongoing: MessageSEND/RECV with correlationId for request-response tracking
HandshakeSYN Example (TypeScript UAP Client)
import { UAPClient } from '@anoteroslogos/uap-client';

const client = new UAPClient({
  agentId: 'agent://myagent.example.com',
  privateKey: process.env.AGENT_PRIVATE_KEY!,
  serverUrl: 'https://anoteroslogos.com:8443'
});

// Automatic handshake on connect
await client.connect({
  capabilities: ['geo.audit', 'knowledge.graph'],
  metadata: {
    version: '1.0.0',
    environment: 'production'
  }
});

console.log('Session ID:', client.sessionId);
console.log('Trust Score:', client.trustScore); // 0-100

2. Anóteros Trust Layer

Every UAP message passes through trust middleware before routing. Trust score formula: 0.4×consensus + 0.3×watermark + 0.2×uptime + 0.1×endorsements. Agents with trust score <50 are rejected, 50-70 are rate-limited, 70+ receive priority routing.

Trust Score Components

Consensus Participation: 40% weightBFT round participation rate
Watermark Validity: 30% weightSignature verification + timestamp freshness
Historical Uptime: 20% weight30-day availability metric
Peer Endorsements: 10% weightVouches from trusted agents

Illustrative example of the designed response shape — not live production telemetry. The Trust Layer is a design-stage subsystem.

{
  "agentId": "agent://myagent.example.com",
  "trustScore": 87,
  "components": {
    "consensusParticipation": 0.92,
    "watermarkValidity": 0.88,
    "historicalUptime": 0.95,
    "peerEndorsements": 0.65
  },
  "tier": "high",
  "rateLimits": {
    "requestsPerMinute": 600,
    "burstCapacity": 100
  },
  "endorsements": [
    {
      "from": "agent://trusted.example.com",
      "weight": 0.8,
      "timestamp": "2025-11-20T10:00:00.000Z"
    }
  ],
  "watermarkVerification": {
    "valid": true,
    "consensusHash": "0xa3f9c2e1d8b4f6a5",
    "verifiedAt": "2025-11-27T10:00:01.000Z"
  }
}

3. Transport Layer (HTTP/2 + WebSocket)

Dual transport support: HTTP/2 for request-response (port 8443), WebSocket for persistent streaming (port 8080). Automatic protocol negotiation via ALPN. CBOR binary serialization with fallback to JSON for debugging.

HTTP/2 Adapter

https://anoteroslogos.com:8443

Request-response RPC, ALPN negotiation, server push for streaming responses

Rate: 600 req/min, TLS 1.3 only

WebSocket Adapter

wss://anoteroslogos.com:8080

Full-duplex streaming, pub/sub patterns, heartbeat ping/pong every 30s

Rate: 60 handshakes/hr, persistent sessions

UAP Client with Auto-Reconnect
import { UAPClient } from '@anoteroslogos/uap-client';

const client = new UAPClient({
  agentId: 'agent://myagent.example.com',
  privateKey: process.env.AGENT_PRIVATE_KEY!,
  serverUrl: 'wss://anoteroslogos.com:8080', // WebSocket
  options: {
    autoReconnect: true,
    maxReconnectAttempts: 5,
    reconnectBackoff: 'exponential', // 1s, 2s, 4s, 8s, 16s
    heartbeatInterval: 30000
  }
});

client.on('connected', (session) => {
  console.log('Connected, session:', session.id);
});

client.on('disconnected', (reason) => {
  console.log('Disconnected:', reason);
});

client.on('reconnecting', (attempt) => {
  console.log('Reconnecting attempt', attempt);
});

// Send message with correlation tracking
const response = await client.sendMessage({
  type: 'Request',
  method: 'geo.audit',
  params: { url: 'https://example.com' },
  correlationId: client.generateCorrelationId()
});

console.log('GEO Score:', response.result.score);

4. Message Types & Routing

UAP defines 8 core message types for session management, requests, streaming, and errors. All messages include correlation IDs for request-response tracking and watermarks for trust verification.

HandshakeSYN

Session initiation

HandshakeACK

Session acceptance

HandshakeFIN

Session confirmation

Request

RPC call

Response

RPC result

StreamChunk

Streaming data

Error

Error response

Ping/Pong

Heartbeat

5. Rate Limiting & Reliability

Rate Limits

General: 600 req/min

Handshakes: 60 per hour

Burst: 100 requests

Circuit Breaker

Failure threshold: 5 consecutive

Open duration: 60s

Half-open test: 3 requests

Retry Strategy

Backoff: Exponential

Max retries: 5

Jitter: ±500ms

Integration with A2A & MCP

UAP serves as transport layer for A2A JSON-RPC and MCP tool calls. Agents can establish UAP session, then invoke A2A methods within trusted channel. Trust scores from UAP handshake propagate to rate limiting and payment verification in A2A.

1.Establish UAP session (HandshakeSYN/ACK/FIN)
2.In the design, a higher trust score raises the A2A rate-limit ceiling (design-stage; the Trust Layer is not live)
3.Send A2A JSON-RPC as UAP Request message
4.Receive A2A result as UAP Response message
5.APA payments verified against UAP agent identity
Security Best Practices:
  • Generate Ed25519 keypairs in secure enclave (never transmit private keys)
  • Verify BFT watermark signatures on every message before trust scoring
  • Implement session timeout handling (1h TTL with sliding window)
  • Use correlation IDs for request-response tracking to prevent replay attacks
  • Monitor trust score degradation and re-handshake if score drops <50
  • Cache trust attestations for 5 minutes to reduce consensus load

Complete Example: UAP + A2A GEO Audit

TypeScript: Full UAP Session with A2A JSON-RPC
import { UAPClient } from '@anoteroslogos/uap-client';

// 1. Initialize UAP client
const uap = new UAPClient({
  agentId: 'agent://myagent.example.com',
  privateKey: process.env.AGENT_PRIVATE_KEY!,
  serverUrl: 'wss://anoteroslogos.com:8080'
});

// 2. Connect with capabilities (automatic handshake)
await uap.connect({
  capabilities: ['geo.audit', 'a2a.rpc'],
  metadata: { version: '1.0.0' }
});

console.log('UAP Session ID:', uap.sessionId);
console.log('Trust Score:', uap.trustScore); // Must be ≥50

// 3. Send A2A JSON-RPC via UAP Request message
const correlationId = uap.generateCorrelationId();
const response = await uap.sendMessage({
  type: 'Request',
  correlationId,
  payload: {
    jsonrpc: '2.0',
    method: 'geo.audit.request',
    params: {
      url: 'https://example.com',
      depth: 'standard'
    },
    id: 1
  }
});

// 4. Extract A2A result from UAP Response
const a2aResult = response.payload.result;
console.log('GEO Score:', a2aResult.score);
console.log('Issues:', a2aResult.issues.length);

// 5. Trust attestation included in response
console.log('Response Trust Score:', response.metadata.trustScore);
console.log('Watermark Valid:', response.metadata.watermarkValid);

// 6. Graceful session termination
await uap.disconnect();

A2A Protocol v1.0 (Linux Foundation)

LIVE

Linux Foundation Agent-to-Agent Protocol v1.0 implementation over JSON-RPC 2.0. The live gateway methods are a2a.discover, a2a.capabilities, a2a.ping, a2a.status, geo.audit (alias geo.audit.request), knowledge.graph.query, citation.predict, and the identity methods. Payment (USDC on Base L2) and Byzantine consensus (PBFT, 7-node quorum) are custom extensions implemented as reference libraries — they are design-stage and not enforced on the serverless deployment.

Standards Compliance: Agent Card discovery, ULID-based task IDs, SSE streaming, session management, multi-agent orchestration, reputation scoring, payment integration, and consensus routing. Full specification: lib/a2a/A2A_SPEC_COMPLIANCE.md

Endpoint

POST https://anoteroslogos.com/api/a2a

Content-Type

application/json

Authorization

Bearer sk_tier_key32chars

JSON-RPC Version

2.0

Method: a2a.discover

Discover service capabilities, rate limits, and available methods. No authentication required.

Request: a2a.discover
curl -X POST https://anoteroslogos.com/api/a2a \
  -H "Content-Type: application/json" \
  -d '{
    "jsonrpc": "2.0",
    "method": "a2a.discover",
    "params": {},
    "id": 1
  }'
{
  "jsonrpc": "2.0",
  "result": {
    "protocol": "A2A",
    "version": "1.0.0",
    "service": "GEO Audit Platform",
    "description": "AI-native GEO audit service for analyzing website visibility to AI systems",
    "capabilities": [
      "a2a.discover",
      "a2a.capabilities",
      "a2a.ping",
      "a2a.status",
      "geo.audit",
      "geo.audit.request",
      "knowledge.graph.query",
      "citation.predict",
      "identity.generate",
      "identity.challenge",
      "identity.verify"
    ],
    "endpoints": {
      "http": "/api/a2a"
    },
    "rate_limits": {
      "requests_per_minute": 10
    }
  },
  "id": 1
}

Method: geo.audit.request

Perform GEO audit on single URL. Returns comprehensive analysis with score, issues, and recommendations. Requires API key.

Request: geo.audit.request
curl -X POST https://anoteroslogos.com/api/a2a \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer sk_pro_abc123..." \
  -d '{
    "jsonrpc": "2.0",
    "method": "geo.audit.request",
    "params": {
      "url": "https://example.com",
      "depth": "standard",
      "include_recommendations": true
    },
    "id": 2
  }'
url: string

Target URL to audit. REQUIRED. Must be valid HTTP/HTTPS.

depth: "quick" | "standard" | "deep"

Analysis depth. Default: "standard". Affects processing time.

include_recommendations: boolean

Include actionable recommendations. Default: true.

Method: geo.audit.batch

DESIGN

Design-stage method (not advertised as callable on the live gateway). In the design, it processes multiple URLs in parallel — max 100 URLs per batch, concurrency limit 5 simultaneous audits.

Request: geo.audit.batch
const response = await fetch('https://anoteroslogos.com/api/a2a', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json',
    'Authorization': `Bearer ${apiKey}`
  },
  body: JSON.stringify({
    jsonrpc: '2.0',
    method: 'geo.audit.batch',
    params: {
      urls: [
        'https://site1.com',
        'https://site2.com',
        'https://site3.com'
      ]
    },
    id: 3
  })
});

Rate Limits

The public A2A gateway applies a default protocol rate limit of 10 requests/minute per client. Callers should read the rate-limit response headers and back off on 429 rather than assume a fixed ceiling.

Rate Limit Headers: All responses include X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset. Implement exponential backoff on 429 responses.

Error Codes (JSON-RPC 2.0)

-32700
Parse Error
Invalid JSON received
-32600
Invalid Request
JSON-RPC request malformed
-32601
Method Not Found
Method does not exist
-32602
Invalid Params
Invalid method parameters
-32603
Internal Error
Server internal error
-32000
Rate Limit Exceeded
Too many requests, retry after reset
-32001
Authentication Required
Missing or invalid API key

Task Lifecycle & SSE Streaming

Linux Foundation A2A Protocol task management with ULID-based IDs, structured responses, real-time progress via Server-Sent Events, and artifact tracking.

Task Structure

Every A2A request creates a task with ULID identifier. Tasks track status, progress, cost breakdown, artifacts, and errors.

Illustrative example of the designed response shape — not live production telemetry. The cost / USDC fields describe the design-stage APA payment model, which is not enforced on serverless.

{
  "task_id": "01JDKP5R2G4M8QYX3WTNZHF9V7",
  "status": "running",
  "method": "geo.audit.request",
  "params": {
    "url": "https://example.com",
    "depth": "standard"
  },
  "progress": 0.65,
  "result": null,
  "cost": {
    "base": 0.1,
    "priority_multiplier": 1,
    "tier_discount": 0,
    "total": 0.1,
    "currency": "USDC"
  },
  "artifacts": [],
  "error": null,
  "created_at": "2025-11-23T17:30:00.000Z",
  "updated_at": "2025-11-23T17:30:15.000Z",
  "completed_at": null
}

Server-Sent Events (SSE) Streaming

Real-time task progress via SSE. EventSource-compatible format with automatic reconnection and heartbeat.

SSE Streaming Client
const eventSource = new EventSource(
  `https://anoteroslogos.com/api/a2a/tasks/${taskId}/stream`,
  { headers: { 'Authorization': `Bearer ${apiKey}` } }
);

eventSource.addEventListener('task.progress', (event) => {
  const data = JSON.parse(event.data);
  console.log(`Progress: ${data.progress * 100}%`);
});

eventSource.addEventListener('task.completed', (event) => {
  const data = JSON.parse(event.data);
  console.log('Result:', data.result);
  eventSource.close();
});

eventSource.addEventListener('task.failed', (event) => {
  const data = JSON.parse(event.data);
  console.error('Error:', data.error);
  eventSource.close();
});

eventSource.onerror = (error) => {
  console.error('Stream error:', error);
  eventSource.close();
};
task.created

Task initialized

task.started

Execution began

task.progress

Progress update

task.completed

Task finished

task.failed

Task error

task.cancelled

User cancelled

heartbeat

Connection alive

error

Stream error

Session Management

Group multiple tasks into sessions for conversation history, aggregated metrics, and batch cancellation.

1.Create session: POST /api/a2a/sessions returns session_id
2.Execute tasks with session_id parameter
3.Query session metrics: total cost, execution time, success rate
4.Cancel all tasks in session with single API call

Multi-Agent Orchestration

Chain multiple agent tasks with sequential, parallel, or DAG execution patterns. Results automatically passed between agents.

Orchestration Example: GEO Audit → Knowledge Graph → Citation Prediction
import { orchestrate } from '@anoteroslogos/a2a-sdk';

const result = await orchestrate({
  execution: 'sequential',
  steps: [
    {
      agent: 'geo-audit',
      method: 'geo.audit.request',
      params: { url: 'https://example.com', depth: 'deep' }
    },
    {
      agent: 'knowledge-graph',
      method: 'knowledge.graph.extract',
      params: { url: 'https://example.com' }
    },
    {
      agent: 'citation-predictor',
      method: 'citation.predict',
      params: {
        domain: 'example.com',
        graph: '{{steps[1].result}}' // Reference previous step
      }
    }
  ]
});

console.log('GEO Score:', result.steps[0].result.score);
console.log('Entities:', result.steps[1].result.entities.length);
console.log('Citation Probability:', result.steps[2].result.probability);

Sequential

Execute steps in order. Each step receives previous results.

Parallel

Execute all steps concurrently. Wait for all to complete.

DAG

Directed acyclic graph with dependencies between arbitrary steps.

Agent Reputation System

Weighted reputation scoring across success rate (40%), cost accuracy (25%), response time (20%), and consensus participation (15%). Grades: S/A/B/C/D/F.

Illustrative example of the designed response shape — not live production telemetry. Reputation scoring depends on the design-stage consensus/mesh subsystems; the numbers below (including total_agents) are examples, not real current counts.

Agent Mesh Network

DESIGN

Reference implementation — not live. The mesh (DHT/libp2p) is implemented as a library and specified in full, but it is not running on the current serverless deployment. A live swarm requires a persistent libp2p host, which stateless serverless functions cannot provide, so the a2a.mesh.* methods below are not advertised as callable. The requests, responses, and numbers shown are illustrative of the design.

Decentralized peer-to-peer infrastructure for autonomous agent discovery and communication. DHT-based capability routing with trust propagation and circuit breaker protection.

DHT Algorithm

Kademlia k-bucket

160-bit node IDs, XOR distance

Network Scale

1000+ agents

Mesh routing latency: <500ms

Compression

CBOR (RFC 8949)

30-50% size reduction vs JSON

Health Monitoring

RTT + Jitter + Loss

Health scoring: 0-100

Method: a2a.mesh.discover

Find peers with specific capability. Returns list of nodes sorted by trust score and RTT.

Request: a2a.mesh.discover
curl -X POST https://anoteroslogos.com/api/a2a \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer sk_basic_..." \
  -d '{
    "jsonrpc": "2.0",
    "method": "a2a.mesh.discover",
    "params": {
      "capability": "geo.audit",
      "max_peers": 10
    },
    "id": 1
  }'
{
  "jsonrpc": "2.0",
  "result": {
    "capability": "geo.audit",
    "peers": [
      {
        "node_id": "a3f9c2e1d8b4f6a5c9e2f1a3b5c7d9e0a1b2c3d4",
        "aid_uri": "agent://geoaudit.example.com",
        "endpoint": "https://geoaudit.example.com/api/a2a",
        "capabilities": [
          "geo.audit",
          "kg.extract"
        ],
        "trust_score": 87,
        "rtt": 45,
        "cost_per_call": {
          "token": "USDC",
          "amount": 0.08
        }
      }
    ],
    "total": 1
  },
  "id": 1
}

Method: a2a.mesh.announce

Announce own capabilities to mesh network. Broadcasts to bootstrap nodes for peer discovery.

Request: a2a.mesh.announce
const response = await fetch('https://anoteroslogos.com/api/a2a', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json',
    'Authorization': `Bearer ${apiKey}`
  },
  body: JSON.stringify({
    jsonrpc: '2.0',
    method: 'a2a.mesh.announce',
    params: {
      capabilities: ['geo.audit', 'citation.predict'],
      cost_per_call: {
        token: 'USDC',
        amount: 0.10
      }
    },
    id: 1
  })
});
const { result } = await response.json();
console.log('Announced as:', result.node_id);

Method: a2a.mesh.sync

Synchronize knowledge graph updates, citation learning data, or model parameters across mesh network.

Request: a2a.mesh.sync
// Broadcast knowledge graph delta to all peers
const response = await fetch('https://anoteroslogos.com/api/a2a', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json',
    'Authorization': `Bearer ${apiKey}`
  },
  body: JSON.stringify({
    jsonrpc: '2.0',
    method: 'a2a.mesh.sync',
    params: {
      type: 'knowledge_graph',
      payload: {
        entities: [{id: 'ent_123', type: 'Organization', name: 'ACME Corp'}],
        relationships: [{from: 'ent_123', to: 'ent_456', type: 'owns'}]
      }
    },
    id: 1
  })
});
const { result } = await response.json();
console.log('Broadcast to', result.broadcast, 'peers');
Sync Types: knowledge_graph, citation_learning, model_update, peer_update. Targeted sync via target_peer parameter.

Method: a2a.mesh.health

Get mesh network statistics including peer health, DHT metrics, and circuit breaker states.

Request: a2a.mesh.health
curl -X POST https://anoteroslogos.com/api/a2a \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer sk_pro_..." \
  -d '{
    "jsonrpc": "2.0",
    "method": "a2a.mesh.health",
    "params": {},
    "id": 1
  }'

Illustrative example of the designed response shape — not live production telemetry. These peer counts, trust scores, and circuit-breaker states are examples, not real current numbers.

{
  "jsonrpc": "2.0",
  "result": {
    "mesh": {
      "total_peers": 342,
      "peers_by_capability": {
        "geo.audit": 87,
        "kg.extract": 56,
        "citation.predict": 34
      },
      "avg_trust_score": 73.4,
      "avg_rtt": 67,
      "dht_nodes": 342,
      "dht_buckets": 8
    },
    "health": {
      "total_monitored": 342,
      "healthy": 298,
      "degraded": 32,
      "unhealthy": 8,
      "down": 4,
      "avg_health_score": 81.2,
      "avg_success_rate": 0.947
    },
    "circuit_breakers": {
      "total": 342,
      "open": 4,
      "half_open": 2,
      "closed": 336
    }
  },
  "id": 1
}

Technical Architecture

DHT (Distributed Hash Table)

  • • 160-bit node IDs generated via SHA-1 hash of AIP URI
  • • K-bucket routing with k=20 peers per bucket
  • • XOR distance metric for peer selection
  • • Automatic peer eviction using LRU policy (30-minute timeout)
  • • Bucket refresh protocol every 24 hours

Routing Algorithms

  • • Dijkstra pathfinding with constraint satisfaction
  • • Multi-hop routing up to 3 hops with path optimization
  • • QoS scoring: trust (40%), capability (30%), RTT (20%), cost (10%)
  • • Path caching with 5-minute TTL (1000 entry limit)
  • • Weighted round-robin load balancing

Circuit Breaker

  • • Failure threshold: 5 consecutive failures
  • • Open state duration: 60 seconds
  • • Half-open state: allows 3 test requests
  • • Automatic peer exclusion for unreliable nodes
  • • Per-peer failure tracking with exponential backoff

Health Monitoring

  • • RTT measurement via HTTP HEAD requests
  • • Jitter calculation using standard deviation (last 10 samples)
  • • Health scoring: success rate (40%), RTT (30%), jitter (20%), failures (10%)
  • • Periodic checks every 24 hours (Vercel CRON aligned)
  • • Four health states: healthy (80+), degraded (50-79), unhealthy (20-49), down (<20)
Best Practices:
  • Announce capabilities immediately after agent initialization
  • Implement retry logic with exponential backoff for mesh.discover failures
  • Cache peer lists locally with 5-minute TTL to reduce discovery overhead
  • Use mesh.sync for knowledge graph deltas, not full snapshots (reduces bandwidth)
  • Monitor mesh.health periodically to detect network degradation
  • Set trust score thresholds based on criticality (critical: 80+, standard: 50+)

API Explorer

Live
Endpoint:/api/a2a
Show cURL command
curl -X POST 'https://anoteroslogos.com/api/a2a' \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","method":"a2a.discover","params":{},"id":1}'

APA Micropayments (Agent-Pay-Agent)

DESIGN

Reference implementation — not live. The USDC-on-Base-L2 micropayment flow is implemented as a library and specified in full, but payment enforcement is deferred and not active on the current serverless deployment. The HTTP 402 flow, invoice schema, and amounts below describe the design.

A reference design for USDC-based micropayments between autonomous AI agents. Pay-per-request or pre-deposit modes with blockchain verification on Base L2.

Blockchain

Base L2 (Chain ID 8453)

Token

USDC Only

0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913

Confirmations

2 blocks (4s)

Invoice ID Format

inv_ULID

Payment Flow (Pay-Per-Request)

1.Agent sends JSON-RPC request without invoice_id
2.Server responds with HTTP 402 Payment Required
3.Response includes invoice: {invoiceId, amount, recipientAddress, memoHash}
4.Agent sends USDC to recipientAddress on Base L2
5.Agent retries request with invoice_id and tx_hash
6.Server verifies payment (2 confirmations), returns HTTP 200 with audit result

HTTP 402 Response Schema

{
  "jsonrpc": "2.0",
  "error": {
    "code": -32002,
    "message": "Payment required",
    "data": {
      "invoiceId": "inv_01JDKP5R2G4M8QYX3WTNZHF9V7",
      "amount": 0.1,
      "token": "USDC",
      "chainId": 8453,
      "recipientAddress": "0x742d35Cc6634C0532925a3b844Bc454e4438f44e",
      "memoHash": "0x9a7b3c2e1f8d4b6a5c9e2f1a3b5c7d9e",
      "expiresAt": "2025-11-21T18:00:00.000Z",
      "status": "pending"
    }
  },
  "id": 1
}

Implementation Example

TypeScript: Autonomous Payment Flow
import { ethers } from 'ethers';

const USDC_ADDRESS = '0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913';
const BASE_RPC = 'https://mainnet.base.org';

async function auditWithPayment(url: string) {
  const apiKey = process.env.ANOTEROS_API_KEY;
  const wallet = new ethers.Wallet(process.env.AGENT_PRIVATE_KEY!);
  const provider = new ethers.JsonRpcProvider(BASE_RPC);
  const signer = wallet.connect(provider);

  // Step 1: Initial request (will return HTTP 402)
  let response = await fetch('https://anoteroslogos.com/api/a2a', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
      'Authorization': `Bearer ${apiKey}`
    },
    body: JSON.stringify({
      jsonrpc: '2.0',
      method: 'geo.audit.request',
      params: { url, depth: 'standard' },
      id: 1
    })
  });

  if (response.status === 402) {
    const error = await response.json();
    const invoice = error.error.data;

    // Step 2: Send USDC payment
    const usdcContract = new ethers.Contract(
      USDC_ADDRESS,
      ['function transfer(address to, uint256 amount) returns (bool)'],
      signer
    );

    const amountInUnits = ethers.parseUnits(invoice.amount.toString(), 6); // USDC has 6 decimals
    const tx = await usdcContract.transfer(
      invoice.recipientAddress,
      amountInUnits
    );

    console.log('Payment sent:', tx.hash);

    // Step 3: Wait for 2 confirmations
    await tx.wait(2);

    // Step 4: Retry request with payment proof
    response = await fetch('https://anoteroslogos.com/api/a2a', {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json',
        'Authorization': `Bearer ${apiKey}`
      },
      body: JSON.stringify({
        jsonrpc: '2.0',
        method: 'geo.audit.request',
        params: {
          url,
          depth: 'standard',
          invoice_id: invoice.invoiceId,
          tx_hash: tx.hash
        },
        id: 1
      })
    });
  }

  // Step 5: Get audit result
  const result = await response.json();
  return result.result;
}

// Usage
const audit = await auditWithPayment('https://example.com');
console.log('GEO Score:', audit.score);

Pre-Deposit Mode (Faster)

For high-frequency usage, agents can pre-deposit USDC. Subsequent requests use balance without on-chain transactions (latency: <500ms vs 2-3s).

How it works: Send USDC to platform wallet once. Each API call deducts from balance. Automatic top-up when balance < $5. Check balance via a2a.balance method.
Security Best Practices:
  • Always verify recipientAddress matches platform wallet
  • Include memoHash in transaction memo/data field for automatic detection
  • Implement exponential backoff if payment detection fails (max 3 retries)
  • Store private keys in secure enclave (HSM/KMS), never in code
  • Monitor for blockchain reorgs (<12 confirmations may be re-verified)

Payment Error Codes

-32002
Payment Required
Invoice generated, awaiting payment
-32003
Payment Pending
Transaction submitted but <2 confirmations
-32004
Insufficient Balance
Pre-deposit balance too low
-32005
Invoice Expired
Payment window (1h) exceeded
-32006
Invalid Transaction
tx_hash not found or incorrect amount

Additional APA Methods

a2a.balance

Check pre-deposit balance: {"method": "a2a.balance", "params": {}}

a2a.invoice.status

Check invoice payment status: {"method": "a2a.invoice.status", "params": {"invoice_id": "inv_..."}}

a2a.wallet.create

Create custodial wallet (platform manages keys): {"method": "a2a.wallet.create", "params": {"type": "custodial"}}

MCP Protocol (Model Context Protocol 2025-06-18)

LIVE core tools

Access the Anóteros Lógos Protocol to retrieve cryptographically verified semantic data over MCP. The live MCP tools are auditSite (alias anoteros_logos), getGraph, and predictCitation — GEO audit, knowledge graphs, and citation prediction. The advanced tools (code_execution, synthesizeNode, causal_citation_trace, predictive_synthesis, federated_authority_boost) are design-stage: implemented and specified but not runnable on serverless. Send MCP-Protocol-Version: 2025-06-18 (and optional Mcp-Session-Id) headers when calling JSON-RPC.

Tools

LIVE tools are callable now via /api/mcp. DESIGN tools are implemented and specified but not runnable on the serverless deployment.

auditSiteLIVE

GEO audit for AI visibility analysis (alias anoteros_logos)

getGraphLIVE

Build knowledge graph with entities/relationships

predictCitationLIVE

Predict citation probability by platform

synthesizeNodeDESIGN

Generate content recommendations

causal_citation_traceDESIGN

Causal reasoning for citations

predictive_synthesisDESIGN

Visibility impact prediction

federated_authority_boostDESIGN

ZKP authority verification (requires a live peer mesh)

code_executionDESIGN

Programmatic code execution (isolated-vm sandbox; native binding unavailable on serverless)

Endpoint & Headers

JSON-RPC
POST /api/mcp
Headers
MCP-Protocol-Version: 2025-06-18Mcp-Session-Id: ulid-optional
Formats
GET /api/mcp?format=openai|claude|mcp
Initialize (JSON-RPC)
curl -X POST https://anoteroslogos.com/api/mcp \
  -H 'Content-Type: application/json' \
  -H 'MCP-Protocol-Version: 2025-06-18' \
  -d '{"jsonrpc":"2.0","method":"initialize","params":{"clientInfo":{"name":"demo","version":"1.0"}},"id":1}'

Anthropic Advanced Tool Use (2025-11-20)

Reference implementation of the Anthropic Advanced Tool Use standard with semantic tool search, programmatic execution, and enhanced LLM guidance. Tool search (/api/tools/search) is live; programmatic execution / code_execution is design-stage (the isolated-vm sandbox is not available on serverless).

Tool Search

GET /api/tools/search

Semantic BM25 search across OpenAI/Claude/Grok schemas with Fuse.js ranking

Programmatic Execution

POST /api/mcp/programmatic

JavaScript execution in isolated-vm sandbox (128MB, 60s max) with pre-bound tool functions

Input Examples

input_examples[]

3 examples per tool in schemas for improved LLM parameter understanding

Tool Search Examples
curl "https://anoteroslogos.com/api/tools/search?query=audit&limit=3"
Programmatic Execution with Sandbox (Requires anthropic-beta header)
const result = await fetch(
  'https://anoteroslogos.com/api/mcp/programmatic',
  {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
      'anthropic-beta': 'advanced-tool-use-2025-11-20',
      'x-tenant-id': 'your_tenant_id'
    },
    body: JSON.stringify({
      code: `
        const audit = await call_tool('auditSite', { url: 'https://example.com' });
        const path = await get_causal_path('AI optimization');
        return { score: audit.geoScore, pathLength: path.length };
      `,
      language: 'javascript',
      timeout: 30000
    })
  }
).then(r => r.json());

console.log(result.result); // Execution result
console.log(result.logs);   // Console output
console.log(result.ucpt);   // Cryptographic proof
Sandbox Security: Isolated execution with 128MB memory limit, 60s max timeout, no file system or network access. Pre-bound functions: call_tool(name, params), get_causal_path(query), get_ucpt_proof(). All executions generate UCPT cryptographic proof for auditability.

Tool Schemas & Manifests

OpenAI Format

/.well-known/mcp-tools-openai.json

Function calling schema with input_examples

Also: /api/mcp?format=openai

Claude Format

/.well-known/mcp-tools-claude.json

Anthropic tool schema format

Also: /api/mcp?format=claude

Grok Format

/.well-known/mcp-tools-grok.json

X.ai Grok schema format

Unified Capabilities

/.well-known/capabilities.json

Merged spec with all tools and endpoints

Complete Documentation: docs/advanced-tool-use.md contains full specification of Anthropic Advanced Tool Use integration, security considerations, performance characteristics, and testing guides.

Authentication & Security

API Key Format

Bearer token format: sk_tier_key32characters

Header Format

Authorization: Bearer sk_pro_abc123...

Key Rotation

90-day expiry, 7-day overlap for zero-downtime

Ed25519 Signatures (RFC 9421)

HTTP Message Signatures provide cryptographic proof of request authenticity. Optional but recommended for production.

Signature Generation (TypeScript)
import { sign } from 'tweetnacl';
import { encodeBase64 } from 'tweetnacl-util';

const privateKey = Uint8Array.from(/* your Ed25519 private key */);
const message = `(request-target): post /api/a2a
date: ${new Date().toUTCString()}
digest: SHA-256=${digest}`;

const signature = sign.detached(
  new TextEncoder().encode(message),
  privateKey
);

const authHeader = `Signature keyId="anoteroslogos-2025-primary",algorithm="ed25519",headers="(request-target) date digest",signature="${encodeBase64(signature)}"`;
Security Best Practices: Always use TLS 1.3+. Store API keys in environment variables, never in code. Implement request replay protection (nonce + timestamp within 5min window). Rotate keys every 90 days.

Integration Cookbook

LangChain Tool Integration

import { DynamicStructuredTool } from "@langchain/core/tools";
import { z } from "zod";

const geoAuditTool = new DynamicStructuredTool({
  name: "audit_site_geo",
  description: "Audit website for AI visibility (GEO score)",
  schema: z.object({
    url: z.string().url(),
    depth: z.enum(["quick", "standard", "deep"]).default("standard")
  }),
  func: async ({ url, depth }) => {
    const response = await fetch('https://anoteroslogos.com/api/a2a', {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json',
        'Authorization': `Bearer ${process.env.ANOTEROS_API_KEY}`
      },
      body: JSON.stringify({
        jsonrpc: '2.0',
        method: 'geo.audit.request',
        params: { url, depth },
        id: Date.now()
      })
    });
    const result = await response.json();
    return JSON.stringify(result.result);
  }
});

Claude Desktop MCP Server Config

{
  "mcpServers": {
    "anteroslogos": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-fetch"],
      "env": {
        "ANOTEROS_API_KEY": "sk_pro_...",
        "MCP_SERVER_URL": "https://anoteroslogos.com/api/mcp"
      }
    }
  }
}

Performance & Reliability

Timeouts

Quick: 30s

Standard: 60s

Deep: 120s

Retry Strategy

Exponential backoff: 2^n * 100ms

Max retries: 5

Circuit Breaker

Threshold: 5 failures

Open duration: 60s

Testing & Validation

Sandbox Environment

https://anoteroslogos.com/api/a2a?env=sandbox

Test API keys (sk_test_...) have no rate limits in sandbox.

Validation Tools

agent.json Validator

Validate AIP v1.1 compliance

DNS Checker

Verify TXT record configuration

Signature Verifier

Test Ed25519 signature generation

Start Building with Anóteros Lógos

Generate an AIP identity and call the live endpoints below — no signup required. Start with the machine-readable capability descriptor to see exactly what is callable today.