{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/domani-run/json-schema/domani-run-backorder-schema.json",
  "title": "Backorder",
  "description": "A watch on a taken domain that auto-registers it when it drops",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/domani-run-backorders-api-openapi.yml#/components/schemas/Backorder",
  "type": "object",
  "properties": {
    "id": {
      "type": "string"
    },
    "domain": {
      "type": "string"
    },
    "status": {
      "type": "string",
      "enum": [
        "watching",
        "caught",
        "failed",
        "cancelled",
        "expired"
      ]
    },
    "payment_method": {
      "type": "string",
      "enum": [
        "card",
        "balance"
      ]
    },
    "max_price": {
      "type": "number",
      "description": "Max USD you'll pay to catch it"
    },
    "currency": {
      "type": "string"
    },
    "domain_expires": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "description": "Current registration's expiry (informational)"
    },
    "last_checked": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "attempts": {
      "type": "integer",
      "description": "Number of availability checks performed"
    },
    "caught_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "registered_domain_id": {
      "type": [
        "string",
        "null"
      ],
      "description": "ID of the Domain created when caught"
    },
    "failure_reason": {
      "type": [
        "string",
        "null"
      ],
      "enum": [
        "price_cap",
        "registration_race",
        "marketplace_listing",
        "payment",
        "registrar",
        "unavailable",
        "unexpected",
        "unspecified"
      ],
      "description": "Stable, language-independent failure code. Internal registrar prose is never returned."
    },
    "expires_at": {
      "type": "string",
      "format": "date-time",
      "description": "When the watch window ends"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}