{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/tgpaycrypto-com/json-schema/tgpaycrypto-com-app-info-schema.json",
  "title": "AppInfo",
  "x-generated": "2026-11-25",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/tgpaycrypto-com-openapi.json#/components/schemas/AppInfo",
  "type": "object",
  "required": [
    "app_id",
    "name",
    "payment_processing_bot_username",
    "webhook_url",
    "webhook_events",
    "scopes",
    "token_name",
    "daily_payout_max_usd_cents",
    "daily_payout_spent_usd_cents",
    "payout_mode",
    "onchain_pay_enabled"
  ],
  "properties": {
    "app_id": {
      "type": "string",
      "description": "The app's public ID, serialized as a string."
    },
    "name": {
      "type": "string"
    },
    "payment_processing_bot_username": {
      "type": "string",
      "description": "The Telegram bot whose Mini App processes payments."
    },
    "webhook_url": {
      "type": [
        "string",
        "null"
      ]
    },
    "webhook_events": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "invoice_expired",
          "check_activated",
          "refund_completed",
          "subscription_activated",
          "subscription_charged",
          "subscription_cancelled",
          "subscription_expired",
          "transfer_completed",
          "transfer_returned",
          "check_expired",
          "invoice_late_payment",
          "exchange_completed"
        ]
      },
      "description": "Selected extended webhook update types. invoice_paid is automatic when a URL is configured and is not listed here."
    },
    "scopes": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": "string",
        "enum": [
          "read",
          "invoices",
          "refunds",
          "payouts",
          "checks",
          "subscriptions",
          "webhooks",
          "withdraw",
          "exchange",
          "withdraw_links"
        ]
      },
      "description": "This token's scopes, sorted; null = the primary token (every scope except withdraw)."
    },
    "token_name": {
      "type": [
        "string",
        "null"
      ],
      "description": "The restricted token's label; null for the primary token."
    },
    "daily_payout_max_usd_cents": {
      "type": "integer",
      "minimum": 0,
      "description": "Owner-set rolling 24-hour payout ceiling in USD cents; 0 means no ceiling."
    },
    "daily_payout_spent_usd_cents": {
      "type": "integer",
      "minimum": 0,
      "description": "Spend currently counted toward the owner's rolling 24-hour payout limit, in USD cents. Includes transfers, checks and app withdrawals; invoice refunds are excluded."
    },
    "payout_mode": {
      "type": "string",
      "enum": [
        "off",
        "allowlist",
        "any"
      ],
      "description": "off disables API payouts; allowlist permits only owner-listed recipients; any permits any valid recipient, including bearer checks."
    },
    "onchain_pay_enabled": {
      "type": "boolean",
      "description": "Whether buyers can pay this app's invoices by a transfer to the invoice's own address (see getInvoiceAddress). Read-only here: the owner switches it in the Mini App (Accepting payments). Off for a new app."
    }
  }
}