{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/v3-news/json-schema/v3-news-validate-receipt-request-schema.json",
  "title": "ValidateReceiptRequest",
  "description": "Mobile client POST body after a successful StoreKit purchase.\n\nThe mobile SDK (react-native-iap) hands back two shapes depending\non platform / API version:\n\n  * ``transactionId`` + ``originalTransactionId`` + ``productId``\n    + ``signedTransaction`` (JWS) — modern StoreKit 2 path.\n  * Legacy ``transactionReceipt`` (base64) — StoreKit 1 fallback.\n\nWe accept either. The signed JWS is preferred (already verifiable\nagainst Apple's CA chain) — if absent we fall back to a transaction\ninfo lookup using the originalTransactionId via the App Store\nServer API.",
  "x-generated": "2026-11-27",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/v3-news-openapi.json#/components/schemas/ValidateReceiptRequest",
  "properties": {
    "transaction_id": {
      "type": "string",
      "title": "Transaction Id",
      "description": "StoreKit transactionId"
    },
    "original_transaction_id": {
      "type": "string",
      "title": "Original Transaction Id",
      "description": "StoreKit originalTransactionId — stable per-subscription ID"
    },
    "product_id": {
      "type": "string",
      "title": "Product Id",
      "description": "App Store Connect product ID"
    },
    "signed_transaction": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Signed Transaction",
      "description": "Signed JWS transactionInfo from StoreKit 2 (preferred path)"
    },
    "transaction_receipt": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Transaction Receipt",
      "description": "Base64 receipt from StoreKit 1 (fallback path)"
    },
    "environment": {
      "type": "string",
      "enum": [
        "Sandbox",
        "Production"
      ],
      "title": "Environment",
      "description": "Apple environment the purchase was made in. Mobile detects from the receipt; defaults to Production for live App Store buyers.",
      "default": "Production"
    }
  },
  "type": "object",
  "required": [
    "transaction_id",
    "original_transaction_id",
    "product_id"
  ]
}