{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/insumermodel-com/json-schema/insumermodel-com-nft-config-schema.json",
  "title": "NftConfig",
  "x-generated": "2026-10-30",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/insumermodel-com-openapi.json#/components/schemas/NftConfig",
  "type": "object",
  "required": [
    "name",
    "contractAddress",
    "chainId"
  ],
  "properties": {
    "name": {
      "type": "string",
      "maxLength": 50
    },
    "contractAddress": {
      "type": "string",
      "description": "Collection contract address, validated per chain: 0x + 40 hex on EVM chains; on Solana a verified collection address, which any NFT in that collection satisfies, or one NFT's mint address (base58, 32 to 44 characters; \"native\" is refused; an unverified collection tag never counts); the issuer r-address on XRPL, whose base58 checksum is verified. A malformed address returns 400."
    },
    "chainId": {
      "$ref": "#/$defs/OnboardingChainId"
    },
    "taxon": {
      "type": "integer",
      "description": "XRPL NFToken taxon filter. Optional, for filtering NFTs by collection under the same issuer. An integer from 0 to 4294967295; anything else is a 400. The XRPL issuer address is checksum-verified, so a mistyped issuer is a 400."
    },
    "benefitType": {
      "type": "string",
      "enum": [
        "discount",
        "recognition"
      ],
      "default": "discount",
      "description": "What holding the collection grants. \"discount\" applies the configured percentage; \"recognition\" only marks the pass as recognized (door access) and carries no discount."
    },
    "discount": {
      "type": "integer",
      "minimum": 1,
      "maximum": 50,
      "description": "Discount percentage: a whole number from 1 to 50, as a JSON number or its digits as a string. A value with a fraction (10.5) is a 400; \"10.0\" is accepted as 10. Required only when benefitType is \"discount\" (the default); ignored for \"recognition\"."
    },
    "enabled": {
      "type": "boolean",
      "default": true,
      "description": "Merchant's on/off toggle for this collection. Absent means enabled; only an explicit false disables it. A value that is not a boolean is a 400."
    }
  },
  "$defs": {
    "OnboardingChainId": {
      "oneOf": [
        {
          "type": "integer",
          "enum": [
            1,
            56,
            8453,
            43114,
            137,
            42161,
            10,
            88888,
            1868,
            98866,
            146,
            100,
            5000,
            534352,
            59144,
            324,
            81457,
            167000,
            2020,
            42220,
            88,
            204,
            480,
            130,
            57073,
            1329,
            80094,
            33139,
            50,
            4663,
            5042
          ]
        },
        {
          "type": "string",
          "enum": [
            "solana",
            "xrpl"
          ]
        }
      ],
      "description": "Chains supported for merchant token/NFT configuration: all 31 EVM chains (same integer IDs as ChainId) plus Solana (\"solana\") and XRP Ledger (\"xrpl\"). Bitcoin, Tron, Stellar, and Sui are not available for merchant registry configuration, though they remain queryable via /v1/attest and /v1/trust.\n"
    }
  }
}