{
  "schema_version": "1.0",
  "organization": "p2-data-lab",
  "portal": "p2-mining-tcrc-royalty-calc",
  "live_meta_url": "https://p2-mining-tcrc-royalty-calc.pages.dev/data/meta.json",
  "openapi_url": "https://p2-mining-tcrc-royalty-calc.pages.dev/openapi.json",
  "public_datasets": [
    "https://p2-mining-tcrc-royalty-calc.pages.dev/data/mineral-rents-and-tariffs.json",
    "https://p2-mining-tcrc-royalty-calc.pages.dev/data/mining-nsr-tcrc-matrix.json"
  ],
  "calculator_inputs_schema": {
    "concentrate_commodity": {
      "label": "Mineral Concentrate / Intermediate Product",
      "type": "select",
      "default": "COPPER_SULFIDE_CONCENTRATE_2603",
      "options": [
        "COPPER_SULFIDE_CONCENTRATE_2603",
        "ZINC_SULFIDE_CONCENTRATE_2608",
        "NICKEL_MHP_MATTE_INTERMEDIATE",
        "LITHIUM_SPODUMENE_SC6_CONCENTRATE"
      ]
    },
    "mining_jurisdiction": {
      "label": "Mine Origin Jurisdiction (Statutory Royalty & FX Profile)",
      "type": "select",
      "default": "CHILE_ROYALTY_MINERO",
      "options": [
        "CHILE_ROYALTY_MINERO",
        "PERU_MODIFIED_MINING_ROYALTY",
        "AUSTRALIA_WA_QLD_AD_VALOREM",
        "CANADA_PROVINCIAL_NSR",
        "DRC_STRATEGIC_ROYALTY",
        "INDONESIA_EXPORT_DUTY_REGIME",
        "SWEDEN_FINLAND_NORDIC_EU"
      ]
    },
    "shipment_wet_tonnes_wmt": {
      "label": "Shipment Parcel Wet Mass (WMT — Wet Metric Tonnes)",
      "type": "number",
      "default": 10000,
      "min": 100,
      "max": 500000
    },
    "moisture_h2o_pct": {
      "label": "Moisture Content H2O (% — billed on ocean/inland freight, zero metal value)",
      "type": "number",
      "default": 8.5,
      "min": 0.5,
      "max": 20
    },
    "primary_head_grade_pct": {
      "label": "Primary Assay Head Grade (% Cu, % Zn, % Ni, or % Li2O)",
      "type": "number",
      "default": 27.5,
      "min": 1,
      "max": 75
    },
    "reference_metal_price_usd_t": {
      "label": "Quotational Period (QP M+1 / M+3) Reference Metal Price (USD / Metric Tonne)",
      "type": "number",
      "default": 9450,
      "min": 500,
      "max": 80000
    },
    "gold_credit_gpt": {
      "label": "By-Product Gold Assay Grade Au (g / DMT — payable above 1.0 g/t floor)",
      "type": "number",
      "default": 2.4,
      "min": 0,
      "max": 50
    },
    "silver_credit_gpt": {
      "label": "By-Product Silver Assay Grade Ag (g / DMT — payable above 30 g/t floor)",
      "type": "number",
      "default": 65,
      "min": 0,
      "max": 1000
    },
    "treatment_charge_usd_dmt": {
      "label": "Smelter Treatment Charge TC (USD / DMT)",
      "type": "number",
      "default": 40,
      "min": 0,
      "max": 450
    },
    "refining_charge_cents_lb": {
      "label": "Refining Charge RC (US cents / lb Payable Metal)",
      "type": "number",
      "default": 4,
      "min": 0,
      "max": 50
    },
    "arsenic_impurity_pct": {
      "label": "Deleterious Arsenic Assay As (% — penalized above 0.20% limit; >0.50% triggers blending/rejection)",
      "type": "number",
      "default": 0.32,
      "min": 0,
      "max": 2.5
    },
    "ocean_and_inland_freight_usd_wmt": {
      "label": "Mine-to-Smelter CIF Freight + Port/Assaying Cost (USD / WMT)",
      "type": "number",
      "default": 68,
      "min": 10,
      "max": 350
    }
  },
  "formulas_summary": {
    "dry_metric_tonnes_dmt": "DMT = shipment_wet_tonnes_wmt * (1 - moisture_h2o_pct / 100)",
    "payable_primary_metal_tonnes": "For Cu: Pay_Pct = min(primary_head_grade_pct * 0.965, primary_head_grade_pct - 1.0); For Zn: Pay_Pct = min(primary_head_grade_pct * 0.85, primary_head_grade_pct - 8.0); For SC6 Li2O: Lithia_Grade_ProRata = primary_head_grade_pct / 6.0; Payable_t = DMT * (Pay_Pct / 100)",
    "gross_payable_revenue_with_precious_credits": "Rev_Gross_USD = Payable_t * reference_metal_price_usd_t + DMT * Payable_Au_oz(gold_credit_gpt) * Au_Price_oz + DMT * Payable_Ag_oz(silver_credit_gpt) * Ag_Price_oz",
    "smelter_tc_rc_and_impurity_penalties": "Cost_TC_RC = DMT * treatment_charge_usd_dmt + (Payable_t * 2204.6226) * (refining_charge_cents_lb / 100) + Precious_Refining_USD; Penalty_Impurity = DMT * max(0, (arsenic_impurity_pct - 0.20) / 0.10) * 3.00_or_stepped_above_0.5pct",
    "wet_freight_and_moisture_tax": "Cost_Freight = shipment_wet_tonnes_wmt * ocean_and_inland_freight_usd_wmt (Moisture_Freight_Waste = (shipment_wet_tonnes_wmt - DMT) * ocean_and_inland_freight_usd_wmt)",
    "net_smelter_return_nsr_before_royalty": "NSR_Total_USD = Rev_Gross_USD - Cost_TC_RC - Penalty_Impurity - Cost_Freight; NSR_per_DMT = NSR_Total_USD / DMT",
    "statutory_royalty_and_export_duty": "Royalty_USD = NSR_Total_USD * Statutory_Royalty_Rate(mining_jurisdiction, concentrate_commodity); Net_Mine_Proceeds_USD = NSR_Total_USD - Royalty_USD"
  },
  "pro_api_endpoint": "https://p2-core-api.evsmtoken.workers.dev/v1/pro/p2-mining-tcrc-royalty-calc/dataset",
  "auth_header": "Authorization: Bearer <POLAR_LICENSE_KEY>",
  "purchase_tiers": [
    {
      "sku_key": "mining_nsr_royalty_dataset",
      "product_id": "cbcbd7a6-4ea0-4752-a489-21843d6cd7ae",
      "name": "Concentrate Smelter NSR & Rents Dataset",
      "price_usd": null,
      "billing": "one_time",
      "checkout_url": "https://buy.polar.sh/polar_cl_DMfzQxKnRK8I6WeKfVAxCvV1b1LzPMRstmliy12ozvT"
    },
    {
      "sku_key": "concentrate_trader_pro_license",
      "product_id": "fce71e3b-8669-48dc-961d-c4a9aabc3f8d",
      "name": "Pro Concentrate Blending & QP API Key",
      "price_usd": null,
      "billing": "one_time",
      "checkout_url": "https://buy.polar.sh/polar_cl_oE7NcpquqPNOvilmUqZCqIkyido58I9zIitQ11T2c18"
    },
    {
      "sku_key": "mine_cfo_offtake_negotiation_pack",
      "product_id": "8ebb4fef-b596-49ee-af00-6cc2c345f223",
      "name": "Mining CFO & Offtake Desk NSR Pack",
      "price_usd": null,
      "billing": "one_time",
      "checkout_url": "https://buy.polar.sh/polar_cl_sYuWf3ybVdGrPeUHryVajqqsVcqx0eD2b28zY4C3PRv"
    }
  ],
  "master_all_portals_pass": {
    "master_all_portals_pro_monthly": {
      "product_id": "18e0b844-b764-41f0-9c3d-186362784997",
      "name": "All-Portals Master Pro API & Batch CSV License Key (Monthly)",
      "price_usd": 79,
      "billing": "monthly",
      "checkout_url": "https://buy.polar.sh/polar_cl_0P1axu2nXEDXECK8Z0k7I3sMndeo3hsdqpepv1LUcJT"
    },
    "enterprise_annual_data_pass": {
      "product_id": "8a5266eb-3aaf-4fb3-9aef-0e5bbfd17dc3",
      "name": "Annual Enterprise FinOps & Compliance Data Pass (All Portals)",
      "price_usd": 499,
      "billing": "yearly",
      "checkout_url": "https://buy.polar.sh/polar_cl_SPWfsAxuQAVHif3soxwqbq5zPAdNZFkN5CtQK3cZRft"
    }
  }
}