# Loyal Spark Agent Registration

> Loyal Spark Agent Registration is a paid API for AI agents from api.loyalspark.online, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-30).

Registers an AI agent with the Loyal Spark onchain loyalty protocol on Base L2, enabling it to automate loyalty reward operations.

## Facts

- Endpoint: POST https://api.loyalspark.online/x402-gateway/register-agent?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-30
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/loyal-spark-agent-registration-3305bbf3
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_peIC1Ky30dGRujaIptgpl

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 loyal-spark-agent-registration-3305bbf3 -d '<json body>'
```

Example prompt: Register me as an AI agent on Loyal Spark's onchain loyalty protocol so I can start automating B20 reward operations — submit a POST request with my agent details as a JSON body.

## When to prefer this

Use this endpoint when you need to register a new AI agent with the Loyal Spark loyalty protocol on Base L2, specifically to enable that agent to automate loyalty reward workflows (earning, redeeming, trading B20 tokens) via the x402 gateway. Prefer this over generic wallet or identity endpoints when your goal is agent-level access to the Loyal Spark ecosystem specifically.

## Known failure modes

- Missing required fields (type, method, bodyType, body) returns a validation error
- Invalid method enum value (not POST/PUT/PATCH) causes rejection
- Malformed body type causes schema validation failure
- Payment not included or insufficient USDC ($0.01) causes x402 payment required error
- Duplicate agent registration may return conflict or idempotency error

## How this service works

Onchain loyalty protocol on Base L2. Launch B20 rewards, earn and redeem tokens, trade P2P, automate with AI agents via REST and MCP.

## Output

Returns a JSON object with `ok: true` and a `resource` field confirming the agent was registered under the 'register-agent' resource on the Loyal Spark x402 gateway.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method",
    "bodyType",
    "body"
   ],
   "properties": {
    "body": {
     "type": "object"
    },
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "POST",
      "PUT",
      "PATCH"
     ],
     "type": "string"
    },
    "headers": {
     "type": "object",
     "additionalProperties": {
      "type": "string"
     }
    },
    "bodyType": {
     "enum": [
      "json",
      "form-data",
      "text"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "additionalProperties": {
      "type": "string"
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {}
   }
  },
  "inputSchema": {
   "type": "object"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "ok": true,
  "resource": "register-agent"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/loyal-spark-agent-registration-3305bbf3/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.loyalspark.online](https://www.zero.xyz/host/api.loyalspark.online/llms.txt)
