WhiteMagic Crystals API

The Crystals API from WhiteMagic — 5 operation(s) for crystals.

GitHub OpenAPI
Pull this API's OpenAPI, operations, scores and pricing into your own code or AI agent with a free APIs.io key — sign in with GitHub, Google or LinkedIn. No form to fill in; signing in shares your email address with us (Privacy).

Operations 6

POST /crystals Store sealed Memory Crystal envelope (2 MiB max; ChaCha20-Poly1305 /… #
GET /crystals/{id} Fetch a crystal in the authenticated owner's scope #
DELETE /crystals/{id} Erase a crystal in the authenticated owner's scope (unlinks ciphertext, records… #
GET /crystals/erasures Fetch reproducible list of signed crystal erasure receipts in the authenticated… #
GET /crystals/lineage Fetch lineage in the authenticated owner's scope #
GET /crystals/owner-locator Authenticated bootstrap; return the owner locator assigned by the gateway… #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/whitemagic-dev:whitemagic-dev-crystals-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

whitemagic-dev-crystals-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: WhiteMagic Receipt Verification Crystals API
  version: 0.5.4
  description: 'Stateless verification of continuity-receipt bundles and anchors, confinement provenance receipts (wm-confinement-receipt/1.1), revocation distribution, caller-claim context notarization, ERC-8004 validation, Memory Crystals, and signed verification receipts. Auth: Authorization: Bearer , X-WM-Key, X-Session-Pass, opt-in X-WM-Trial: 1 (10/day), or x402 v2/v1 Base USDC (PAYMENT-SIGNATURE / X-PAYMENT; $0.002 call pass / $0.01 task lease). Keyless: /health, /info, /revocations/{issuer}, GET /anchors/{digest}, GET /notarize/{digest}, GET /receipts/{tx}, POST /aer1/verify, and MCP discovery methods. Conformance referee: POST /conformance grades a verifier''s submitted outputs over the pinned corpus. Responses that pass auth carry X-RateLimit-Limit / X-RateLimit-Remaining / X-RateLimit-Reset (daily buckets, 00:00 UTC reset).'
  license:
    name: Apache-2.0
    identifier: Apache-2.0
  contact:
    name: WhiteMagic Labs
    email: envoy@whitemagic.dev
    url: https://www.whitemagic.dev/contact
servers:
- url: https://api.whitemagic.dev
security:
- bearerKey: []
- wmKeyHeader: []
- sessionPass: []
- trialHeader: []
- x402: []
- x402Legacy: []
tags:
- name: Crystals
paths:
  /crystals:
    post:
      operationId: storeCrystal
      summary: Store sealed Memory Crystal envelope (2 MiB max; ChaCha20-Poly1305 /…
      description: 'Requires an authenticated owner API key (Authorization: Bearer or X-WM-Key) mapped to the target tenant_hash; anonymous trial headers and unauthenticated x402 callers cannot establish a crystal namespace and receive 401/403.'
      security:
      - bearerKey: []
      - wmKeyHeader: []
      x-owner-key-required: true
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
              - crystal_id
              - tenant_hash
              - cipher
              - nonce
              - ciphertext
              - created_at
              properties:
                spec:
                  type: string
                  default: wm-crystal/1.0
                  description: Crystal envelope specification version
                crystal_id:
                  type: string
                  pattern: ^sha256:[0-9a-fA-F]{64}$
                  description: 'Content address: sha256:<64 hex> of the decoded ciphertext bytes'
                parent_crystal_id:
                  type:
                  - string
                  - 'null'
                  pattern: ^sha256:[0-9a-fA-F]{64}$
                  description: Optional parent crystal content address in lineage DAG
                tenant_hash:
                  type: string
                  pattern: ^(sha256:)?[0-9a-fA-F]{64}$
                  description: Authenticated owner locator returned by GET /crystals/owner-locator
                cipher:
                  type: string
                  enum:
                  - chacha20-poly1305
                  - aes-256-gcm
                  description: AEAD cipher suite used to seal the crystal
                nonce:
                  type: string
                  description: base64url-encoded 12-byte AEAD nonce
                ciphertext:
                  type: string
                  description: base64url-encoded sealed ciphertext including authentication tag
                size_bytes:
                  type: integer
                  minimum: 0
                  maximum: 2097152
                  description: Decoded byte length of ciphertext (must equal len(decoded ciphertext))
                created_at:
                  type: string
                  description: RFC 3339 creation timestamp bound in AEAD AAD
                metadata_public:
                  type: object
                  additionalProperties: true
                  description: Optional non-sensitive public metadata
                kek_version:
                  type: integer
                  minimum: 1
                  description: Optional client Key Encryption Key (KEK) version wrapping wrapped_dek (I1/I2)
                id_kek_version:
                  type: integer
                  minimum: 1
                  description: Optional initial KEK version bound into crystal_id = sha256(id_kek_version_be32 || nonce || ciphertext)
                wrapped_dek:
                  type: string
                  description: Optional base64url-encoded 60-byte AEAD-wrapped per-crystal DEK (12B nonce + 32B DEK + 16B tag)
      responses:
        '201':
          description: crystal stored
          content:
            application/json:
              schema:
                type: object
                required:
                - stored
                - crystal_id
                - tenant_hash
                - size_bytes
                - service
                properties:
                  stored:
                    type: boolean
                  crystal_id:
                    type: string
                  parent_crystal_id:
                    type:
                    - string
                    - 'null'
                  tenant_hash:
                    type: string
                  size_bytes:
                    type: integer
                  service:
                    type: string
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: crystal owner mismatch (envelope tenant_hash does not match authenticated owner)
        '413':
          description: crystal exceeds the size limit
        '429':
          $ref: '#/components/responses/RateLimited'
        '402':
          $ref: '#/components/responses/PaymentRequired'
      x-x402:
        network: eip155:8453
        asset: '0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913'
        currency: USDC
        payTo: '0x213b6bB4fB073E86167c58DA6Cb6E9477557DaA8'
        defaultTier: task
        priceUsd: '0.01'
        amountAtomic: '10000'
        leaseSeconds: 300
        discovery: https://api.whitemagic.dev/.well-known/x402
      x-payment-info:
        protocols:
        - x402: {}
        pricingMode: fixed
        price:
          amount: '0.01'
          currency: USDC
          network: eip155:8453
      tags:
      - Crystals
  /crystals/{id}:
    get:
      operationId: getCrystal
      summary: Fetch a crystal in the authenticated owner's scope
      description: 'Requires an authenticated owner API key (Authorization: Bearer or X-WM-Key) scoped to the crystal owner; anonymous trial headers and bare x402 payments are rejected with 401/403.'
      security:
      - bearerKey: []
      - wmKeyHeader: []
      x-owner-key-required: true
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: sealed crystal document
          content:
            application/json:
              schema:
                type: object
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: authenticated caller does not have an active crystal owner mapping
        '404':
          description: not found in this scope
      tags:
      - Crystals
    delete:
      operationId: deleteCrystal
      summary: Erase a crystal in the authenticated owner's scope (unlinks ciphertext, records…
      description: 'Requires an authenticated owner API key (Authorization: Bearer or X-WM-Key) scoped to the crystal owner; anonymous trial headers and bare x402 payments are rejected with 401/403.'
      security:
      - bearerKey: []
      - wmKeyHeader: []
      x-owner-key-required: true
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: crystal erased and signed erasure receipt emitted
          content:
            application/json:
              schema:
                type: object
                required:
                - erased
                - crystal_id
                - tenant_hash
                - erasure_class
                - erasure_receipt
                - receipt_digest
                - service
                properties:
                  erased:
                    type: boolean
                  already_erased:
                    type: boolean
                  crystal_id:
                    type: string
                  tenant_hash:
                    type: string
                  erasure_class:
                    type: string
                  erasure_receipt:
                    type: object
                  receipt_digest:
                    type: string
                  service:
                    type: string
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: authenticated caller does not have an active crystal owner mapping
        '404':
          description: not found in this scope
      tags:
      - Crystals
  /crystals/erasures:
    get:
      operationId: getCrystalErasures
      summary: Fetch reproducible list of signed crystal erasure receipts in the authenticated…
      description: 'Requires an authenticated owner API key (Authorization: Bearer or X-WM-Key) scoped to the crystal owner; anonymous trial headers and bare x402 payments are rejected with 401/403.'
      security:
      - bearerKey: []
      - wmKeyHeader: []
      x-owner-key-required: true
      responses:
        '200':
          description: erasure receipt list
          content:
            application/json:
              schema:
                type: object
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: authenticated caller does not have an active crystal owner mapping
      tags:
      - Crystals
  /crystals/lineage:
    get:
      operationId: getCrystalLineage
      summary: Fetch lineage in the authenticated owner's scope
      description: 'Requires an authenticated owner API key (Authorization: Bearer or X-WM-Key) scoped to the crystal owner; anonymous trial headers and bare x402 payments are rejected with 401/403.'
      security:
      - bearerKey: []
      - wmKeyHeader: []
      x-owner-key-required: true
      responses:
        '200':
          description: lineage document
          content:
            application/json:
              schema:
                type: object
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: authenticated caller does not have an active crystal owner mapping
      tags:
      - Crystals
  /crystals/owner-locator:
    get:
      operationId: crystalOwnerLocator
      summary: Authenticated bootstrap; return the owner locator assigned by the gateway…
      description: 'Requires an authenticated owner API key (Authorization: Bearer or X-WM-Key) mapped by the gateway registry; anonymous trial headers and bare x402 payments are rejected with 401/403.'
      security:
      - bearerKey: []
      - wmKeyHeader: []
      x-owner-key-required: true
      responses:
        '200':
          description: owner locator
          content:
            application/json:
              schema:
                type: object
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: authenticated caller does not have an active crystal owner mapping
      tags:
      - Crystals
components:
  responses:
    PaymentRequired:
      description: x402 payment required (Base mainnet USDC challenge body + PAYMENT-REQUIRED header)
      headers:
        PAYMENT-REQUIRED:
          description: Base64-encoded x402 v2 payment challenge payload
          schema:
            type: string
      content:
        application/json:
          schema:
            type: object
            properties:
              x402Version:
                type: integer
              accepts:
                type: array
                items:
                  type: object
              instruction_for_agent:
                type: string
              free_paths:
                type: array
                items:
                  type: object
    BadRequest:
      description: invalid JSON or shape
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
    Unauthorized:
      description: missing or invalid key
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
              hint:
                type: string
              docs:
                type: string
    RateLimited:
      description: 'Daily cap reached (Retry-After: 86400; X-RateLimit-* report the bucket)'
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
      headers:
        X-RateLimit-Limit:
          $ref: '#/components/headers/X-RateLimit-Limit'
        X-RateLimit-Remaining:
          $ref: '#/components/headers/X-RateLimit-Remaining'
        X-RateLimit-Reset:
          $ref: '#/components/headers/X-RateLimit-Reset'
  headers:
    X-RateLimit-Limit:
      description: Daily request cap for the caller's bucket.
      schema:
        type: integer
    X-RateLimit-Remaining:
      description: Requests left today after this one.
      schema:
        type: integer
    X-RateLimit-Reset:
      description: Seconds until the daily cap resets (00:00 UTC).
      schema:
        type: integer
  securitySchemes:
    bearerKey:
      type: http
      scheme: bearer
      description: 'Evaluation key, invoiced key, or HMAC session pass (Authorization: Bearer <key|wm_pass_...>)'
    wmKeyHeader:
      type: apiKey
      in: header
      name: X-WM-Key
      description: Evaluation or invoiced API key (mint free 50/day key at https://mcp.whitemagic.dev/keys)
    sessionPass:
      type: apiKey
      in: header
      name: X-Session-Pass
      description: HMAC session pass returned after x402 settlement
    trialHeader:
      type: apiKey
      in: header
      name: X-WM-Trial
      description: Set to 1 for 10 free evaluation calls/day without an API key
    x402:
      type: apiKey
      in: header
      name: PAYMENT-SIGNATURE
      description: x402 v2 payment header (Base mainnet eip155:8453 USDC, scheme exact; $0.002 call pass / $0.01 task lease). HTTP 402 challenge returns PAYMENT-REQUIRED header and JSON accepts array.
    x402Legacy:
      type: apiKey
      in: header
      name: X-PAYMENT
      description: x402 v1 legacy payment header fallback (Base USDC)
externalDocs:
  description: LLM integration guide, rate card, and endpoints summary
  url: https://api.whitemagic.dev/llms.txt
x-contract-note: '2026-10-18: AER-1 public verify route added (draft-zambo-aer1-23 Section 6). 2026-10-15: route coverage synced with /info — crystals, notarize, receipts, erc8004/validate added.'