{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/flopsindex-com/json-schema/flopsindex-com-smpitransaction-schema.json",
  "title": "SMPITransaction",
  "description": "SMPI transaction: legacy gpu_model/purchase_date plus v7 sku/quality_tier/region/transaction_date.\n\nPhase H P0 #1 (2026-06-01): extra=\"ignore\" -> \"allow\" per the\nFleetSubmission docstring. SMPI submissions that include lender-side\nenrichment fields (institution_tier, reseller_attestation, etc.) per\nSubmission Guide §4.x were silently dropped before this change. Now\nextras flow to model_dump() and the Redis-stream persistence record.",
  "x-generated": "2026-11-08",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/flopsindex-com-openapi.json#/components/schemas/SMPITransaction",
  "properties": {
    "purchase_date": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Purchase Date"
    },
    "transaction_date": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Transaction Date"
    },
    "gpu_model": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Gpu Model"
    },
    "sku": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Sku"
    },
    "quantity": {
      "type": "integer",
      "minimum": 1.0,
      "title": "Quantity"
    },
    "unit_price_usd": {
      "type": "number",
      "exclusiveMinimum": 0.0,
      "title": "Unit Price Usd"
    },
    "memory_gb": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Memory Gb"
    },
    "form_factor": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Form Factor"
    },
    "source_type": {
      "type": "string",
      "enum": [
        "itad",
        "reseller",
        "marketplace"
      ],
      "title": "Source Type",
      "default": "marketplace"
    },
    "price_basis": {
      "type": "string",
      "enum": [
        "close",
        "ask"
      ],
      "title": "Price Basis",
      "default": "close"
    },
    "seller_id_hash": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Seller Id Hash"
    },
    "condition_description": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Condition Description"
    },
    "shipping_cost_usd": {
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "null"
        }
      ],
      "title": "Shipping Cost Usd"
    },
    "warranty_months": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Warranty Months"
    },
    "quality_tier": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "enterprise",
            "refurbished",
            "as_is"
          ]
        },
        {
          "type": "null"
        }
      ],
      "title": "Quality Tier"
    },
    "region": {
      "anyOf": [
        {
          "$ref": "#/$defs/Region"
        },
        {
          "type": "null"
        }
      ]
    }
  },
  "additionalProperties": true,
  "type": "object",
  "required": [
    "quantity",
    "unit_price_usd"
  ],
  "$defs": {
    "Region": {
      "type": "string",
      "enum": [
        "us_east",
        "us_west",
        "eu_west",
        "ap_southeast",
        "africa",
        "global"
      ],
      "title": "Region"
    }
  }
}