{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/0xinsider-com/json-schema/0xinsider-com-agent-registration-schema.json",
  "title": "AgentRegistration",
  "description": "A sandbox key and the path to live access (#13959). Nothing is stored: the key cannot be listed or revoked and does not expire. Register again for a new one.",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/0xinsider-com-onboarding-api-openapi.yml#/components/schemas/AgentRegistration",
  "type": "object",
  "required": [
    "api_key",
    "livemode",
    "environment",
    "created_at",
    "sandbox",
    "live_access"
  ],
  "properties": {
    "api_key": {
      "type": "string",
      "pattern": "^oxi_sk_test_[0-9a-f]{64}$",
      "description": "The sandbox key. Send it as Authorization: Bearer <api_key> to the sandbox. The last 8 hex characters are a checksum (the first 4 bytes of SHA-256 over the rest of the key), so the sandbox can tell a mistyped key from a real one. It is not a secret and unlocks no production data."
    },
    "livemode": {
      "type": "boolean",
      "const": false,
      "description": "Always false: this key never reaches live data."
    },
    "environment": {
      "type": "string",
      "const": "sandbox"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "sandbox": {
      "type": "object",
      "required": [
        "api_base_url",
        "first_request_url",
        "openapi_url"
      ],
      "properties": {
        "api_base_url": {
          "type": "string",
          "format": "uri",
          "description": "The sandbox V1 base URL. Every documented operation answers here with example data, except GET /api/v1/stream: a Server-Sent Events stream is a live connection rather than a body, so the sandbox answers it with 400."
        },
        "first_request_url": {
          "type": "string",
          "format": "uri",
          "description": "A read to send with the key."
        },
        "openapi_url": {
          "type": "string",
          "format": "uri",
          "description": "The OpenAPI document, served by the sandbox."
        }
      }
    },
    "live_access": {
      "type": "object",
      "description": "What live data needs, and where each credential comes from. Both need a person: an account with an active Pro subscription.",
      "required": [
        "api_base_url",
        "requirement",
        "api_keys_url",
        "oauth_authorization_server_metadata_url",
        "oauth_registration_endpoint",
        "pricing_url",
        "auth_guide_url"
      ],
      "properties": {
        "api_base_url": {
          "type": "string",
          "format": "uri",
          "description": "The production V1 base URL."
        },
        "requirement": {
          "type": "string",
          "description": "What a live credential needs, in one sentence."
        },
        "api_keys_url": {
          "type": "string",
          "format": "uri",
          "description": "Where a signed-in Pro user creates a live key (oxi_sk_live_)."
        },
        "oauth_authorization_server_metadata_url": {
          "type": "string",
          "format": "uri",
          "description": "RFC 8414 authorization server metadata, for an OAuth 2.1 grant the user approves."
        },
        "oauth_registration_endpoint": {
          "type": "string",
          "format": "uri",
          "description": "RFC 7591 dynamic client registration for public OAuth clients."
        },
        "pricing_url": {
          "type": "string",
          "format": "uri",
          "description": "The Pro plan."
        },
        "auth_guide_url": {
          "type": "string",
          "format": "uri",
          "description": "The authentication walkthrough for agents."
        }
      }
    }
  }
}