{
  "openapi": "3.1.1",
  "info": {
    "title": "TON HTTP API C++",
    "description": "This API enables HTTP access to TON blockchain - getting accounts and wallets information, looking up blocks and transactions, sending messages to the blockchain, calling get methods of smart contracts, and more.\n\nIn addition to REST API, all methods are available through [JSON-RPC endpoint](#json%20rpc)  with `method` equal to method name and `params` passed as a dictionary.\n\nThe response contains a JSON object, which always has a boolean field `ok` and either `error` or `result`. If `ok` equals true, the request was successful and the result of the query can be found in the `result` field. In case of an unsuccessful request, `ok` equals false and the error is explained in the `error`.\n\nAPI Key should be sent either as `api_key` query parameter or `X-API-Key` header\n",
    "version": "v2.1.15-8bacaa3"
  },
  "paths": {
    "/api/v2/jsonRPC": {
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "JSON-RPC endpoint",
        "description": "All API methods are available through this single endpoint. Send the method name in the `method` field and parameters as a dictionary in `params`.",
        "operationId": "jsonRPC_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/JsonRpcRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the result of the specified JSON-RPC method call.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/detectAddress": {
      "get": {
        "tags": [
          "utils"
        ],
        "summary": "Detect address",
        "description": "Validates an address and returns it in all standard formats. Use this to convert between address formats or to validate user input. Returns raw format (0:abc), base64 bounceable (EQ), base64 non-bounceable (UQ), and URL-safe variants.",
        "operationId": "detectAddress_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/address"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the address in all supported formats (raw, bounceable, non-bounceable) with base64 and URL-safe variants.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Detect address",
        "description": "Validates an address and returns it in all standard formats. Use this to convert between address formats or to validate user input. Returns raw format (0:abc), base64 bounceable (EQ), base64 non-bounceable (UQ), and URL-safe variants.",
        "operationId": "detectAddress_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DetectAddressRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the address in all supported formats (raw, bounceable, non-bounceable) with base64 and URL-safe variants.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/detectHash": {
      "get": {
        "tags": [
          "utils"
        ],
        "summary": "Detect hash",
        "description": "Validates a hash and returns it in all standard formats. Use this to convert between hex (64 chars) and base64 (44 chars) representations. Works with any 256-bit hash including transaction hashes, block hashes, and message hashes.",
        "operationId": "detectHash_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/hash"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the hash in all supported formats (hex, base64, URL-safe base64).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Detect hash",
        "description": "Validates a hash and returns it in all standard formats. Use this to convert between hex (64 chars) and base64 (44 chars) representations. Works with any 256-bit hash including transaction hashes, block hashes, and message hashes.",
        "operationId": "detectHash_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DetectHashRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the hash in all supported formats (hex, base64, URL-safe base64).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/packAddress": {
      "get": {
        "tags": [
          "utils"
        ],
        "summary": "Pack address",
        "description": "Converts a raw address to user-friendly base64 format. Raw addresses use the format `workchain:hex` (e.g., `0:abc...`). The packed format is shorter and includes a checksum for error detection.",
        "operationId": "packAddress_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/address"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the address converted to user-friendly (base64) format.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Pack address",
        "description": "Converts a raw address to user-friendly base64 format. Raw addresses use the format `workchain:hex` (e.g., `0:abc...`). The packed format is shorter and includes a checksum for error detection.",
        "operationId": "packAddress_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PackAddressRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the address converted to user-friendly (base64) format.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/unpackAddress": {
      "get": {
        "tags": [
          "utils"
        ],
        "summary": "Unpack address",
        "description": "Converts a user-friendly base64 address to a raw address string in `workchain:hex` format.",
        "operationId": "unpackAddress_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/address"
          }
        ],
        "responses": {
          "200": {
            "description": "Converts a user-friendly base64 address to a raw address string in `workchain:hex` format.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Unpack address",
        "description": "Converts a user-friendly base64 address to a raw address string in `workchain:hex` format.",
        "operationId": "unpackAddress_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UnpackAddressRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Converts a user-friendly base64 address to a raw address string in `workchain:hex` format.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getAddressInformation": {
      "get": {
        "tags": [
          "accounts"
        ],
        "summary": "Get Address Information",
        "description": "Returns the current state of any account on the TON blockchain. Includes the balance (in nanotons), smart contract code and data (if deployed), account status, and a reference to the last transaction. This is the primary endpoint for checking if an address exists and what's deployed there.",
        "operationId": "getAddressInformation_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/address"
          },
          {
            "$ref": "#/components/parameters/seqnoOptional"
          }
        ],
        "responses": {
          "200": {
            "description": "The complete current state of the requested account.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Address Information",
        "description": "Returns the current state of any account on the TON blockchain. Includes the balance (in nanotons), smart contract code and data (if deployed), account status, and a reference to the last transaction. This is the primary endpoint for checking if an address exists and what's deployed there.",
        "operationId": "getAddressInformation_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AddressInformationRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "The complete current state of the requested account.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getExtendedAddressInformation": {
      "get": {
        "tags": [
          "accounts"
        ],
        "summary": "Get Extended Address Information",
        "description": "Returns detailed account information with parsed contract state. For recognized contract types, returns type-specific state fields. For other contracts, returns the raw state.",
        "operationId": "getExtendedAddressInformation_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/address"
          },
          {
            "$ref": "#/components/parameters/seqnoOptional"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns detailed account information including parsed contract state and type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Extended Address Information",
        "description": "Returns detailed account information with parsed contract state. For recognized contract types, returns type-specific state fields. For other contracts, returns the raw state.",
        "operationId": "getExtendedAddressInformation_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ExtendedAddressInformationRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns detailed account information including parsed contract state and type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getShardAccountCell": {
      "get": {
        "tags": [
          "accounts"
        ],
        "summary": "Get Shard Address Cell",
        "description": "Get raw TVM cell with shard account",
        "operationId": "getShardAccountCell_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/address"
          },
          {
            "$ref": "#/components/parameters/seqnoOptional"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Shard Address Cell",
        "description": "Get raw TVM cell with shard account",
        "operationId": "getShardAccountCell_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ShardAccountCellRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getWalletInformation": {
      "get": {
        "tags": [
          "accounts"
        ],
        "summary": "Get Wallet Information",
        "description": "Returns wallet-specific information for an address. If the address is a known wallet contract, returns the wallet type, current `seqno` (needed for sending transactions), and wallet_id. Always check `wallet: true` before using wallet-specific fields. Call this before sending any transaction to get the current `seqno`.",
        "operationId": "getWalletInformation_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/address"
          },
          {
            "$ref": "#/components/parameters/seqnoOptional"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns wallet-specific details: type, `seqno`, subwallet ID, and balance.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Wallet Information",
        "description": "Returns wallet-specific information for an address. If the address is a known wallet contract, returns the wallet type, current `seqno` (needed for sending transactions), and wallet_id. Always check `wallet: true` before using wallet-specific fields. Call this before sending any transaction to get the current `seqno`.",
        "operationId": "getWalletInformation_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WalletInformationRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns wallet-specific details: type, `seqno`, subwallet ID, and balance.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getAddressBalance": {
      "get": {
        "tags": [
          "accounts"
        ],
        "summary": "Get Address Balance",
        "description": "Returns the TON balance of an account in nanotons. 1 TON = 1,000,000,000 nanotons. A lightweight endpoint that returns only the balance without contract code, data, or other account details. Returns \"0\" for addresses that have never received any funds.",
        "operationId": "getAddressBalance_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/address"
          },
          {
            "$ref": "#/components/parameters/seqnoOptional"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the account balance in nanotons.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Address Balance",
        "description": "Returns the TON balance of an account in nanotons. 1 TON = 1,000,000,000 nanotons. A lightweight endpoint that returns only the balance without contract code, data, or other account details. Returns \"0\" for addresses that have never received any funds.",
        "operationId": "getAddressBalance_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AddressBalanceRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the account balance in nanotons.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getAddressState": {
      "get": {
        "tags": [
          "accounts"
        ],
        "summary": "Get Address State",
        "description": "Returns the account lifecycle state: `uninitialized` (no contract deployed), `active` (contract deployed), or `frozen` (contract state frozen).",
        "operationId": "getAddressState_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/address"
          },
          {
            "$ref": "#/components/parameters/seqnoOptional"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the account lifecycle state: `uninitialized` (no contract deployed), `active` (contract deployed), or `frozen` (contract state frozen).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Address State",
        "description": "Returns the account lifecycle state: `uninitialized` (no contract deployed), `active` (contract deployed), or `frozen` (contract state frozen).",
        "operationId": "getAddressState_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AddressStateRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the account lifecycle state: `uninitialized` (no contract deployed), `active` (contract deployed), or `frozen` (contract state frozen).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getTokenData": {
      "get": {
        "tags": [
          "accounts"
        ],
        "summary": "Get Token Data",
        "description": "Returns metadata for Jetton or NFT contracts. Automatically detects the contract type and returns appropriate fields. For Jetton masters: total supply, admin, metadata. For Jetton wallets: balance, owner. For NFT items: collection, owner, content. For NFT collections: item count, metadata.",
        "operationId": "getTokenData_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/address"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns parsed token metadata for Jetton masters, Jetton wallets, NFT collections, and NFT items.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Token Data",
        "description": "Returns metadata for Jetton or NFT contracts. Automatically detects the contract type and returns appropriate fields. For Jetton masters: total supply, admin, metadata. For Jetton wallets: balance, owner. For NFT items: collection, owner, content. For NFT collections: item count, metadata.",
        "operationId": "getTokenData_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TokenDataRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns parsed token metadata for Jetton masters, Jetton wallets, NFT collections, and NFT items.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/dnsResolve": {
      "get": {
        "tags": [
          "accounts"
        ],
        "summary": "Resolve TON DNS name",
        "description": "Resolve TON DNS contract",
        "operationId": "dnsResolve_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/address"
          },
          {
            "name": "name",
            "in": "query",
            "description": "Domain name to resolve",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "category",
            "in": "query",
            "description": "Get a specific category of DNS record",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "ttl",
            "in": "query",
            "description": "TTL of a resolved record",
            "required": false,
            "schema": {
              "type": "int",
              "format": "int32"
            }
          },
          {
            "$ref": "#/components/parameters/seqnoOptional"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Resolve TON DNS name",
        "description": "Resolve TON DNS contract",
        "operationId": "dnsResolve_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DnsResolveRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getMasterchainInfo": {
      "get": {
        "tags": [
          "blocks"
        ],
        "summary": "Get Masterchain Info",
        "description": "Returns the current state of the TON masterchain. The `last` field contains the latest block used for querying current state. The `seqno` in `last` is the current block height. Use this endpoint to obtain the latest block reference for other queries.",
        "operationId": "getMasterchainInfo_get",
        "parameters": [],
        "responses": {
          "200": {
            "description": "The current masterchain state, including the latest block identifier, its state root hash, and the genesis block reference. Use `result.last.seqno` as the current block height.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Masterchain Info",
        "description": "Returns the current state of the TON masterchain. The `last` field contains the latest block used for querying current state. The `seqno` in `last` is the current block height. Use this endpoint to obtain the latest block reference for other queries.",
        "operationId": "getMasterchainInfo_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MasterchainInfoRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "The current masterchain state, including the latest block identifier, its state root hash, and the genesis block reference. Use `result.last.seqno` as the current block height.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getMasterchainBlockSignatures": {
      "get": {
        "tags": [
          "blocks"
        ],
        "summary": "Get Masterchain Block Signatures",
        "description": "Returns validator signatures for a specific masterchain block. Each signature proves that a validator approved this block. Use this for building cryptographic proofs or verifying block authenticity in trustless applications.",
        "operationId": "getMasterchainBlockSignatures_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/seqno"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns validator signatures for the specified masterchain block.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Masterchain Block Signatures",
        "description": "Returns validator signatures for a specific masterchain block. Each signature proves that a validator approved this block. Use this for building cryptographic proofs or verifying block authenticity in trustless applications.",
        "operationId": "getMasterchainBlockSignatures_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MasterchainBlockSignaturesRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns validator signatures for the specified masterchain block.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getShardBlockProof": {
      "get": {
        "tags": [
          "blocks"
        ],
        "summary": "Get Shard Block Proof",
        "description": "Returns a Merkle proof that links a shardchain block to a masterchain block. This proof cryptographically verifies that the shard block is part of the canonical chain. Used by light clients and cross-chain bridges to verify shard data without trusting the API.",
        "operationId": "getShardBlockProof_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/workchain"
          },
          {
            "$ref": "#/components/parameters/shard"
          },
          {
            "$ref": "#/components/parameters/seqno"
          },
          {
            "name": "from_seqno",
            "in": "query",
            "description": "Seqno of masterchain block starting from which proof is required. If not specified latest masterchain block is used",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a cryptographic proof chain linking a shard block to the masterchain.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Shard Block Proof",
        "description": "Returns a Merkle proof that links a shardchain block to a masterchain block. This proof cryptographically verifies that the shard block is part of the canonical chain. Used by light clients and cross-chain bridges to verify shard data without trusting the API.",
        "operationId": "getShardBlockProof_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ShardBlockProofRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns a cryptographic proof chain linking a shard block to the masterchain.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getConsensusBlock": {
      "get": {
        "tags": [
          "blocks"
        ],
        "summary": "Get Consensus Block",
        "description": "Get block that was confirmed by consensus",
        "operationId": "getConsensusBlock_get",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Consensus Block",
        "description": "Get block that was confirmed by consensus",
        "operationId": "getConsensusBlock_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ConsensusBlockRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/lookupBlock": {
      "get": {
        "tags": [
          "blocks"
        ],
        "summary": "Lookup Block",
        "description": "Finds a block by position or time. Specify workchain and shard, then provide exactly one of `seqno` (block sequence number), `lt` (logical time), or `unixtime` (Unix timestamp). Returns the full block identifier including hashes.",
        "operationId": "lookupBlock_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/workchain"
          },
          {
            "$ref": "#/components/parameters/shard"
          },
          {
            "$ref": "#/components/parameters/seqnoOptional"
          },
          {
            "name": "lt",
            "in": "query",
            "description": "Logical time of a block",
            "required": false,
            "schema": {
              "type": "string",
              "x-usrv-cpp-format": "std::int64_t"
            }
          },
          {
            "name": "unixtime",
            "in": "query",
            "description": "UNIX timestamp of a block",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the full block identifier matching the given `seqno`, logical time, or unix timestamp.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Lookup Block",
        "description": "Finds a block by position or time. Specify workchain and shard, then provide exactly one of `seqno` (block sequence number), `lt` (logical time), or `unixtime` (Unix timestamp). Returns the full block identifier including hashes.",
        "operationId": "lookupBlock_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LookupBlockRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the full block identifier matching the given `seqno`, logical time, or unix timestamp.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getShards": {
      "get": {
        "tags": [
          "blocks"
        ],
        "summary": "Get Shards",
        "description": "Returns the active shardchain block identifiers at a given masterchain block height. Each shard processes a subset of accounts in parallel. The response shows how the basechain is currently partitioned and which block each shard is at.",
        "operationId": "getShards_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/seqno",
            "description": "Seqno of masterchain block"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the list of active shard block identifiers at the specified masterchain block.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Shards",
        "description": "Returns the active shardchain block identifiers at a given masterchain block height. Each shard processes a subset of accounts in parallel. The response shows how the basechain is currently partitioned and which block each shard is at.",
        "operationId": "getShards_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ShardsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the list of active shard block identifiers at the specified masterchain block.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getBlock": {
      "get": {
        "tags": [
          "blocks"
        ],
        "summary": "Get Block",
        "description": "Get raw block data as a base64-encoded BOC",
        "operationId": "getBlock_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/workchain"
          },
          {
            "$ref": "#/components/parameters/shard"
          },
          {
            "$ref": "#/components/parameters/seqno"
          },
          {
            "$ref": "#/components/parameters/rootHashOptional"
          },
          {
            "$ref": "#/components/parameters/fileHashOptional"
          },
          {
            "$ref": "#/components/parameters/archivalOptional"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Block",
        "description": "Get raw block data as a base64-encoded BOC",
        "operationId": "getBlock_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BlockDataRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getBlockHeader": {
      "get": {
        "tags": [
          "blocks"
        ],
        "summary": "Get Block Header",
        "description": "Returns block metadata without the full transaction list. Includes timestamps, validator info, and references to previous blocks. Intended for block explorers and other use cases that require block information without transactions.",
        "operationId": "getBlockHeader_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/workchain"
          },
          {
            "$ref": "#/components/parameters/shard"
          },
          {
            "$ref": "#/components/parameters/seqno"
          },
          {
            "$ref": "#/components/parameters/rootHashOptional"
          },
          {
            "$ref": "#/components/parameters/fileHashOptional"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the block header with merge/split flags, validator info, and timing data.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Block Header",
        "description": "Returns block metadata without the full transaction list. Includes timestamps, validator info, and references to previous blocks. Intended for block explorers and other use cases that require block information without transactions.",
        "operationId": "getBlockHeader_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BlockHeaderRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the block header with merge/split flags, validator info, and timing data.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getOutMsgQueueSize": {
      "get": {
        "tags": [
          "blocks"
        ],
        "summary": "Get Out Msg Queue Size",
        "description": "Returns the current size of the outbound message queue for each shard. A growing queue indicates network congestion. If the queue is large, transactions may take longer to process. Monitor this to detect network issues.",
        "operationId": "getOutMsgQueueSize_get",
        "responses": {
          "200": {
            "description": "Outgoing message queue sizes for all active shards. A growing queue indicates network congestion and may cause transaction delays.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Out Msg Queue Size",
        "description": "Returns the current size of the outbound message queue for each shard. A growing queue indicates network congestion. If the queue is large, transactions may take longer to process. Monitor this to detect network issues.",
        "operationId": "getOutMsgQueueSize_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OutMsgQueueSizeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Outgoing message queue sizes for all active shards. A growing queue indicates network congestion and may cause transaction delays.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getBlockTransactions": {
      "get": {
        "tags": [
          "transactions"
        ],
        "summary": "Get Block Transactions",
        "description": "Returns a summary of transactions in a specific block. Each item contains the account address and transaction ID, but not full transaction details. Use `count` to limit results and `after_lt`/`after_hash` for pagination. Call getTransactions with each transaction ID to get full details.",
        "operationId": "getBlockTransactions_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/workchain"
          },
          {
            "$ref": "#/components/parameters/shard"
          },
          {
            "$ref": "#/components/parameters/seqno"
          },
          {
            "$ref": "#/components/parameters/rootHashOptional"
          },
          {
            "$ref": "#/components/parameters/fileHashOptional"
          },
          {
            "$ref": "#/components/parameters/afterLtOptional"
          },
          {
            "$ref": "#/components/parameters/afterAccountHashOptional"
          },
          {
            "$ref": "#/components/parameters/countOptional"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns short transaction identifiers (account, lt, hash) for transactions in the specified block.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Block Transactions",
        "description": "Returns a summary of transactions in a specific block. Each item contains the account address and transaction ID, but not full transaction details. Use `count` to limit results and `after_lt`/`after_hash` for pagination. Call getTransactions with each transaction ID to get full details.",
        "operationId": "getBlockTransactions_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BlockTransactionsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns short transaction identifiers (account, lt, hash) for transactions in the specified block.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getBlockTransactionsExt": {
      "get": {
        "tags": [
          "transactions"
        ],
        "summary": "Get Block Transactions Extended",
        "description": "Returns full transaction objects for transactions in a specific block. Each transaction includes complete data: inbound and outbound messages, fees, and BoC-encoded raw data. Use `count` to limit results and `after_lt`/`after_hash` for pagination when `incomplete` is true.",
        "operationId": "getBlockTransactionsExt_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/workchain"
          },
          {
            "$ref": "#/components/parameters/shard"
          },
          {
            "$ref": "#/components/parameters/seqno"
          },
          {
            "$ref": "#/components/parameters/rootHashOptional"
          },
          {
            "$ref": "#/components/parameters/fileHashOptional"
          },
          {
            "$ref": "#/components/parameters/afterLtOptional"
          },
          {
            "$ref": "#/components/parameters/afterAccountHashOptional"
          },
          {
            "$ref": "#/components/parameters/countOptional"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns full transaction objects for transactions in the specified block.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Block Transactions Extended",
        "description": "Returns full transaction objects for transactions in a specific block. Each transaction includes complete data: inbound and outbound messages, fees, and BoC-encoded raw data. Use `count` to limit results and `after_lt`/`after_hash` for pagination when `incomplete` is true.",
        "operationId": "getBlockTransactionsExt_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BlockTransactionsExtRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns full transaction objects for transactions in the specified block.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getTransactions": {
      "get": {
        "tags": [
          "transactions"
        ],
        "summary": "Get Transactions",
        "description": "Returns transaction history for an account. Transactions are returned newest-first. Each transaction shows the incoming message that triggered it, all outgoing messages, and fees paid. For pagination: use the `lt` and `hash` from the oldest transaction as the starting point for the next request.",
        "operationId": "getTransactions_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/address"
          },
          {
            "$ref": "#/components/parameters/limitOptional"
          },
          {
            "$ref": "#/components/parameters/ltOptional"
          },
          {
            "$ref": "#/components/parameters/hashOptional",
            "description": "SHA-256 transaction hash to start pagination from"
          },
          {
            "$ref": "#/components/parameters/toLtOptional"
          },
          {
            "$ref": "#/components/parameters/archivalOptional"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns a list of transactions for the specified account, ordered by logical time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Transactions",
        "description": "Returns transaction history for an account. Transactions are returned newest-first. Each transaction shows the incoming message that triggered it, all outgoing messages, and fees paid. For pagination: use the `lt` and `hash` from the oldest transaction as the starting point for the next request.",
        "operationId": "getTransactions_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TransactionsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns a list of transactions for the specified account, ordered by logical time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getTransactionsStd": {
      "get": {
        "tags": [
          "transactions"
        ],
        "summary": "Get Transactions Std",
        "description": "Returns transaction history for an account in a standardized format. Transactions are returned newest-first. Each transaction includes the triggering inbound message, all outbound messages, and fees paid. The response includes a `previous_transaction_id` cursor for paginating through older transactions.",
        "operationId": "getTransactionsStd_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/address"
          },
          {
            "$ref": "#/components/parameters/limitOptional"
          },
          {
            "$ref": "#/components/parameters/ltOptional"
          },
          {
            "$ref": "#/components/parameters/hashOptional",
            "description": "SHA-256 transaction hash to start pagination from"
          },
          {
            "$ref": "#/components/parameters/toLtOptional"
          },
          {
            "$ref": "#/components/parameters/archivalOptional"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns transactions in standardized format with a pagination cursor.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Transactions Std",
        "description": "Returns transaction history for an account in a standardized format. Transactions are returned newest-first. Each transaction includes the triggering inbound message, all outbound messages, and fees paid. The response includes a `previous_transaction_id` cursor for paginating through older transactions.",
        "operationId": "getTransactionsStd_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TransactionsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns transactions in standardized format with a pagination cursor.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/tryLocateTx": {
      "get": {
        "tags": [
          "transactions"
        ],
        "summary": "Try Locate Transaction",
        "description": "Finds a transaction by message parameters. Given a source address, destination address, and message creation time (created_lt), returns the transaction that processed this message. Useful for locating when a previously sent message was executed.",
        "operationId": "tryLocateTx_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/sourceAddress"
          },
          {
            "$ref": "#/components/parameters/destinationAddress"
          },
          {
            "$ref": "#/components/parameters/createdLt"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the transaction matching the given source, destination, and created logical time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Try Locate Transaction",
        "description": "Finds a transaction by message parameters. Given a source address, destination address, and message creation time (created_lt), returns the transaction that processed this message. Useful for locating when a previously sent message was executed.",
        "operationId": "tryLocateTx_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TryLocateTxRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the transaction matching the given source, destination, and created logical time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/tryLocateResultTx": {
      "get": {
        "tags": [
          "transactions"
        ],
        "summary": "Try Locate Result Transaction",
        "description": "Finds the transaction that received a specific message. Given message parameters, returns the transaction on the destination account that processed the incoming message. Use this to trace message delivery across accounts.",
        "operationId": "tryLocateResultTx_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/sourceAddress"
          },
          {
            "$ref": "#/components/parameters/destinationAddress"
          },
          {
            "$ref": "#/components/parameters/createdLt"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the resulting transaction on the destination account for the given message.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Try Locate Result Transaction",
        "description": "Finds the transaction that received a specific message. Given message parameters, returns the transaction on the destination account that processed the incoming message. Use this to trace message delivery across accounts.",
        "operationId": "tryLocateResultTx_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TryLocateResultTxRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the resulting transaction on the destination account for the given message.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/tryLocateSourceTx": {
      "get": {
        "tags": [
          "transactions"
        ],
        "summary": "Try Locate Source Transaction",
        "description": "Finds the transaction that sent a specific message. Given message parameters, returns the transaction on the source account that created this outgoing message. Useful for tracing where a message originated from.",
        "operationId": "tryLocateSourceTx_get",
        "parameters": [
          {
            "$ref": "#/components/parameters/sourceAddress"
          },
          {
            "$ref": "#/components/parameters/destinationAddress"
          },
          {
            "$ref": "#/components/parameters/createdLt"
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the originating transaction on the source account for the given message.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Try Locate Source Transaction",
        "description": "Finds the transaction that sent a specific message. Given message parameters, returns the transaction on the source account that created this outgoing message. Useful for tracing where a message originated from.",
        "operationId": "tryLocateSourceTx_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TryLocateSourceTxRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the originating transaction on the source account for the given message.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getConfigParam": {
      "get": {
        "tags": [
          "configuration"
        ],
        "summary": "Get Config Parameter",
        "description": "Returns a specific blockchain configuration parameter. TON stores all network settings on-chain as numbered parameters. Common ones: 0 (config contract), 1 (elector), 15 (election timing), 17 (stake limits), 20-21 (gas prices), 34 (current validators). Check TON documentation for the full list.",
        "operationId": "getConfigParam_get",
        "parameters": [
          {
            "name": "param",
            "in": "query",
            "description": "Parameter number",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "seqno",
            "in": "query",
            "description": "Block `seqno`",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the specified blockchain configuration parameter as a TVM cell.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Config Parameter",
        "description": "Returns a specific blockchain configuration parameter. TON stores all network settings on-chain as numbered parameters. Common ones: 0 (config contract), 1 (elector), 15 (election timing), 17 (stake limits), 20-21 (gas prices), 34 (current validators). Check TON documentation for the full list.",
        "operationId": "getConfigParam_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ConfigParamRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the specified blockchain configuration parameter as a TVM cell.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getConfigAll": {
      "get": {
        "tags": [
          "configuration"
        ],
        "summary": "Get All Config",
        "description": "Returns all blockchain configuration parameters at once. Includes gas prices, validator settings, workchain configs, and governance rules. Use the optional `seqno` to get historical configuration at a specific block height.",
        "operationId": "getConfigAll_get",
        "parameters": [
          {
            "name": "seqno",
            "in": "query",
            "description": "Block `seqno`",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returns all blockchain configuration parameters as a single TVM cell.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get All Config",
        "description": "Returns all blockchain configuration parameters at once. Includes gas prices, validator settings, workchain configs, and governance rules. Use the optional `seqno` to get historical configuration at a specific block height.",
        "operationId": "getConfigAll_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ConfigAllRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns all blockchain configuration parameters as a single TVM cell.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/getLibraries": {
      "get": {
        "tags": [
          "configuration"
        ],
        "summary": "Get Libraries",
        "description": "Returns smart contract library code by hash. Some contracts reference shared libraries instead of including all code directly. When a library reference appears in contract code, this endpoint fetches the actual library implementation.",
        "operationId": "getLibraries_get",
        "parameters": [
          {
            "name": "libraries",
            "in": "query",
            "description": "Hashes of libraries",
            "required": false,
            "schema": {
              "type": "array",
              "items": {
                "type": "#/components/schemas/TonHash"
              }
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returns the code of the requested shared library cells.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      },
      "post": {
        "tags": [
          "rpc"
        ],
        "summary": "Get Libraries",
        "description": "Returns smart contract library code by hash. Some contracts reference shared libraries instead of including all code directly. When a library reference appears in contract code, this endpoint fetches the actual library implementation.",
        "operationId": "getLibraries_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LibrariesRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the code of the requested shared library cells.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/runGetMethod": {
      "post": {
        "tags": [
          "run method",
          "rpc"
        ],
        "summary": "Run Get Method",
        "description": "Executes a read-only method on a smart contract. Get methods query contract state without sending a transaction. Common methods include `seqno` (wallet sequence number), `get_wallet_data` (wallet info), and `get_jetton_data` (token info). Method arguments are provided in the `stack` array.",
        "operationId": "runGetMethod_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RunGetMethodRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the TVM stack output and exit code from executing the specified get method.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/runGetMethodStd": {
      "post": {
        "tags": [
          "run method",
          "rpc"
        ],
        "summary": "Run Get Method Std",
        "description": "Executes a read-only method on a smart contract using typed stack entries. Input and output stack entries use explicit types (`TvmStackEntryNumber`, `TvmStackEntryCell`, etc.) for structured input/output handling. Common methods: `seqno` (wallet sequence number), `get_wallet_data` (wallet info), `get_jetton_data` (token info).",
        "operationId": "runGetMethodStd_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RunGetMethodStdRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the get method result in standardized stack format.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/sendBoc": {
      "post": {
        "tags": [
          "send",
          "rpc"
        ],
        "summary": "Send BOC",
        "description": "Broadcasts a signed message to the TON network. The `boc` parameter must contain a complete, signed external message in base64 format. The API validates the message and forwards it to validators. Returns immediately after acceptance; use getTransactions to confirm the transaction was processed.",
        "operationId": "sendBoc_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendBocRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns a success confirmation after broadcasting the serialized message to the network.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/sendBocReturnHash": {
      "post": {
        "tags": [
          "send",
          "rpc"
        ],
        "summary": "Send BOC Return Hash",
        "description": "Broadcasts a signed message to the TON network and returns the message hash. The `boc` parameter must contain a complete, signed external message in base64 format. The API validates the message and forwards it to validators. The returned hash can be used to track the message's processing status.",
        "operationId": "sendBocReturnHash_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendBocRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the message hash after broadcasting the serialized message to the network.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    },
    "/api/v2/estimateFee": {
      "post": {
        "tags": [
          "send",
          "rpc"
        ],
        "summary": "Estimate Fee",
        "description": "Calculates the fees required to send a message. Provide the destination address and message body. For new contract deployments, also include init_code and init_data. Set ignore_chksig to true when estimating before signing. Returns a breakdown of storage, gas, and forwarding fees.",
        "operationId": "estimateFee_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EstimateFeeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Returns the estimated fees (gas, storage, forwarding) for the specified message.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TonlibResponse"
                }
              }
            }
          },
          "default": {
            "$ref": "#/components/responses/default"
          }
        },
        "security": [
          {
            "APIKeyHeader": []
          },
          {
            "APIKeyQuery": []
          }
        ]
      }
    }
  },
  "tags": [
    {
      "name": "utils",
      "description": "Some useful methods"
    },
    {
      "name": "accounts",
      "description": "Information about accounts"
    },
    {
      "name": "blocks",
      "description": "Information about blocks"
    },
    {
      "name": "transactions",
      "description": "Fetching and locating transactions"
    },
    {
      "name": "configuration",
      "description": "Information about blockchain config"
    },
    {
      "name": "run method",
      "description": "Run get-method of smart contracts"
    },
    {
      "name": "send",
      "description": "Send data to blockchain"
    },
    {
      "name": "rpc",
      "description": "JSON-RPC and POST endpoints"
    }
  ],
  "components": {
    "parameters": {
      "address": {
        "name": "address",
        "in": "query",
        "description": "The account address to query, in raw or user-friendly format.",
        "required": true,
        "schema": {
          "$ref": "#/components/schemas/TonAddr"
        }
      },
      "hash": {
        "name": "hash",
        "in": "query",
        "description": "The 256-bit hash in any form",
        "required": true,
        "schema": {
          "$ref": "#/components/schemas/TonHash"
        }
      },
      "hashOptional": {
        "name": "hash",
        "in": "query",
        "description": "The 256-bit hash in any form",
        "required": false,
        "schema": {
          "$ref": "#/components/schemas/TonHash"
        }
      },
      "workchain": {
        "name": "workchain",
        "in": "query",
        "description": "The workchain to query. Use `-1` for masterchain (validators, system contracts, config) or `0` for basechain (regular accounts and contracts). Most user transactions happen on workchain `0`.",
        "required": true,
        "schema": {
          "type": "integer",
          "format": "int32"
        }
      },
      "shard": {
        "name": "shard",
        "in": "query",
        "description": "The shard identifier. Masterchain always uses `-9223372036854775808`. For basechain, shards split and merge dynamically. Use the `shards` endpoint to discover current shard configuration.",
        "required": true,
        "schema": {
          "type": "string",
          "x-usrv-cpp-type": "std::int64_t"
        }
      },
      "seqno": {
        "name": "seqno",
        "in": "query",
        "description": "Block sequence number within the specified workchain and shard.",
        "required": true,
        "schema": {
          "type": "integer",
          "format": "int32"
        }
      },
      "seqnoOptional": {
        "name": "seqno",
        "in": "query",
        "description": "Query state at a specific block height. If omitted, returns the current state. Use this to look up historical data at a specific point in time.",
        "required": false,
        "schema": {
          "type": "integer",
          "format": "int32"
        }
      },
      "rootHashOptional": {
        "name": "root_hash",
        "in": "query",
        "description": "The block's root hash. Together with `file_hash`, uniquely identifies a block.",
        "required": false,
        "schema": {
          "type": "string",
          "x-usrv-cpp-type": "#/components/schemas/TonHash"
        }
      },
      "fileHashOptional": {
        "name": "file_hash",
        "in": "query",
        "description": "The block's file hash. Together with `root_hash`, uniquely identifies a block.",
        "required": false,
        "schema": {
          "type": "string",
          "x-usrv-cpp-type": "#/components/schemas/TonHash"
        }
      },
      "afterLtOptional": {
        "name": "after_lt",
        "in": "query",
        "description": "Pagination cursor. Pass the `lt` value from the last item in the previous response to get the next page. Transactions and messages are ordered by logical time.",
        "required": false,
        "schema": {
          "type": "string",
          "x-usrv-cpp-format": "std::int64_t"
        }
      },
      "afterAccountHashOptional": {
        "name": "after_hash",
        "in": "query",
        "description": "Account ID in hex or base64 for block transaction pagination. Use together with `after_lt` from the last transaction in the previous page.",
        "required": false,
        "schema": {
          "type": "string",
          "x-usrv-cpp-type": "#/components/schemas/TonAddrWithoutWorkchain"
        }
      },
      "countOptional": {
        "name": "count",
        "in": "query",
        "description": "Maximum number of items to return. The default is 40. Use smaller values for faster responses or larger values to reduce the number of API calls.",
        "required": false,
        "schema": {
          "type": "integer",
          "format": "int64",
          "default": 40
        }
      },
      "limitOptional": {
        "name": "limit",
        "in": "query",
        "description": "Maximum number of transactions to return. The default is 10. For accounts with many transactions, use pagination (lt + hash) to fetch more.",
        "required": false,
        "schema": {
          "type": "integer",
          "format": "int64",
          "default": 10
        }
      },
      "ltOptional": {
        "name": "lt",
        "in": "query",
        "description": "Starting point for transaction history. Pass the lt from `last_transaction_id` to start from the most recent, or from a specific transaction to continue pagination.",
        "required": false,
        "schema": {
          "type": "string",
          "x-usrv-cpp-type": "std::int64_t"
        }
      },
      "toLtOptional": {
        "name": "to_lt",
        "in": "query",
        "description": "Stop fetching when reaching this logical time. Set to 0 (default) to leave the lower logical-time bound unspecified.",
        "required": false,
        "schema": {
          "type": "string",
          "x-usrv-cpp-type": "std::int64_t",
          "default": 0
        }
      },
      "archivalOptional": {
        "name": "archival",
        "in": "query",
        "description": "Request data from archival nodes when querying old transactions or historical state.",
        "required": false,
        "schema": {
          "type": "boolean",
          "default": false
        }
      },
      "sourceAddress": {
        "name": "source",
        "in": "query",
        "description": "Source account address.",
        "required": true,
        "schema": {
          "$ref": "#/components/schemas/TonAddr"
        }
      },
      "destinationAddress": {
        "name": "destination",
        "in": "query",
        "description": "Destination account address.",
        "required": true,
        "schema": {
          "$ref": "#/components/schemas/TonAddr"
        }
      },
      "createdLt": {
        "name": "created_lt",
        "in": "query",
        "description": "The logical time when the message was created. Available in the `created_lt` field of message objects.",
        "required": true,
        "schema": {
          "type": "string",
          "x-usrv-cpp-type": "std::int64_t"
        }
      }
    },
    "responses": {
      "default": {
        "description": "Error response.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/TonlibErrorResponse"
            },
            "examples": {
              "422": {
                "summary": "Request validation error",
                "value": {
                  "ok": false,
                  "code": 422,
                  "error": "...",
                  "@extra": "..."
                }
              },
              "504": {
                "summary": "Tonlib timeout",
                "value": {
                  "ok": false,
                  "code": 504,
                  "error": "...",
                  "@extra": "..."
                }
              },
              "429": {
                "summary": "Ratelimit exceeded",
                "value": {
                  "ok": false,
                  "code": 429,
                  "error": "...",
                  "@extra": "..."
                }
              },
              "409": {
                "summary": "Not a token",
                "value": {
                  "ok": false,
                  "code": 409,
                  "error": "Smart contract is not a Jetton or NFT",
                  "@extra": "..."
                }
              }
            }
          }
        }
      }
    },
    "securitySchemes": {
      "APIKeyHeader": {
        "description": "API key header of the form `X-API-Key: <token>`, where `<token>` is the API key.",
        "type": "apiKey",
        "in": "header",
        "name": "X-API-Key"
      },
      "APIKeyQuery": {
        "description": "API key query parameter of the form `?api_key=<token>`, where `<token>` is the API key. Equivalent to the header method.",
        "type": "apiKey",
        "in": "query",
        "name": "api_key"
      }
    },
    "schemas": {
      "EmptyRequest": {
        "description": "Empty request body for endpoints that require no parameters.",
        "type": "object",
        "additionalProperties": false,
        "required": [],
        "properties": {}
      },
      "AddressRequest": {
        "description": "Request containing a single address parameter.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "address"
        ],
        "properties": {
          "address": {
            "$ref": "#/components/schemas/TonAddr"
          }
        }
      },
      "AddressWithSeqnoRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "address"
        ],
        "properties": {
          "address": {
            "$ref": "#/components/schemas/TonAddr"
          },
          "seqno": {
            "description": "Masterchain block sequence number. Query the account state as it was at this block height. If omitted, returns the current state.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          }
        }
      },
      "SeqnoRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "seqno"
        ],
        "properties": {
          "seqno": {
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          }
        }
      },
      "DetectAddressRequest": {
        "$ref": "#/components/schemas/AddressRequest"
      },
      "DetectHashRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "hash"
        ],
        "properties": {
          "hash": {
            "description": "Hash value to detect encoding formats for.",
            "$ref": "#/components/schemas/TonHash"
          }
        }
      },
      "PackAddressRequest": {
        "$ref": "#/components/schemas/AddressRequest"
      },
      "UnpackAddressRequest": {
        "$ref": "#/components/schemas/AddressRequest"
      },
      "AddressInformationRequest": {
        "$ref": "#/components/schemas/AddressWithSeqnoRequest"
      },
      "ShardAccountCellRequest": {
        "$ref": "#/components/schemas/AddressWithSeqnoRequest"
      },
      "ExtendedAddressInformationRequest": {
        "$ref": "#/components/schemas/AddressWithSeqnoRequest"
      },
      "WalletInformationRequest": {
        "$ref": "#/components/schemas/AddressWithSeqnoRequest"
      },
      "AddressBalanceRequest": {
        "$ref": "#/components/schemas/AddressWithSeqnoRequest"
      },
      "AddressStateRequest": {
        "$ref": "#/components/schemas/AddressWithSeqnoRequest"
      },
      "TokenDataRequest": {
        "$ref": "#/components/schemas/AddressWithSeqnoRequest"
      },
      "DnsResolveRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "address"
        ],
        "properties": {
          "address": {
            "$ref": "#/components/schemas/TonAddr"
          },
          "name": {
            "type": "string"
          },
          "category": {
            "type": "string"
          },
          "ttl": {
            "type": "integer",
            "format": "int32",
            "x-usrv-cpp-type": "std::int32_t"
          },
          "seqno": {
            "type": "integer",
            "format": "int32"
          }
        }
      },
      "MasterchainInfoRequest": {
        "$ref": "#/components/schemas/EmptyRequest"
      },
      "MasterchainBlockSignaturesRequest": {
        "$ref": "#/components/schemas/SeqnoRequest"
      },
      "ShardBlockProofRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "workchain",
          "shard",
          "seqno"
        ],
        "properties": {
          "workchain": {
            "description": "Workchain ID: `-1` for masterchain, `0` for basechain. Most user transactions are on workchain `0`.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          },
          "shard": {
            "description": "Shard identifier. A signed 64-bit integer. Masterchain uses -9223372036854775808.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int64",
                "x-usrv-cpp-type": "std::int64_t"
              }
            ],
            "x-usrv-cpp-type": "std::int64_t"
          },
          "seqno": {
            "description": "Shardchain block sequence number. Identifies a specific block within the given workchain and shard. Use together with `workchain` and `shard` to uniquely identify a block.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          },
          "from_seqno": {
            "description": "Starting masterchain block for proof generation.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          }
        }
      },
      "ConsensusBlockRequest": {
        "$ref": "#/components/schemas/EmptyRequest"
      },
      "LookupBlockRequest": {
        "description": "Request to find a block by workchain, shard, and either `seqno`, lt, or unixtime.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "workchain",
          "shard"
        ],
        "properties": {
          "workchain": {
            "description": "Workchain ID: `-1` for masterchain, `0` for basechain. Most user transactions are on workchain `0`.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          },
          "shard": {
            "description": "Shard identifier. A signed 64-bit integer. Masterchain uses -9223372036854775808.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int64",
                "x-usrv-cpp-type": "std::int64_t"
              }
            ],
            "x-usrv-cpp-type": "std::int64_t"
          },
          "seqno": {
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          },
          "lt": {
            "description": "Logical time of the transaction. Use together with its hash for pagination and lookups.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int64",
                "x-usrv-cpp-type": "std::int64_t"
              }
            ],
            "x-usrv-cpp-type": "std::int64_t"
          },
          "unixtime": {
            "description": "Unix timestamp to look up.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          }
        }
      },
      "ShardsRequest": {
        "$ref": "#/components/schemas/SeqnoRequest"
      },
      "BlockDataRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "workchain",
          "shard",
          "seqno"
        ],
        "properties": {
          "workchain": {
            "description": "Workchain ID: `-1` for masterchain, `0` for basechain. Most user transactions are on workchain `0`.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          },
          "shard": {
            "description": "Shard identifier. A signed 64-bit integer. Masterchain uses -9223372036854775808.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int64",
                "x-usrv-cpp-type": "std::int64_t"
              }
            ],
            "x-usrv-cpp-type": "std::int64_t"
          },
          "seqno": {
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          },
          "root_hash": {
            "$ref": "#/components/schemas/TonHash"
          },
          "file_hash": {
            "$ref": "#/components/schemas/TonHash"
          },
          "archival": {
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              },
              {
                "type": "boolean"
              }
            ],
            "x-usrv-cpp-type": "bool"
          }
        }
      },
      "BlockHeaderRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "workchain",
          "shard",
          "seqno"
        ],
        "properties": {
          "workchain": {
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          },
          "shard": {
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int64",
                "x-usrv-cpp-type": "std::int64_t"
              }
            ],
            "x-usrv-cpp-type": "std::int64_t"
          },
          "seqno": {
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          },
          "root_hash": {
            "description": "Root hash of the block. Together with `file_hash`, uniquely identifies a block.",
            "$ref": "#/components/schemas/TonHash"
          },
          "file_hash": {
            "description": "Hash of the serialized block data. Together with `root_hash`, uniquely identifies a block.",
            "$ref": "#/components/schemas/TonHash"
          }
        }
      },
      "OutMsgQueueSizeRequest": {
        "$ref": "#/components/schemas/EmptyRequest"
      },
      "BlockTransactionsRequest": {
        "description": "Request to fetch transactions from a specific block with optional pagination.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "workchain",
          "shard",
          "seqno"
        ],
        "properties": {
          "workchain": {
            "description": "Workchain ID: `-1` for masterchain, `0` for basechain. Most user transactions are on workchain `0`.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          },
          "shard": {
            "description": "Shard identifier. A signed 64-bit integer. Masterchain uses -9223372036854775808.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int64",
                "x-usrv-cpp-type": "std::int64_t"
              }
            ],
            "x-usrv-cpp-type": "std::int64_t"
          },
          "seqno": {
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          },
          "root_hash": {
            "description": "Root hash of the block. Together with `file_hash`, uniquely identifies a block.",
            "$ref": "#/components/schemas/TonHash"
          },
          "file_hash": {
            "description": "Hash of the serialized block data. Together with `root_hash`, uniquely identifies a block.",
            "$ref": "#/components/schemas/TonHash"
          },
          "after_lt": {
            "description": "Return items after this logical time (for pagination).",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int64",
                "x-usrv-cpp-type": "std::int64_t"
              }
            ],
            "x-usrv-cpp-type": "std::int64_t"
          },
          "after_hash": {
            "description": "Return items after this hash (for pagination within same `lt`).",
            "$ref": "#/components/schemas/TonAddrWithoutWorkchain"
          },
          "count": {
            "description": "Maximum number of items to return.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int64"
              }
            ],
            "x-usrv-cpp-type": "std::int64_t"
          }
        }
      },
      "BlockTransactionsExtRequest": {
        "$ref": "#/components/schemas/BlockTransactionsRequest"
      },
      "TransactionsRequest": {
        "description": "Request to fetch transaction history for an account with optional pagination and filtering parameters.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "address"
        ],
        "properties": {
          "address": {
            "$ref": "#/components/schemas/TonAddr"
          },
          "lt": {
            "description": "Logical time of the transaction. Use together with its hash for pagination and lookups.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int64",
                "x-usrv-cpp-type": "std::int64_t"
              }
            ],
            "x-usrv-cpp-type": "std::int64_t"
          },
          "hash": {
            "description": "Hash of the starting transaction for pagination. Use together with `lt` from a previous response's `transaction_id`.",
            "$ref": "#/components/schemas/TonHash"
          },
          "to_lt": {
            "description": "Stop returning items at this logical time.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int64",
                "x-usrv-cpp-type": "std::int64_t"
              }
            ],
            "x-usrv-cpp-type": "std::int64_t"
          },
          "archival": {
            "description": "Whether to use archival nodes for old data.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              },
              {
                "type": "boolean"
              }
            ],
            "x-usrv-cpp-type": "bool"
          },
          "limit": {
            "description": "Maximum number of items to return.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int64"
              }
            ],
            "x-usrv-cpp-type": "std::int64_t"
          }
        }
      },
      "TryLocateTxRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "source",
          "destination",
          "created_lt"
        ],
        "properties": {
          "source": {
            "$ref": "#/components/schemas/TonAddr"
          },
          "destination": {
            "description": "Recipient address.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "created_lt": {
            "description": "Logical time when this message was created. Use with source and destination to uniquely identify a message.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int64",
                "x-usrv-cpp-type": "std::int64_t"
              }
            ],
            "x-usrv-cpp-type": "std::int64_t"
          }
        }
      },
      "TryLocateResultTxRequest": {
        "$ref": "#/components/schemas/TryLocateTxRequest"
      },
      "TryLocateSourceTxRequest": {
        "$ref": "#/components/schemas/TryLocateTxRequest"
      },
      "ConfigParamRequest": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "config_id": {
            "description": "Configuration parameter number. Each number controls different blockchain settings.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          },
          "param": {
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          },
          "seqno": {
            "description": "Masterchain block sequence number (block height). Used to query blockchain config at a specific block. If omitted, the latest masterchain block is used.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          }
        }
      },
      "ConfigAllRequest": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "seqno": {
            "description": "Masterchain block sequence number (block height). Used to query blockchain config at a specific block. If omitted, the latest masterchain block is used.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ],
            "x-usrv-cpp-type": "std::int32_t"
          }
        }
      },
      "LibrariesRequest": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "libraries": {
            "description": "Array of library cell hashes to retrieve. Each hash is a 256-bit value in hex (64 chars) or base64 (44 chars) format.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TonHash"
            }
          }
        }
      },
      "SendBocRequest": {
        "description": "Request to broadcast a signed message. The boc field contains the base64-encoded external message.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "boc"
        ],
        "properties": {
          "boc": {
            "description": "Serialized external message in BoC format, base64 encoded.",
            "$ref": "#/components/schemas/Bytes"
          }
        }
      },
      "EstimateFeeRequest": {
        "description": "Request to estimate transaction fees. Include the target address, message body, and optionally init code/data for contract deployment.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "address",
          "body"
        ],
        "properties": {
          "address": {
            "$ref": "#/components/schemas/TonAddr"
          },
          "body": {
            "description": "Message body in BoC format, base64 encoded.",
            "$ref": "#/components/schemas/Bytes"
          },
          "init_code": {
            "description": "Contract code for deployment messages, BoC format, base64 encoded. Omit for regular transfers.",
            "$ref": "#/components/schemas/Bytes"
          },
          "init_data": {
            "description": "Initial contract storage for deployment, BoC format, base64 encoded. Omit for regular transfers.",
            "$ref": "#/components/schemas/Bytes"
          },
          "ignore_chksig": {
            "description": "Set to `true` to skip signature verification during fee estimation; otherwise `false`. Useful when a real signature is not yet available.",
            "type": "boolean",
            "default": true
          }
        }
      },
      "JsonRpcRequest": {
        "description": "Request to the JSON-RPC endpoint. Set `method` to the API method name (e.g., `getWalletInformation`) and `params` to a dictionary of parameters.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "jsonrpc",
          "id",
          "method",
          "params"
        ],
        "properties": {
          "jsonrpc": {
            "description": "JSON-RPC protocol version identifier.",
            "type": "string",
            "default": "2.0"
          },
          "id": {
            "type": "string"
          },
          "method": {
            "description": "API method name to invoke (e.g., `getMasterchainInfo`, `getAddressBalance`).",
            "type": "string"
          },
          "params": {
            "description": "Method parameters as a JSON object with key-value pairs.",
            "type": "object",
            "additionalProperties": true
          }
        }
      },
      "TonAddr": {
        "description": "Account address in raw format (e.g., `0:ca6e321c...`) or user-friendly format (e.g., `EQDKbjIcfM...`). All formats are automatically detected.",
        "type": "string",
        "x-usrv-cpp-type": "ton_http::types::ton_addr"
      },
      "TonAddrWithoutWorkchain": {
        "description": "The account ID portion of an address without the workchain prefix. This is the 256-bit identifier in hex or base64 format.",
        "type": "string",
        "x-usrv-cpp-type": "ton_http::types::ton_addr_without_workchain"
      },
      "TonHash": {
        "description": "A 256-bit hash value. Accepts either hex format (64 characters) or base64 format (44 characters). Used for block hashes, transaction hashes, and cryptographic proofs.",
        "type": "string",
        "x-usrv-cpp-type": "ton_http::types::ton_hash"
      },
      "TonHashHex": {
        "description": "A 256-bit hash in hexadecimal format. Exactly 64 characters (0-9, a-f).",
        "type": "string",
        "x-usrv-cpp-type": "ton_http::types::ton_hash_hex"
      },
      "Int256": {
        "description": "A large integer represented as a string to avoid precision loss. Used for balances and other values that may exceed JavaScript's safe integer limit.",
        "type": "string",
        "x-usrv-cpp-type": "ton_http::types::int256"
      },
      "Bytes": {
        "description": "Binary data encoded as base64. Used for serialized cells (BoC format), message bodies, and smart contract code/data.",
        "type": "string",
        "x-usrv-cpp-type": "ton_http::types::bytes"
      },
      "AccountAddress": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "account_address"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for account address objects.",
            "type": "string",
            "enum": [
              "accountAddress"
            ],
            "default": "accountAddress"
          },
          "account_address": {
            "description": "The account address in raw format (`workchain:hex`), e.g. `0:abc123...`. Use the pack address endpoint to convert to user-friendly base64 format.",
            "type": "string",
            "x-usrv-cpp-type": "ton_http::types::ton_addr"
          }
        }
      },
      "AdnlAddress": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "adnl_address"
        ],
        "properties": {
          "@type": {
            "type": "string",
            "enum": [
              "adnlAddress"
            ],
            "default": "adnlAddress"
          },
          "adnl_address": {
            "type": "string"
          }
        }
      },
      "TonBlockIdExt": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for full block identifiers.",
            "type": "string",
            "enum": [
              "ton.blockIdExt"
            ],
            "default": "ton.blockIdExt"
          },
          "workchain": {
            "description": "Workchain ID: `-1` for masterchain, `0` for basechain.",
            "type": "integer"
          },
          "shard": {
            "description": "Shard identifier as a signed 64-bit integer string. Masterchain uses `-9223372036854775808`.",
            "type": "string",
            "x-usrv-cpp-type": "std::int64_t"
          },
          "seqno": {
            "description": "Block sequence number within its workchain and shard. For the masterchain (workchain `-1`), this equals the global block height. For basechain shards (workchain `0`), this is the sequence number local to that specific shard, not a global height.",
            "type": "integer"
          },
          "root_hash": {
            "description": "Root hash of the block. Together with `file_hash`, uniquely identifies a block.",
            "$ref": "#/components/schemas/TonHash"
          },
          "file_hash": {
            "description": "Hash of the serialized block file. Together with `root_hash`, uniquely identifies a block.",
            "$ref": "#/components/schemas/TonHash"
          }
        },
        "required": [
          "@type",
          "workchain",
          "shard",
          "seqno",
          "root_hash",
          "file_hash"
        ],
        "description": "A complete block identifier with cryptographic hashes. Contains `workchain`, `shard`, `seqno` (position) plus `root_hash` and `file_hash` (verification)."
      },
      "DetectAddressBase64Variant": {
        "type": "object",
        "additionalProperties": false,
        "description": "User-friendly address in both standard base64 and URL-safe base64 encodings.",
        "properties": {
          "@type": {
            "description": "TonLib type identifier for base64 address encoding variants.",
            "type": "string",
            "enum": [
              "ext.utils.detectedAddressVariant"
            ],
            "default": "ext.utils.detectedAddressVariant"
          },
          "b64": {
            "description": "Address in standard base64 encoding (48 characters, uses `+` and `/`).",
            "type": "string"
          },
          "b64url": {
            "description": "Address in URL-safe base64 encoding (48 characters, uses `-` and `_` instead of `+` and `/`).",
            "type": "string"
          }
        },
        "required": [
          "@type",
          "b64",
          "b64url"
        ]
      },
      "ExtraCurrencyBalance": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for extra currency balance entries.",
            "type": "string",
            "enum": [
              "extraCurrency"
            ],
            "default": "extraCurrency"
          },
          "id": {
            "type": "integer",
            "format": "int32"
          },
          "amount": {
            "description": "Currency balance amount as a decimal string.",
            "$ref": "#/components/schemas/Int256"
          }
        },
        "required": [
          "@type",
          "id",
          "amount"
        ]
      },
      "InternalTransactionId": {
        "type": "object",
        "additionalProperties": false,
        "description": "A reference to a specific transaction. The combination of `lt` (logical time) and `hash` uniquely identifies any transaction. Use these values for pagination and lookups.",
        "properties": {
          "@type": {
            "description": "TonLib type identifier for transaction ID references.",
            "type": "string",
            "enum": [
              "internal.transactionId"
            ],
            "default": "internal.transactionId"
          },
          "lt": {
            "type": "string",
            "description": "Logical time of the transaction. Use together with its hash for pagination and lookups.",
            "x-usrv-cpp-type": "std::int64_t"
          },
          "hash": {
            "description": "SHA-256 hash of this transaction, encoded in base64.",
            "$ref": "#/components/schemas/TonHash"
          }
        },
        "required": [
          "@type",
          "lt",
          "hash"
        ]
      },
      "AccountStateRaw": {
        "description": "Unrecognized or non-wallet contract state. Identified by `@type: raw.accountState`. Returned when TonLib cannot parse the contract as a known type.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for raw (unrecognized) contract states.",
            "type": "string",
            "enum": [
              "raw.accountState"
            ],
            "default": "raw.accountState"
          },
          "code": {
            "description": "Smart contract code in BoC format, base64 encoded. Empty if account is uninitialized.",
            "$ref": "#/components/schemas/Bytes"
          },
          "data": {
            "description": "Smart contract persistent storage in BoC format, base64 encoded.",
            "$ref": "#/components/schemas/Bytes"
          },
          "frozen_hash": {
            "$ref": "#/components/schemas/TonHash"
          }
        },
        "required": [
          "@type",
          "code",
          "data",
          "frozen_hash"
        ]
      },
      "AccountStateWalletV3": {
        "description": "Standard wallet contract version 3. Identified by `@type: wallet.v3.accountState`. The most widely deployed wallet type prior to v4.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for Wallet v3 contracts.",
            "type": "string",
            "enum": [
              "wallet.v3.accountState"
            ],
            "default": "wallet.v3.accountState"
          },
          "wallet_id": {
            "description": "Subwallet identifier. Allows creating multiple wallets from one key.",
            "type": "integer",
            "format": "int64"
          },
          "seqno": {
            "description": "Wallet contract sequence number. Used for replay protection: each outgoing transaction must include the current `seqno` and increments it by 1. Fetch the current value before sending a transaction.",
            "type": "integer",
            "format": "int32"
          }
        },
        "required": [
          "@type",
          "wallet_id",
          "seqno"
        ]
      },
      "AccountStateWalletV4": {
        "description": "Standard wallet contract version 4. Identified by `@type: wallet.v4.accountState`. Adds plugin support over v3.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for Wallet v4 contracts.",
            "type": "string",
            "enum": [
              "wallet.v4.accountState"
            ],
            "default": "wallet.v4.accountState"
          },
          "wallet_id": {
            "description": "Subwallet identifier. Allows creating multiple wallets from one key.",
            "type": "integer",
            "format": "int64"
          },
          "seqno": {
            "description": "Wallet contract sequence number. Used for replay protection: each outgoing transaction must include the current `seqno` and increments it by 1. Fetch the current value before sending a transaction.",
            "type": "integer",
            "format": "int32"
          }
        },
        "required": [
          "@type",
          "wallet_id",
          "seqno"
        ]
      },
      "AccountStateWalletHighloadV1": {
        "description": "High-throughput wallet contract version 1. Identified by `@type: wallet.highload.v1.accountState`. Designed for sending many transactions in a single block.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for Highload Wallet v1 contracts.",
            "type": "string",
            "enum": [
              "wallet.highload.v1.accountState"
            ],
            "default": "wallet.highload.v1.accountState"
          },
          "wallet_id": {
            "description": "Subwallet identifier. Allows creating multiple wallets from one key.",
            "type": "integer",
            "format": "int64"
          },
          "seqno": {
            "description": "Wallet contract sequence number. Used for replay protection: each outgoing transaction must include the current `seqno` and increments it by 1. Fetch the current value before sending a transaction.",
            "type": "integer",
            "format": "int32"
          }
        },
        "required": [
          "@type",
          "wallet_id",
          "seqno"
        ]
      },
      "AccountStateWalletHighloadV2": {
        "description": "High-throughput wallet contract version 2. Identified by `@type: wallet.highload.v2.accountState`. Improved version of highload v1 with better replay protection.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for Highload Wallet v2 contracts.",
            "type": "string",
            "enum": [
              "wallet.highload.v2.accountState"
            ],
            "default": "wallet.highload.v2.accountState"
          },
          "wallet_id": {
            "description": "Subwallet identifier. Allows creating multiple wallets from one key.",
            "type": "integer",
            "format": "int64"
          }
        },
        "required": [
          "@type",
          "wallet_id"
        ]
      },
      "AccountStateDns": {
        "description": "TON DNS contract state. Identified by `@type: dns.accountState`. Used by contracts that resolve TON domain names.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for DNS resolver contracts.",
            "type": "string",
            "enum": [
              "dns.accountState"
            ],
            "default": "dns.accountState"
          },
          "wallet_id": {
            "type": "integer",
            "format": "int64"
          }
        },
        "required": [
          "@type",
          "wallet_id"
        ]
      },
      "RWalletLimit": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for restricted wallet spending limit rules.",
            "type": "string",
            "enum": [
              "rwallet.limit"
            ],
            "default": "rwallet.limit"
          },
          "seconds": {
            "description": "Duration of this spending limit window in seconds.",
            "type": "integer",
            "format": "int32"
          },
          "value": {
            "description": "Maximum spendable amount within this time period, in nanotons.",
            "type": "integer",
            "format": "int64"
          }
        },
        "required": [
          "@type",
          "seconds",
          "value"
        ]
      },
      "RWalletConfig": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for restricted wallet configuration.",
            "type": "string",
            "enum": [
              "rwallet.config"
            ],
            "default": "rwallet.config"
          },
          "start_at": {
            "description": "Unix timestamp when the spending limits become active.",
            "type": "integer",
            "format": "int64"
          },
          "limits": {
            "description": "Array of spending limit rules. Each entry defines a time window in seconds and the maximum spendable amount in nanotons within that window.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RWalletLimit"
            }
          }
        },
        "required": [
          "@type",
          "start_at",
          "limits"
        ]
      },
      "AccountStateRWallet": {
        "description": "Restricted wallet contract state. Identified by `@type: rwallet.accountState`. Used for wallets with vesting or transfer restrictions.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for restricted wallet contracts.",
            "type": "string",
            "enum": [
              "rwallet.accountState"
            ],
            "default": "rwallet.accountState"
          },
          "wallet_id": {
            "description": "Subwallet identifier. Allows creating multiple wallets from one key.",
            "type": "integer",
            "format": "int64"
          },
          "seqno": {
            "description": "Wallet contract sequence number. Used for replay protection: each outgoing transaction must include the current `seqno` and increments it by 1. Fetch the current value before sending a transaction.",
            "type": "integer",
            "format": "int32"
          },
          "unlocked_balance": {
            "description": "Balance available for immediate withdrawal, in nanotons.",
            "type": "integer",
            "format": "int64"
          },
          "config": {
            "description": "Spending limits and restrictions configuration.",
            "$ref": "#/components/schemas/RWalletConfig"
          }
        },
        "required": [
          "@type",
          "wallet_id",
          "seqno",
          "unlocked_balance",
          "config"
        ]
      },
      "PChanConfig": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for payment channel configuration.",
            "type": "string",
            "enum": [
              "pchan.config"
            ],
            "default": "pchan.config"
          },
          "alice_public_key": {
            "description": "Alice's Ed25519 public key for signing channel operations.",
            "type": "string"
          },
          "alice_address": {
            "description": "Alice's on-chain wallet address.",
            "$ref": "#/components/schemas/AccountAddress"
          },
          "bob_public_key": {
            "description": "Bob's Ed25519 public key for signing channel operations.",
            "type": "string"
          },
          "bob_address": {
            "description": "Bob's on-chain wallet address.",
            "$ref": "#/components/schemas/AccountAddress"
          },
          "init_timeout": {
            "description": "Maximum seconds allowed to complete channel initialization before it expires.",
            "type": "integer",
            "format": "int32"
          },
          "close_timeout": {
            "description": "Maximum seconds allowed to complete cooperative channel closure.",
            "type": "integer",
            "format": "int32"
          },
          "channel_id": {
            "description": "Unique numeric identifier for this payment channel.",
            "type": "integer",
            "format": "int64"
          }
        },
        "required": [
          "@type",
          "alice_public_key",
          "alice_address",
          "bob_public_key",
          "bob_address",
          "init_timeout",
          "close_timeout",
          "channel_id"
        ]
      },
      "PChanStateInit": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for payment channels in the initialization phase.",
            "type": "string",
            "enum": [
              "pchan.stateInit"
            ],
            "default": "pchan.stateInit"
          },
          "signed_A": {
            "description": "Returns `true` if Alice has signed the initialization; otherwise `false`.",
            "type": "boolean"
          },
          "signed_B": {
            "description": "Returns `true` if Bob has signed the initialization; otherwise `false`.",
            "type": "boolean"
          },
          "min_A": {
            "description": "Minimum deposit required from Alice, in nanotons.",
            "type": "integer",
            "format": "int64"
          },
          "min_B": {
            "description": "Minimum deposit required from Bob, in nanotons.",
            "type": "integer",
            "format": "int64"
          },
          "expire_at": {
            "description": "Unix timestamp when the initialization offer expires.",
            "type": "integer",
            "format": "int64"
          },
          "A": {
            "description": "Alice's deposited amount in nanotons.",
            "type": "integer",
            "format": "int64"
          },
          "B": {
            "description": "Bob's deposited amount in nanotons.",
            "type": "integer",
            "format": "int64"
          }
        },
        "required": [
          "@type",
          "signed_A",
          "signed_B",
          "min_A",
          "min_B",
          "expire_at",
          "A",
          "B"
        ]
      },
      "PChanStateClose": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for payment channels in the closing phase.",
            "type": "string",
            "enum": [
              "pchan.stateClose"
            ],
            "default": "pchan.stateClose"
          },
          "signed_A": {
            "description": "Returns `true` if Alice has signed the close proposal; otherwise `false`.",
            "type": "boolean"
          },
          "signed_B": {
            "description": "Returns `true` if Bob has signed the close proposal; otherwise `false`.",
            "type": "boolean"
          },
          "min_A": {
            "description": "Minimum guaranteed payout for Alice, in nanotons.",
            "type": "integer",
            "format": "int64"
          },
          "min_B": {
            "description": "Minimum guaranteed payout for Bob, in nanotons.",
            "type": "integer",
            "format": "int64"
          },
          "expire_at": {
            "description": "Unix timestamp when the close proposal expires.",
            "type": "integer",
            "format": "int64"
          },
          "A": {
            "description": "Alice's final balance in nanotons.",
            "type": "integer",
            "format": "int64"
          },
          "B": {
            "description": "Bob's final balance in nanotons.",
            "type": "integer",
            "format": "int64"
          }
        },
        "required": [
          "@type",
          "signed_A",
          "signed_B",
          "min_A",
          "min_B",
          "expire_at",
          "A",
          "B"
        ]
      },
      "PChanStatePayout": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for payment channels in the payout phase.",
            "type": "string",
            "enum": [
              "pchan.statePayout"
            ],
            "default": "pchan.statePayout"
          },
          "A": {
            "description": "Alice's payout amount in nanotons.",
            "type": "integer",
            "format": "int64"
          },
          "B": {
            "description": "Bob's payout amount in nanotons.",
            "type": "integer",
            "format": "int64"
          }
        },
        "required": [
          "@type",
          "A",
          "B"
        ]
      },
      "PChanState": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/PChanStateInit"
          },
          {
            "$ref": "#/components/schemas/PChanStateClose"
          },
          {
            "$ref": "#/components/schemas/PChanStatePayout"
          }
        ],
        "discriminator": {
          "propertyName": "@type",
          "mapping": {
            "pchan.stateInit": "#/components/schemas/PChanStateInit",
            "pchan.stateClose": "#/components/schemas/PChanStateClose",
            "pchan.statePayout": "#/components/schemas/PChanStatePayout"
          }
        }
      },
      "AccountStatePChan": {
        "description": "Payment channel contract state. Identified by `@type: pchan.accountState`. Used for off-chain payment channels between two parties.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for payment channel contracts.",
            "type": "string",
            "enum": [
              "pchan.accountState"
            ],
            "default": "pchan.accountState"
          },
          "config": {
            "description": "Payment channel configuration (parties, timeouts, keys).",
            "$ref": "#/components/schemas/PChanConfig"
          },
          "state": {
            "description": "Current payment channel state (init, close, or payout phase).",
            "$ref": "#/components/schemas/PChanState"
          },
          "description": {
            "description": "Human-readable payment channel description.",
            "type": "string"
          }
        },
        "required": [
          "@type",
          "config",
          "state",
          "description"
        ]
      },
      "AccountStateUninited": {
        "description": "Account exists on-chain but has no deployed contract. Identified by `@type: uninited.accountState`. The address has received TON but no code has been deployed yet.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for uninitialized accounts.",
            "type": "string",
            "enum": [
              "uninited.accountState"
            ],
            "default": "uninited.accountState"
          },
          "frozen_hash": {
            "$ref": "#/components/schemas/TonHash"
          }
        },
        "required": [
          "@type",
          "frozen_hash"
        ]
      },
      "AccountState": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/AccountStateRaw"
          },
          {
            "$ref": "#/components/schemas/AccountStateWalletV3"
          },
          {
            "$ref": "#/components/schemas/AccountStateWalletV4"
          },
          {
            "$ref": "#/components/schemas/AccountStateWalletHighloadV1"
          },
          {
            "$ref": "#/components/schemas/AccountStateWalletHighloadV2"
          },
          {
            "$ref": "#/components/schemas/AccountStateDns"
          },
          {
            "$ref": "#/components/schemas/AccountStateRWallet"
          },
          {
            "$ref": "#/components/schemas/AccountStatePChan"
          },
          {
            "$ref": "#/components/schemas/AccountStateUninited"
          }
        ],
        "discriminator": {
          "propertyName": "@type",
          "mapping": {
            "raw.accountState": "#/components/schemas/AccountStateRaw",
            "wallet.v3.accountState": "#/components/schemas/AccountStateWalletV3",
            "wallet.v4.accountState": "#/components/schemas/AccountStateWalletV4",
            "wallet.highload.v1.accountState": "#/components/schemas/AccountStateWalletHighloadV1",
            "wallet.highload.v2.accountState": "#/components/schemas/AccountStateWalletHighloadV2",
            "dns.accountState": "#/components/schemas/AccountStateDns",
            "rwallet.accountState": "#/components/schemas/AccountStateRWallet",
            "pchan.accountState": "#/components/schemas/AccountStatePChan",
            "uninited.accountState": "#/components/schemas/AccountStateUninited"
          }
        }
      },
      "TokenContentDict": {
        "type": "object",
        "additionalProperties": true
      },
      "DnsRecordStorageAddress": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "bag_id"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for TON Storage DNS records.",
            "type": "string",
            "enum": [
              "dns_storage_address"
            ],
            "default": "dns_storage_address"
          },
          "bag_id": {
            "description": "TON Storage bag identifier in hex, pointing to distributed file storage.",
            "$ref": "#/components/schemas/TonHashHex"
          }
        }
      },
      "DnsRecordAdnlAddress": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "adnl_addr"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for ADNL address DNS records.",
            "type": "string",
            "enum": [
              "dns_adnl_address"
            ],
            "default": "dns_adnl_address"
          },
          "adnl_addr": {
            "description": "ADNL (Abstract Datagram Network Layer) address in hex, used for TON Sites and services.",
            "$ref": "#/components/schemas/TonHashHex"
          }
        }
      },
      "SmcAddr": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "workchain_id",
          "address"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for standard smart contract addresses.",
            "type": "string",
            "enum": [
              "addr_std"
            ],
            "default": "addr_std"
          },
          "workchain_id": {
            "description": "Workchain ID (`0` for basechain, `-1` for masterchain).",
            "type": "integer",
            "format": "int32"
          },
          "address": {
            "description": "Account identifier as a 64-character hex string.",
            "$ref": "#/components/schemas/TonHashHex"
          }
        }
      },
      "DnsRecordSmcAddress": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "smc_addr"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for smart contract address DNS records.",
            "type": "string",
            "enum": [
              "dns_smc_address"
            ],
            "default": "dns_smc_address"
          },
          "smc_addr": {
            "description": "Smart contract address associated with this DNS record.",
            "$ref": "#/components/schemas/SmcAddr"
          }
        }
      },
      "DnsRecordNextResolver": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "resolver"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for next-resolver DNS records.",
            "type": "string",
            "enum": [
              "dns_next_resolver"
            ],
            "default": "dns_next_resolver"
          },
          "resolver": {
            "description": "Smart contract address of the next DNS resolver in the chain.",
            "$ref": "#/components/schemas/SmcAddr"
          }
        }
      },
      "DnsRecord": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/DnsRecordStorageAddress"
          },
          {
            "$ref": "#/components/schemas/DnsRecordSmcAddress"
          },
          {
            "$ref": "#/components/schemas/DnsRecordAdnlAddress"
          },
          {
            "$ref": "#/components/schemas/DnsRecordNextResolver"
          }
        ],
        "discriminator": {
          "propertyName": "@type",
          "mapping": {
            "dns_storage_address": "#/components/schemas/DnsRecordStorageAddress",
            "dns_smc_address": "#/components/schemas/DnsRecordSmcAddress",
            "dns_adnl_address": "#/components/schemas/DnsRecordAdnlAddress",
            "dns_next_resolver": "#/components/schemas/DnsRecordNextResolver"
          }
        }
      },
      "DnsRecordSet": {
        "type": "object",
        "additionalProperties": true,
        "properties": {
          "dns_next_resolver": {
            "description": "Next resolver contract for subdomain lookups.",
            "$ref": "#/components/schemas/DnsRecord"
          },
          "wallet": {
            "description": "Wallet address associated with this domain.",
            "$ref": "#/components/schemas/DnsRecord"
          },
          "site": {
            "description": "Site hosting address (ADNL or TON Storage).",
            "$ref": "#/components/schemas/DnsRecord"
          },
          "storage": {
            "description": "TON Storage bag ID for files hosted under this domain.",
            "$ref": "#/components/schemas/DnsRecord"
          }
        }
      },
      "DnsContent": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "domain",
          "data"
        ],
        "properties": {
          "domain": {
            "description": "The resolved domain name.",
            "type": "string"
          },
          "data": {
            "description": "Parsed DNS records for this domain.",
            "$ref": "#/components/schemas/DnsRecordSet"
          }
        }
      },
      "TokenContent": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "type",
          "data"
        ],
        "properties": {
          "type": {
            "description": "Storage method for token (jetton) metadata content: `onchain` (stored in contract data) or `offchain` (external URI).",
            "type": "string",
            "enum": [
              "onchain",
              "offchain"
            ]
          },
          "data": {
            "description": "Token metadata key-value pairs (name, symbol, decimals, image, description).",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "$ref": "#/components/schemas/TokenContentDict"
              }
            ]
          }
        }
      },
      "JettonMasterData": {
        "description": "Jetton (fungible token) master contract data. Contains total supply, whether minting is allowed, admin address, and token metadata (name, symbol, decimals). This is the central contract that tracks the token.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "address",
          "contract_type",
          "total_supply",
          "mintable",
          "jetton_content",
          "jetton_wallet_code"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for Jetton master contract data.",
            "type": "string",
            "enum": [
              "ext.tokens.jettonMasterData"
            ],
            "default": "ext.tokens.jettonMasterData"
          },
          "address": {
            "description": "Contract address of this Jetton master.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "contract_type": {
            "description": "Type of token contract: jetton_master, jetton_wallet, nft_collection, or nft_item.",
            "type": "string",
            "enum": [
              "jetton_master"
            ],
            "default": "jetton_master"
          },
          "total_supply": {
            "description": "Total tokens in circulation, in the smallest unit. Divide by 10^decimals for human-readable amount.",
            "$ref": "#/components/schemas/Int256"
          },
          "mintable": {
            "description": "Whether new tokens can currently be minted.",
            "type": "boolean"
          },
          "admin_address": {
            "description": "Admin address that can mint tokens or update metadata. Empty if admin rights were revoked.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "jetton_content": {
            "description": "Token metadata: name, symbol, decimals, description, and image URL.",
            "$ref": "#/components/schemas/TokenContent"
          },
          "jetton_wallet_code": {
            "description": "Code used to deploy individual user wallets for this token. Used to verify wallet authenticity.",
            "$ref": "#/components/schemas/Bytes"
          }
        }
      },
      "JettonWalletData": {
        "description": "Jetton wallet contract data. Each user has a separate wallet contract for each token they hold. Contains the token balance, owner address, and reference to the master contract.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "address",
          "contract_type",
          "balance",
          "owner",
          "jetton",
          "jetton_wallet_code"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for Jetton wallet contract data.",
            "type": "string",
            "enum": [
              "ext.tokens.jettonWalletData"
            ],
            "default": "ext.tokens.jettonWalletData"
          },
          "address": {
            "description": "Contract address of this Jetton wallet.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "contract_type": {
            "description": "Type of token contract: jetton_master, jetton_wallet, nft_collection, or nft_item.",
            "type": "string",
            "enum": [
              "jetton_wallet"
            ],
            "default": "jetton_wallet"
          },
          "balance": {
            "description": "The token balance in the Jetton's base units (smallest denomination). To get the human-readable amount, divide by 10^decimals, where `decimals` is a metadata field on the Jetton master contract (commonly 9, but varies per token). Refer to the Jetton overview for how Jetton decimals are defined.",
            "$ref": "#/components/schemas/Int256"
          },
          "owner": {
            "description": "Wallet owner's address (the user who holds these tokens).",
            "$ref": "#/components/schemas/TonAddr"
          },
          "jetton": {
            "description": "Address of the Jetton master contract this wallet belongs to.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "mintless_is_claimed": {
            "description": "Returns `true` if the mintless jetton allocation has been claimed; otherwise `false`.",
            "type": "boolean"
          },
          "jetton_wallet_code": {
            "description": "Wallet contract code. Should match the master contract's wallet code to verify authenticity.",
            "$ref": "#/components/schemas/Bytes"
          }
        }
      },
      "NftCollectionData": {
        "description": "NFT collection contract data. Contains the number of items minted, collection owner, and collection metadata (name, description, image).",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "address",
          "contract_type",
          "next_item_index",
          "collection_content"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for NFT collection contract data.",
            "type": "string",
            "enum": [
              "ext.tokens.nftCollectionData"
            ],
            "default": "ext.tokens.nftCollectionData"
          },
          "address": {
            "description": "Contract address of this NFT collection.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "contract_type": {
            "description": "Type of token contract: jetton_master, jetton_wallet, nft_collection, or nft_item.",
            "type": "string",
            "enum": [
              "nft_collection"
            ],
            "default": "nft_collection"
          },
          "next_item_index": {
            "description": "Index that will be assigned to the next minted NFT. Also indicates total items if minted sequentially.",
            "$ref": "#/components/schemas/Int256"
          },
          "owner_address": {
            "description": "Collection owner's address. Controls minting and metadata updates.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "collection_content": {
            "description": "Collection metadata: name, description, and cover image.",
            "$ref": "#/components/schemas/TokenContent"
          }
        }
      },
      "NftItemData": {
        "description": "Individual NFT data. Contains the item index, collection reference, current owner, and item-specific content/metadata.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "address",
          "contract_type",
          "init",
          "index",
          "content"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for NFT item contract data.",
            "type": "string",
            "enum": [
              "ext.tokens.nftItemData"
            ],
            "default": "ext.tokens.nftItemData"
          },
          "address": {
            "description": "Contract address of this NFT item.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "contract_type": {
            "description": "Type of token contract: jetton_master, jetton_wallet, nft_collection, or nft_item.",
            "type": "string",
            "enum": [
              "nft_item"
            ],
            "default": "nft_item"
          },
          "init": {
            "description": "Returns `true` if this NFT item has been initialized (deployed); otherwise `false`.",
            "type": "boolean"
          },
          "index": {
            "description": "This item's sequential index within its collection.",
            "$ref": "#/components/schemas/Int256"
          },
          "collection_address": {
            "description": "Address of the NFT collection this item belongs to. Empty if standalone NFT.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "owner_address": {
            "description": "Current owner's address. Changes on each transfer.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "content": {
            "description": "NFT item metadata and content (name, description, image URL).",
            "oneOf": [
              {
                "$ref": "#/components/schemas/TokenContent"
              },
              {
                "$ref": "#/components/schemas/DnsContent"
              }
            ]
          }
        }
      },
      "TokenData": {
        "description": "Token metadata returned by getTokenData. Can be a Jetton master, Jetton wallet, NFT collection, or NFT item depending on which contract was queried.",
        "oneOf": [
          {
            "$ref": "#/components/schemas/JettonMasterData"
          },
          {
            "$ref": "#/components/schemas/JettonWalletData"
          },
          {
            "$ref": "#/components/schemas/NftCollectionData"
          },
          {
            "$ref": "#/components/schemas/NftItemData"
          }
        ],
        "discriminator": {
          "propertyName": "@type",
          "mapping": {
            "ext.tokens.jettonMasterData": "#/components/schemas/JettonMasterData",
            "ext.tokens.jettonWalletData": "#/components/schemas/JettonWalletData",
            "ext.tokens.nftCollectionData": "#/components/schemas/NftCollectionData",
            "ext.tokens.nftItemData": "#/components/schemas/NftItemData"
          }
        }
      },
      "DnsEntryDataUnknown": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "bytes"
        ],
        "properties": {
          "@type": {
            "type": "string",
            "enum": [
              "dns.entryDataUnknown"
            ],
            "default": "dns.entryDataUnknown"
          },
          "bytes": {
            "$ref": "#/components/schemas/Bytes"
          }
        }
      },
      "DnsEntryDataText": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "text"
        ],
        "properties": {
          "@type": {
            "type": "string",
            "enum": [
              "dns.entryDataText"
            ],
            "default": "dns.entryDataText"
          },
          "text": {
            "type": "string"
          }
        }
      },
      "DnsEntryDataNextResolver": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "resolver"
        ],
        "properties": {
          "@type": {
            "type": "string",
            "enum": [
              "dns.entryDataNextResolver"
            ],
            "default": "dns.entryDataNextResolver"
          },
          "resolver": {
            "$ref": "#/components/schemas/AccountAddress"
          }
        }
      },
      "DnsEntryDataSmcAddress": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "smc_address"
        ],
        "properties": {
          "@type": {
            "type": "string",
            "enum": [
              "dns.entryDataSmcAddress"
            ],
            "default": "dns.entryDataSmcAddress"
          },
          "smc_address": {
            "$ref": "#/components/schemas/AccountAddress"
          }
        }
      },
      "DnsEntryDataAdnlAddress": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "adnl_address"
        ],
        "properties": {
          "@type": {
            "type": "string",
            "enum": [
              "dns.entryDataAdnlAddress"
            ],
            "default": "dns.entryDataAdnlAddress"
          },
          "adnl_address": {
            "$ref": "#/components/schemas/AdnlAddress"
          }
        }
      },
      "DnsEntryDataStorageAddress": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "bag_id"
        ],
        "properties": {
          "@type": {
            "type": "string",
            "enum": [
              "dns.entryDataStorageAddress"
            ],
            "default": "dns.entryDataStorageAddress"
          },
          "bag_id": {
            "$ref": "#/components/schemas/TonHashHex"
          }
        }
      },
      "DnsEntryData": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/DnsEntryDataUnknown"
          },
          {
            "$ref": "#/components/schemas/DnsEntryDataText"
          },
          {
            "$ref": "#/components/schemas/DnsEntryDataNextResolver"
          },
          {
            "$ref": "#/components/schemas/DnsEntryDataSmcAddress"
          },
          {
            "$ref": "#/components/schemas/DnsEntryDataAdnlAddress"
          },
          {
            "$ref": "#/components/schemas/DnsEntryDataStorageAddress"
          }
        ],
        "discriminator": {
          "propertyName": "@type",
          "mapping": {
            "dns.entryDataUnknown": "#/components/schemas/DnsEntryDataUnknown",
            "dns.entryDataText": "#/components/schemas/DnsEntryDataText",
            "dns.entryDataNextResolver": "#/components/schemas/DnsEntryDataNextResolver",
            "dns.entryDataSmcAddress": "#/components/schemas/DnsEntryDataSmcAddress",
            "dns.entryDataAdnlAddress": "#/components/schemas/DnsEntryDataAdnlAddress",
            "dns.entryDataStorageAddress": "#/components/schemas/DnsEntryDataStorageAddress"
          }
        }
      },
      "DnsEntry": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "name",
          "category",
          "entry"
        ],
        "properties": {
          "@type": {
            "type": "string",
            "enum": [
              "dns.entry"
            ],
            "default": "dns.entry"
          },
          "name": {
            "type": "string"
          },
          "category": {
            "$ref": "#/components/schemas/TonHash"
          },
          "entry": {
            "$ref": "#/components/schemas/DnsEntryData"
          }
        }
      },
      "DnsResolved": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "entries"
        ],
        "properties": {
          "@type": {
            "type": "string",
            "enum": [
              "dns.resolved"
            ],
            "default": "dns.resolved"
          },
          "entries": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/DnsEntry"
            }
          }
        }
      },
      "AccountStateEnum": {
        "type": "string",
        "enum": [
          "uninitialized",
          "active",
          "frozen"
        ],
        "description": "Account lifecycle state: `uninitialized` (no contract deployed), `active` (contract deployed), or `frozen` (contract state frozen)."
      },
      "BlockSignature": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for validator signature objects.",
            "type": "string",
            "enum": [
              "blocks.signature"
            ],
            "default": "blocks.signature"
          },
          "node_id_short": {
            "description": "Short public key hash of the validator node that produced this signature.",
            "$ref": "#/components/schemas/TonHash"
          },
          "signature": {
            "description": "Ed25519 signature of the block by this validator, base64 encoded.",
            "$ref": "#/components/schemas/Bytes"
          }
        },
        "required": [
          "@type",
          "node_id_short",
          "signature"
        ]
      },
      "ShardBlockLink": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for shard-to-masterchain proof links.",
            "type": "string",
            "enum": [
              "blocks.shardBlockLink"
            ],
            "default": "blocks.shardBlockLink"
          },
          "id": {
            "description": "Block identifier for this link in the proof chain.",
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          "proof": {
            "description": "Merkle proof data for this shard block link.",
            "$ref": "#/components/schemas/Bytes"
          }
        },
        "required": [
          "@type",
          "id",
          "proof"
        ]
      },
      "BlockLinkBack": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for backward block link proofs.",
            "type": "string",
            "enum": [
              "blocks.blockLinkBack"
            ],
            "default": "blocks.blockLinkBack"
          },
          "to_key_block": {
            "description": "Returns `true` if the destination block is a key block; otherwise `false`.",
            "type": "boolean"
          },
          "from": {
            "description": "Source block in the proof chain.",
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          "to": {
            "description": "Destination block in the proof chain.",
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          "dest_proof": {
            "description": "Cryptographic proof for the destination block.",
            "$ref": "#/components/schemas/Bytes"
          },
          "proof": {
            "description": "Merkle proof linking the two blocks.",
            "$ref": "#/components/schemas/Bytes"
          },
          "state_proof": {
            "description": "State proof validating the block link.",
            "$ref": "#/components/schemas/Bytes"
          }
        },
        "required": [
          "@type",
          "to_key_block",
          "from",
          "to",
          "dest_proof",
          "proof",
          "state_proof"
        ]
      },
      "OutMsgQueueSize": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for per-shard queue size entries.",
            "type": "string",
            "enum": [
              "blocks.outMsgQueueSize"
            ],
            "default": "blocks.outMsgQueueSize"
          },
          "id": {
            "$ref": "#/components/schemas/TonBlockIdExt",
            "description": "Full block identifier for the shard."
          },
          "size": {
            "type": "integer",
            "description": "Number of outgoing messages waiting in this shard's queue."
          }
        },
        "required": [
          "@type",
          "id",
          "size"
        ]
      },
      "LibraryEntry": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for shared library cell entries.",
            "type": "string",
            "enum": [
              "smc.libraryEntry"
            ],
            "default": "smc.libraryEntry"
          },
          "hash": {
            "description": "Library cell hash.",
            "$ref": "#/components/schemas/TonHash"
          },
          "data": {
            "description": "Library cell code in BoC format, base64 encoded.",
            "$ref": "#/components/schemas/Bytes"
          }
        },
        "required": [
          "@type",
          "hash",
          "data"
        ]
      },
      "ShortTxId": {
        "type": "object",
        "additionalProperties": false,
        "description": "Compact transaction reference containing the account address, logical time, and hash. Used in block transaction listings for efficient enumeration.",
        "properties": {
          "@type": {
            "description": "TonLib type identifier for compact transaction references.",
            "type": "string",
            "enum": [
              "blocks.shortTxId"
            ],
            "default": "blocks.shortTxId"
          },
          "mode": {
            "type": "integer",
            "description": "Bitmask indicating which optional fields are present."
          },
          "account": {
            "description": "Account address that executed this transaction.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "lt": {
            "type": "string",
            "description": "Logical time of the transaction. Use together with its hash for pagination and lookups.",
            "x-usrv-cpp-type": "std::int64_t"
          },
          "hash": {
            "$ref": "#/components/schemas/TonHash",
            "description": "SHA-256 hash of this transaction, encoded in base64."
          }
        },
        "required": [
          "@type",
          "mode",
          "account",
          "lt",
          "hash"
        ]
      },
      "MsgDataRaw": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for raw (binary) message bodies.",
            "type": "string",
            "enum": [
              "msg.dataRaw"
            ],
            "default": "msg.dataRaw"
          },
          "body": {
            "description": "Raw message body in BoC format, base64 encoded.",
            "$ref": "#/components/schemas/Bytes"
          },
          "init_state": {
            "$ref": "#/components/schemas/Bytes"
          }
        }
      },
      "MsgDataText": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for plain text comment message bodies.",
            "type": "string",
            "enum": [
              "msg.dataText"
            ],
            "default": "msg.dataText"
          },
          "text": {
            "description": "UTF-8 text comment, base64 encoded.",
            "$ref": "#/components/schemas/Bytes"
          }
        }
      },
      "MsgDataDecryptedText": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for decrypted text message bodies.",
            "type": "string",
            "enum": [
              "msg.dataDecryptedText"
            ],
            "default": "msg.dataDecryptedText"
          },
          "text": {
            "description": "Decrypted UTF-8 text content, base64 encoded.",
            "$ref": "#/components/schemas/Bytes"
          }
        }
      },
      "MsgDataEncryptedText": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for encrypted text message bodies.",
            "type": "string",
            "enum": [
              "msg.dataEncryptedText"
            ],
            "default": "msg.dataEncryptedText"
          },
          "text": {
            "description": "Encrypted message payload, base64 encoded.",
            "$ref": "#/components/schemas/Bytes"
          }
        }
      },
      "MsgData": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/MsgDataRaw"
          },
          {
            "$ref": "#/components/schemas/MsgDataText"
          },
          {
            "$ref": "#/components/schemas/MsgDataDecryptedText"
          },
          {
            "$ref": "#/components/schemas/MsgDataEncryptedText"
          }
        ],
        "discriminator": {
          "propertyName": "@type",
          "mapping": {
            "msg.dataRaw": "#/components/schemas/MsgDataRaw",
            "msg.dataText": "#/components/schemas/MsgDataText",
            "msg.dataDecryptedText": "#/components/schemas/MsgDataDecryptedText",
            "msg.dataEncryptedText": "#/components/schemas/MsgDataEncryptedText"
          }
        }
      },
      "MessageStd": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for raw message objects.",
            "type": "string",
            "enum": [
              "raw.message"
            ],
            "default": "raw.message"
          },
          "hash": {
            "description": "SHA-256 hash of this message, encoded in base64.",
            "$ref": "#/components/schemas/TonHash"
          },
          "source": {
            "description": "Sender account address. Empty for external inbound messages.",
            "$ref": "#/components/schemas/AccountAddress"
          },
          "destination": {
            "description": "Recipient account address.",
            "$ref": "#/components/schemas/AccountAddress"
          },
          "value": {
            "description": "TON amount transferred with this message, in nanotons.",
            "$ref": "#/components/schemas/Int256"
          },
          "extra_currencies": {
            "description": "Array of extra currencies (native blockchain-level tokens, distinct from Jettons) transferred in this message. Each entry contains a currency ID (integer) and amount (decimal string). Empty array if no extra currencies were transferred.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ExtraCurrencyBalance"
            }
          },
          "fwd_fee": {
            "description": "Forwarding fee deducted from the message value, in nanotons.",
            "$ref": "#/components/schemas/Int256"
          },
          "ihr_fee": {
            "description": "Instant Hypercube Routing (IHR) fee in nanotons.",
            "$ref": "#/components/schemas/Int256"
          },
          "created_lt": {
            "type": "string",
            "description": "Logical time when this message was created.",
            "x-usrv-cpp-type": "std::int64_t"
          },
          "body_hash": {
            "description": "Hash of the message body.",
            "$ref": "#/components/schemas/TonHash"
          },
          "msg_data": {
            "description": "Message body payload (raw, text comment, or encrypted).",
            "$ref": "#/components/schemas/MsgData"
          }
        },
        "required": [
          "@type",
          "hash",
          "source",
          "destination",
          "value",
          "extra_currencies",
          "fwd_fee",
          "ihr_fee",
          "created_lt",
          "body_hash",
          "msg_data"
        ]
      },
      "TransactionStd": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for raw transaction objects.",
            "type": "string",
            "enum": [
              "raw.transaction"
            ],
            "default": "raw.transaction"
          },
          "address": {
            "description": "Account address object for this transaction.",
            "$ref": "#/components/schemas/AccountAddress"
          },
          "utime": {
            "type": "integer",
            "description": "Unix timestamp when this transaction was executed."
          },
          "data": {
            "description": "Full transaction data serialized as BoC, base64 encoded.",
            "$ref": "#/components/schemas/Bytes"
          },
          "transaction_id": {
            "description": "The transaction identifier, represented by logical time and transaction hash.",
            "$ref": "#/components/schemas/InternalTransactionId"
          },
          "fee": {
            "description": "Total fees paid for this transaction, in nanotons.",
            "$ref": "#/components/schemas/Int256"
          },
          "storage_fee": {
            "description": "Storage fees in nanotons deducted from the account balance during the storage phase of this transaction. Covers the cost of storing the contract state on-chain since the last transaction.",
            "$ref": "#/components/schemas/Int256"
          },
          "other_fee": {
            "description": "Fees in nanotons deducted from the account balance during the computation and action phases of this transaction. Covers the cost of TVM execution and processing outgoing messages.",
            "$ref": "#/components/schemas/Int256"
          },
          "in_msg": {
            "description": "The inbound message that triggered this transaction.",
            "$ref": "#/components/schemas/MessageStd"
          },
          "out_msgs": {
            "description": "Array of outbound messages produced by this transaction. Each message contains sender and recipient address objects, TON amount (nanotons as string), forwarding fee, and raw message body.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MessageStd"
            }
          }
        },
        "required": [
          "@type",
          "address",
          "utime",
          "data",
          "transaction_id",
          "fee",
          "storage_fee",
          "other_fee",
          "out_msgs"
        ]
      },
      "TransactionExt": {
        "allOf": [
          {
            "$ref": "#/components/schemas/TransactionStd"
          },
          {
            "type": "object",
            "additionalProperties": false,
            "properties": {
              "@type": {
                "description": "Object type identifier.",
                "type": "string",
                "enum": [
                  "raw.transactionExt"
                ],
                "default": "raw.transactionExt"
              },
              "account": {
                "description": "The account address that this transaction belongs to.",
                "$ref": "#/components/schemas/TonAddr"
              }
            }
          }
        ]
      },
      "Message": {
        "description": "A message between accounts. Contains sender, recipient, TON amount transferred, message creation logical time, and the message body.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for extended message objects with decoded comments.",
            "type": "string",
            "enum": [
              "ext.message"
            ],
            "default": "ext.message"
          },
          "hash": {
            "description": "SHA-256 hash of this message, encoded in base64.",
            "$ref": "#/components/schemas/TonHash"
          },
          "source": {
            "description": "Sender address. Empty for external inbound messages.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "destination": {
            "description": "Recipient address.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "value": {
            "description": "TON amount transferred with this message, in nanotons.",
            "$ref": "#/components/schemas/Int256"
          },
          "extra_currencies": {
            "description": "Array of extra currencies (native blockchain-level tokens, distinct from Jettons) transferred in this message. Each entry contains a currency ID (integer) and amount (decimal string). Empty array if no extra currencies were transferred.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ExtraCurrencyBalance"
            }
          },
          "fwd_fee": {
            "description": "Forwarding fee deducted from the message value, in nanotons.",
            "$ref": "#/components/schemas/Int256"
          },
          "ihr_fee": {
            "description": "Instant Hypercube Routing (IHR) fee in nanotons.",
            "$ref": "#/components/schemas/Int256"
          },
          "created_lt": {
            "type": "string",
            "description": "Logical time when this message was created.",
            "x-usrv-cpp-type": "std::int64_t"
          },
          "body_hash": {
            "description": "Hash of the message body. Useful for verifying content without the full payload.",
            "$ref": "#/components/schemas/TonHash"
          },
          "msg_data": {
            "description": "Message body payload (raw, text comment, or encrypted).",
            "$ref": "#/components/schemas/MsgData"
          },
          "message": {
            "description": "Decoded UTF-8 text comment from the message body. Present only when the message body is a plain text comment (opcode `0x00000000`). Empty string otherwise.",
            "type": "string"
          },
          "message_decode_error": {
            "description": "Error description if the message body could not be decoded as a text comment.",
            "type": "string"
          }
        },
        "required": [
          "@type",
          "hash",
          "source",
          "destination",
          "value",
          "extra_currencies",
          "fwd_fee",
          "ihr_fee",
          "created_lt",
          "body_hash",
          "msg_data"
        ]
      },
      "Transaction": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for extended transaction objects with decoded messages.",
            "type": "string",
            "enum": [
              "ext.transaction"
            ],
            "default": "ext.transaction"
          },
          "address": {
            "description": "Account address object for this transaction.",
            "$ref": "#/components/schemas/AccountAddress"
          },
          "account": {
            "description": "Account address in raw format.",
            "$ref": "#/components/schemas/TonAddr"
          },
          "utime": {
            "type": "integer",
            "description": "Unix timestamp when this transaction was executed."
          },
          "data": {
            "description": "Full transaction data serialized as BoC, base64 encoded.",
            "$ref": "#/components/schemas/Bytes"
          },
          "transaction_id": {
            "description": "The transaction identifier, represented by logical time and transaction hash.",
            "$ref": "#/components/schemas/InternalTransactionId"
          },
          "fee": {
            "description": "Total fees paid for this transaction, in nanotons.",
            "$ref": "#/components/schemas/Int256"
          },
          "storage_fee": {
            "description": "Storage fees in nanotons deducted from the account balance during the storage phase of this transaction. Covers the cost of storing the contract state on-chain since the last transaction.",
            "$ref": "#/components/schemas/Int256"
          },
          "other_fee": {
            "description": "Fees in nanotons deducted from the account balance during the computation and action phases of this transaction. Covers the cost of TVM execution and processing outgoing messages.",
            "$ref": "#/components/schemas/Int256"
          },
          "in_msg": {
            "description": "The inbound message that triggered this transaction.",
            "$ref": "#/components/schemas/Message"
          },
          "out_msgs": {
            "description": "Array of outbound messages produced by this transaction. Each message contains sender, recipient, TON amount (nanotons as string), forwarding fee, message body, and optional decoded text comment.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Message"
            }
          }
        },
        "required": [
          "@type",
          "address",
          "account",
          "utime",
          "data",
          "transaction_id",
          "fee",
          "storage_fee",
          "other_fee",
          "out_msgs"
        ]
      },
      "TonlibObject": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/DetectAddress"
          },
          {
            "$ref": "#/components/schemas/DetectHash"
          },
          {
            "$ref": "#/components/schemas/AddressInformation"
          },
          {
            "$ref": "#/components/schemas/ExtendedAddressInformation"
          },
          {
            "$ref": "#/components/schemas/WalletInformation"
          },
          {
            "$ref": "#/components/schemas/JettonMasterData"
          },
          {
            "$ref": "#/components/schemas/JettonWalletData"
          },
          {
            "$ref": "#/components/schemas/NftCollectionData"
          },
          {
            "$ref": "#/components/schemas/NftItemData"
          },
          {
            "$ref": "#/components/schemas/DnsResolved"
          },
          {
            "$ref": "#/components/schemas/MasterchainInfo"
          },
          {
            "$ref": "#/components/schemas/BlockSignatures"
          },
          {
            "$ref": "#/components/schemas/BlockSignaturesSimplex"
          },
          {
            "$ref": "#/components/schemas/ShardBlockProof"
          },
          {
            "$ref": "#/components/schemas/ConsensusBlock"
          },
          {
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          {
            "$ref": "#/components/schemas/Shards"
          },
          {
            "$ref": "#/components/schemas/BlockData"
          },
          {
            "$ref": "#/components/schemas/BlockHeader"
          },
          {
            "$ref": "#/components/schemas/OutMsgQueueSizes"
          },
          {
            "$ref": "#/components/schemas/BlockTransactions"
          },
          {
            "$ref": "#/components/schemas/BlockTransactionsExt"
          },
          {
            "$ref": "#/components/schemas/Transaction"
          },
          {
            "$ref": "#/components/schemas/TransactionsStd"
          },
          {
            "$ref": "#/components/schemas/ConfigInfo"
          },
          {
            "$ref": "#/components/schemas/LibraryResult"
          },
          {
            "$ref": "#/components/schemas/QueryFees"
          },
          {
            "$ref": "#/components/schemas/ExtMessageInfo"
          },
          {
            "$ref": "#/components/schemas/ResultOk"
          },
          {
            "$ref": "#/components/schemas/RunGetMethodStdResult"
          },
          {
            "$ref": "#/components/schemas/RunGetMethodResult"
          },
          {
            "$ref": "#/components/schemas/TvmCell"
          }
        ],
        "discriminator": {
          "propertyName": "@type",
          "mapping": {
            "ext.utils.detectAddress": "#/components/schemas/DetectAddress",
            "ext.utils.detectedHash": "#/components/schemas/DetectHash",
            "raw.fullAccountState": "#/components/schemas/AddressInformation",
            "fullAccountState": "#/components/schemas/ExtendedAddressInformation",
            "ext.accounts.walletInformation": "#/components/schemas/WalletInformation",
            "ext.tokens.jettonMasterData": "#/components/schemas/JettonMasterData",
            "ext.tokens.jettonWalletData": "#/components/schemas/JettonWalletData",
            "ext.tokens.nftCollectionData": "#/components/schemas/NftCollectionData",
            "ext.tokens.nftItemData": "#/components/schemas/NftItemData",
            "dns.resolved": "#/components/schemas/DnsResolved",
            "blocks.masterchainInfo": "#/components/schemas/MasterchainInfo",
            "blocks.blockSignatures": "#/components/schemas/BlockSignatures",
            "blocks.blockSignatures.simplex": "#/components/schemas/BlockSignaturesSimplex",
            "blocks.shardBlockProof": "#/components/schemas/ShardBlockProof",
            "ext.blocks.consensusBlock": "#/components/schemas/ConsensusBlock",
            "ton.blockIdExt": "#/components/schemas/TonBlockIdExt",
            "blocks.shards": "#/components/schemas/Shards",
            "blocks.blockData": "#/components/schemas/BlockData",
            "blocks.header": "#/components/schemas/BlockHeader",
            "blocks.outMsgQueueSizes": "#/components/schemas/OutMsgQueueSizes",
            "blocks.transactions": "#/components/schemas/BlockTransactions",
            "blocks.transactionsExt": "#/components/schemas/BlockTransactionsExt",
            "ext.transaction": "#/components/schemas/Transaction",
            "raw.transactions": "#/components/schemas/TransactionsStd",
            "configInfo": "#/components/schemas/ConfigInfo",
            "query.fees": "#/components/schemas/QueryFees",
            "smc.libraryResult": "#/components/schemas/LibraryResult",
            "raw.extMessageInfo": "#/components/schemas/ExtMessageInfo",
            "ok": "#/components/schemas/ResultOk",
            "smc.runResult": "#/components/schemas/RunGetMethodStdResult",
            "ext.runResult": "#/components/schemas/RunGetMethodResult",
            "tvm.cell": "#/components/schemas/TvmCell"
          }
        }
      },
      "TonlibResponse": {
        "type": "object",
        "title": "TonlibResponse",
        "additionalProperties": false,
        "required": [
          "ok",
          "result",
          "@extra"
        ],
        "properties": {
          "ok": {
            "description": "Returns `true` if the request succeeded; otherwise `false`. See the `error` field for details.",
            "type": "boolean",
            "title": "Ok",
            "default": true
          },
          "result": {
            "description": "The method return value. The structure depends on the method called; see individual method documentation for response schemas. Only present when `ok` is `true`.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "$ref": "#/components/schemas/AccountStateEnum"
              },
              {
                "$ref": "#/components/schemas/TonlibObject"
              },
              {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/TonlibObject"
                }
              }
            ]
          },
          "@extra": {
            "type": "string",
            "title": "Extra information"
          },
          "jsonrpc": {
            "description": "JSON-RPC protocol version identifier.",
            "type": "string"
          },
          "id": {
            "type": "string"
          }
        }
      },
      "TonlibErrorResponse": {
        "description": "The `ok` field is always false, `code` contains the HTTP status, and `error` describes what went wrong.",
        "type": "object",
        "additionalProperties": false,
        "title": "TonlibErrorResponse",
        "required": [
          "ok",
          "error",
          "code"
        ],
        "properties": {
          "ok": {
            "description": "Always `false` for error responses.",
            "type": "boolean",
            "title": "Ok",
            "default": false
          },
          "error": {
            "description": "Error message explaining what went wrong.",
            "type": "string",
            "title": "Error description"
          },
          "code": {
            "description": "HTTP status code. Common values: 404 (not found), 409 (conflict), 422 (validation error), 429 (rate limit), 500 (server error), 504 (timeout), 542 (liteserver error).",
            "type": "integer",
            "title": "Error code",
            "minimum": 100,
            "maximum": 600
          },
          "@extra": {
            "type": "string",
            "title": "Extra information"
          },
          "jsonrpc": {
            "type": "string"
          },
          "id": {
            "type": "string"
          }
        }
      },
      "JsonRpcResponse": {
        "allOf": [
          {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "jsonrpc",
              "id"
            ],
            "properties": {
              "jsonrpc": {
                "description": "JSON-RPC protocol version identifier.",
                "type": "string",
                "default": "2.0"
              },
              "id": {
                "type": "string"
              }
            }
          },
          {
            "$ref": "#/components/schemas/TonlibResponse"
          }
        ]
      },
      "JsonRpcErrorResponse": {
        "allOf": [
          {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "jsonrpc",
              "id"
            ],
            "properties": {
              "jsonrpc": {
                "description": "JSON-RPC protocol version identifier.",
                "type": "string",
                "default": "2.0"
              },
              "id": {
                "type": "string"
              }
            }
          },
          {
            "$ref": "#/components/schemas/TonlibErrorResponse"
          }
        ]
      },
      "DetectAddress": {
        "type": "object",
        "additionalProperties": false,
        "description": "Detected address in all supported formats. Contains the raw on-chain form, bounceable and non-bounceable user-friendly representations (each in base64 and URL-safe base64), the format type of the original input, and the testnet-only flag from the user-friendly encoding.",
        "properties": {
          "@type": {
            "description": "TonLib type identifier for address detection results.",
            "type": "string",
            "enum": [
              "ext.utils.detectedAddress"
            ],
            "default": "ext.utils.detectedAddress"
          },
          "raw_form": {
            "description": "Raw address in `workchain_id:account_id` hex format (e.g., `0:abc...def`). This is the canonical on-chain representation without flags or checksum.",
            "type": "string"
          },
          "bounceable": {
            "description": "Bounceable form of the address in standard base64 and URL-safe base64. Bounceable addresses (prefix `E...`) instruct wallet software to set the bounce flag on outgoing messages, so funds are returned if the destination contract cannot process them.",
            "$ref": "#/components/schemas/DetectAddressBase64Variant"
          },
          "non_bounceable": {
            "description": "Non-bounceable form of the address in standard base64 and URL-safe base64. Non-bounceable addresses (prefix `U...`) instruct wallet software to clear the bounce flag, ensuring funds are credited even if the recipient has no deployed contract.",
            "$ref": "#/components/schemas/DetectAddressBase64Variant"
          },
          "given_type": {
            "description": "The encoding format of the address as provided in the request (e.g., `raw_form`, `dns`, `friendly_bounceable`, `friendly_non_bounceable`).",
            "type": "string",
            "enum": [
              "raw_form",
              "friendly_bounceable",
              "friendly_non_bounceable"
            ]
          },
          "test_only": {
            "description": "Returns `true` if the user-friendly address has the testnet-only flag set (`0x80`); otherwise `false`. This is a flag in the address encoding that tells wallet software to reject this address on mainnet. The underlying account itself can exist on both networks.",
            "type": "boolean"
          }
        },
        "required": [
          "@type",
          "raw_form",
          "bounceable",
          "non_bounceable",
          "given_type",
          "test_only"
        ]
      },
      "DetectHash": {
        "description": "Detected hash in all supported encoding formats: hex (64 characters), standard base64 (44 characters), and URL-safe base64.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for hash detection results.",
            "type": "string",
            "enum": [
              "ext.utils.detectedHash"
            ],
            "default": "ext.utils.detectedHash"
          },
          "b64": {
            "description": "Hash in standard base64 encoding (44 characters, uses `+` and `/`).",
            "type": "string",
            "title": "base64 form"
          },
          "b64url": {
            "description": "Hash in URL-safe base64 encoding (44 characters, uses `-` and `_` instead of `+` and `/`).",
            "type": "string",
            "title": "base64 url-safe form"
          },
          "hex": {
            "description": "Hash in lowercase hexadecimal encoding (64 characters).",
            "type": "string",
            "title": "hex form"
          }
        },
        "required": [
          "@type",
          "b64",
          "b64url",
          "hex"
        ]
      },
      "PackAddress": {
        "type": "string",
        "title": "Address packed in base64",
        "x-usrv-cpp-type": "ton_http::types::bytes"
      },
      "UnpackAddress": {
        "type": "string",
        "title": "Address unpacked to raw form"
      },
      "AddressInformation": {
        "description": "Raw account state including balance, code, data, and status. The code and data fields contain the smart contract in BoC format.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for full account state responses.",
            "type": "string",
            "enum": [
              "raw.fullAccountState"
            ],
            "default": "raw.fullAccountState"
          },
          "balance": {
            "description": "Account balance in nanotons as a decimal string. 1 TON = 1,000,000,000 nanotons.",
            "$ref": "#/components/schemas/Int256"
          },
          "extra_currencies": {
            "description": "Array of non-TON currency balances held by this account. Each entry contains a currency ID (integer) and balance amount (decimal string). Empty array if the account holds no extra currencies.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ExtraCurrencyBalance"
            }
          },
          "last_transaction_id": {
            "description": "Reference to the most recent transaction. Use as starting point for getTransactions.",
            "$ref": "#/components/schemas/InternalTransactionId"
          },
          "block_id": {
            "description": "Full block identifier where this event occurred.",
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          "code": {
            "description": "Smart contract code in BoC format, base64 encoded.",
            "$ref": "#/components/schemas/Bytes"
          },
          "data": {
            "description": "Smart contract persistent storage in BoC format, base64 encoded.",
            "$ref": "#/components/schemas/Bytes"
          },
          "frozen_hash": {
            "$ref": "#/components/schemas/TonHash"
          },
          "sync_utime": {
            "description": "Unix timestamp of the block from which this data was read.",
            "type": "integer",
            "format": "int64"
          },
          "state": {
            "description": "Account state: uninitialized, active, or frozen.",
            "$ref": "#/components/schemas/AccountStateEnum"
          },
          "suspended": {
            "type": "boolean"
          }
        },
        "required": [
          "@type",
          "balance",
          "extra_currencies",
          "code",
          "data",
          "last_transaction_id",
          "block_id",
          "frozen_hash",
          "sync_utime",
          "state"
        ]
      },
      "ExtendedAddressInformation": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for extended account state responses.",
            "type": "string",
            "enum": [
              "fullAccountState"
            ],
            "default": "fullAccountState"
          },
          "address": {
            "description": "Account address object.",
            "$ref": "#/components/schemas/AccountAddress"
          },
          "balance": {
            "description": "Account balance in nanotons as a decimal string. 1 TON = 1,000,000,000 nanotons.",
            "$ref": "#/components/schemas/Int256"
          },
          "extra_currencies": {
            "description": "Array of non-TON currency balances held by this account. Each entry contains a currency ID (integer) and balance amount (decimal string). Empty array if the account holds no extra currencies.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ExtraCurrencyBalance"
            }
          },
          "last_transaction_id": {
            "description": "Reference to the most recent transaction. Use as starting point for getTransactions.",
            "$ref": "#/components/schemas/InternalTransactionId"
          },
          "block_id": {
            "description": "Full block identifier where this event occurred.",
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          "sync_utime": {
            "description": "Unix timestamp of the block from which this data was read.",
            "type": "integer",
            "format": "int64"
          },
          "account_state": {
            "description": "Detailed account state including contract type and internal data.",
            "$ref": "#/components/schemas/AccountState"
          },
          "revision": {
            "description": "Contract revision number. Different revisions may have different behavior.",
            "type": "integer"
          }
        },
        "required": [
          "@type",
          "address",
          "balance",
          "extra_currencies",
          "last_transaction_id",
          "block_id",
          "sync_utime",
          "account_state",
          "revision"
        ]
      },
      "WalletInformation": {
        "description": "Information about a wallet account. Check `wallet` before using wallet-specific fields such as `wallet_type`, `seqno`, and `wallet_id`; available fields depend on the wallet type.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for wallet info responses.",
            "type": "string",
            "enum": [
              "ext.accounts.walletInformation"
            ],
            "default": "ext.accounts.walletInformation"
          },
          "wallet": {
            "description": "Returns `true` if this address is a recognized wallet contract type; otherwise `false`.",
            "type": "boolean"
          },
          "balance": {
            "description": "Account balance in nanotons as a decimal string.",
            "type": "string",
            "x-usrv-cpp-type": "ton_http::types::int256"
          },
          "account_state": {
            "description": "Account lifecycle state: `uninitialized`, `active`, or `frozen`.",
            "$ref": "#/components/schemas/AccountStateEnum"
          },
          "last_transaction_id": {
            "description": "Reference to the most recent transaction. Use as starting point for getTransactions.",
            "$ref": "#/components/schemas/InternalTransactionId"
          },
          "wallet_type": {
            "description": "Recognized wallet contract type, such as `wallet v4 r2`, `wallet v5 r1`, or `tg-wallet`.",
            "type": "string",
            "enum": [
              "wallet v1 r1",
              "wallet v1 r2",
              "wallet v1 r3",
              "wallet v2 r1",
              "wallet v2 r2",
              "wallet v3 r1",
              "wallet v3 r2",
              "wallet v4 r1",
              "wallet v4 r2",
              "wallet v5 beta",
              "wallet v5 r1",
              "tg-wallet"
            ]
          },
          "seqno": {
            "description": "Wallet contract sequence number. Used for replay protection: each outgoing transaction must include the current `seqno` and increments it by 1. Fetch the current value before sending a transaction.",
            "type": "integer",
            "format": "int64"
          },
          "wallet_id": {
            "description": "Subwallet identifier. Allows creating multiple wallets from one key.",
            "type": "integer"
          },
          "is_signature_allowed": {
            "description": "Whether signature authentication is enabled for this wallet (v5 wallets only).",
            "type": "boolean"
          }
        },
        "required": [
          "@type",
          "wallet",
          "balance",
          "account_state",
          "last_transaction_id"
        ]
      },
      "AddressBalance": {
        "$ref": "#/components/schemas/Int256"
      },
      "AddressState": {
        "$ref": "#/components/schemas/AccountStateEnum"
      },
      "MasterchainInfo": {
        "type": "object",
        "additionalProperties": false,
        "description": "Information about the latest masterchain block.",
        "properties": {
          "@type": {
            "description": "TonLib type identifier for masterchain state info.",
            "type": "string",
            "enum": [
              "blocks.masterchainInfo"
            ],
            "default": "blocks.masterchainInfo"
          },
          "last": {
            "description": "The most recent masterchain block.",
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          "state_root_hash": {
            "$ref": "#/components/schemas/TonHash"
          },
          "init": {
            "$ref": "#/components/schemas/TonBlockIdExt"
          }
        },
        "required": [
          "@type",
          "last",
          "state_root_hash",
          "init"
        ]
      },
      "BlockSignatures": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "type": "string",
            "enum": [
              "blocks.blockSignatures"
            ],
            "default": "blocks.blockSignatures"
          },
          "id": {
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          "signatures": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BlockSignature"
            }
          }
        },
        "required": [
          "@type",
          "id",
          "signatures"
        ]
      },
      "BlockSignaturesSimplex": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "type": "string",
            "enum": [
              "blocks.blockSignatures.simplex"
            ],
            "default": "blocks.blockSignatures.simplex"
          },
          "id": {
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          "signatures": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BlockSignature"
            }
          },
          "session_id": {
            "$ref": "#/components/schemas/TonHash"
          },
          "slot": {
            "type": "integer",
            "format": "int32"
          },
          "candidate": {
            "$ref": "#/components/schemas/Bytes"
          }
        },
        "required": [
          "@type",
          "id",
          "signatures",
          "session_id",
          "slot",
          "candidate"
        ]
      },
      "MasterchainBlockSignatures": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/BlockSignatures"
          },
          {
            "$ref": "#/components/schemas/BlockSignaturesSimplex"
          }
        ],
        "discriminator": {
          "propertyName": "@type",
          "mapping": {
            "blocks.blockSignatures": "#/components/schemas/BlockSignatures",
            "blocks.blockSignatures.simplex": "#/components/schemas/BlockSignaturesSimplex"
          }
        }
      },
      "ShardBlockProof": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for shard block proof chains.",
            "type": "string",
            "enum": [
              "blocks.shardBlockProof"
            ],
            "default": "blocks.shardBlockProof"
          },
          "from": {
            "description": "The shard block being proven.",
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          "mc_id": {
            "description": "Masterchain block used as trust anchor for the proof.",
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          "links": {
            "description": "Array of cryptographic links forming a proof chain from the shard block to the masterchain. Each link contains a block identifier and a Merkle proof (base64).",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShardBlockLink"
            }
          },
          "mc_proof": {
            "description": "Array of masterchain block link proofs. Each entry contains source and destination block identifiers with corresponding Merkle proofs (base64) and state proofs (base64).",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BlockLinkBack"
            }
          }
        },
        "required": [
          "@type",
          "from",
          "mc_id",
          "links",
          "mc_proof"
        ]
      },
      "ConsensusBlock": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for consensus block info.",
            "type": "string",
            "enum": [
              "ext.blocks.consensusBlock"
            ],
            "default": "ext.blocks.consensusBlock"
          },
          "consensus_block": {
            "description": "Sequence number of the latest consensus block.",
            "type": "integer",
            "format": "int32"
          },
          "timestamp": {
            "type": "integer",
            "format": "int32"
          }
        },
        "required": [
          "@type",
          "consensus_block",
          "timestamp"
        ]
      },
      "LookupBlock": {
        "$ref": "#/components/schemas/TonBlockIdExt"
      },
      "Shards": {
        "description": "List of shardchain blocks at a specific masterchain height. Shows how the basechain is currently partitioned.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for shard listing responses.",
            "type": "string",
            "enum": [
              "blocks.shards"
            ],
            "default": "blocks.shards"
          },
          "shards": {
            "description": "Array of active shard block identifiers. Each entry contains `workchain` (integer), `shard` ID (string), `seqno` (integer), `root_hash` (base64/hex), and `file_hash` (base64/hex).",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TonBlockIdExt"
            }
          }
        },
        "required": [
          "@type",
          "shards"
        ]
      },
      "BlockData": {
        "type": "object",
        "additionalProperties": false,
        "description": "Raw block data returned by a LiteServer.",
        "properties": {
          "@type": {
            "type": "string",
            "enum": [
              "blocks.blockData"
            ],
            "default": "blocks.blockData"
          },
          "id": {
            "$ref": "#/components/schemas/TonBlockIdExt",
            "description": "Extended identifier of the returned block."
          },
          "data": {
            "$ref": "#/components/schemas/Bytes",
            "description": "Full block BOC encoded as base64."
          }
        },
        "required": [
          "@type",
          "id",
          "data"
        ]
      },
      "BlockHeader": {
        "type": "object",
        "additionalProperties": true,
        "description": "Block metadata including creation time, validator info, and links to previous blocks. Does not include the transactions themselves.",
        "properties": {
          "@type": {
            "description": "TonLib type identifier for block header objects.",
            "type": "string",
            "enum": [
              "blocks.header"
            ],
            "default": "blocks.header"
          },
          "id": {
            "$ref": "#/components/schemas/TonBlockIdExt",
            "description": "Full block identifier including workchain, shard, `seqno`, and hashes."
          },
          "global_id": {
            "type": "integer",
            "description": "Global network identifier."
          },
          "version": {
            "type": "integer",
            "description": "Block format version number."
          },
          "after_merge": {
            "type": "boolean",
            "description": "Returns `true` if this block was created immediately after a shard merge; otherwise `false`."
          },
          "after_split": {
            "type": "boolean",
            "description": "Returns `true` if this block was created immediately after a shard split; otherwise `false`."
          },
          "before_split": {
            "type": "boolean",
            "description": "Returns `true` if this shard will split after this block; otherwise `false`."
          },
          "want_merge": {
            "type": "boolean",
            "description": "Returns `true` if validators have signaled a preference to merge this shard; otherwise `false`."
          },
          "want_split": {
            "type": "boolean",
            "description": "Returns `true` if validators have signaled a preference to split this shard; otherwise `false`."
          },
          "validator_list_hash_short": {
            "type": "integer",
            "description": "Short hash of the validator set active during this block."
          },
          "catchain_seqno": {
            "type": "integer",
            "description": "Catchain sequence number used for validator consensus."
          },
          "min_ref_mc_seqno": {
            "type": "integer",
            "description": "Minimum masterchain block `seqno` referenced by this block."
          },
          "is_key_block": {
            "type": "boolean",
            "description": "Returns `true` if this is a key block containing validator set changes or config updates; otherwise `false`."
          },
          "prev_key_block_seqno": {
            "type": "integer",
            "description": "Sequence number of the previous key block."
          },
          "start_lt": {
            "type": "string",
            "description": "Logical time at the start of this block.",
            "x-usrv-cpp-type": "std::int64_t"
          },
          "end_lt": {
            "type": "string",
            "description": "Ending logical time.",
            "x-usrv-cpp-type": "std::int64_t"
          },
          "gen_utime": {
            "type": "integer",
            "description": "Unix timestamp when this block was generated."
          },
          "prev_blocks": {
            "type": "array",
            "description": "Array of previous block identifiers (`workchain`, `shard`, `seqno`, `root_hash`, `file_hash`). Usually contains one entry, but two after a shard merge.",
            "items": {
              "$ref": "#/components/schemas/TonBlockIdExt"
            }
          }
        },
        "required": [
          "@type",
          "id",
          "global_id",
          "version",
          "after_merge",
          "after_split",
          "before_split",
          "want_merge",
          "want_split",
          "validator_list_hash_short",
          "catchain_seqno",
          "min_ref_mc_seqno",
          "is_key_block",
          "prev_key_block_seqno",
          "start_lt",
          "end_lt",
          "gen_utime",
          "prev_blocks"
        ]
      },
      "OutMsgQueueSizes": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for outgoing message queue size responses.",
            "type": "string",
            "enum": [
              "blocks.outMsgQueueSizes"
            ],
            "default": "blocks.outMsgQueueSizes"
          },
          "shards": {
            "type": "array",
            "description": "Array of per-shard queue sizes. Each entry contains the shard's block identifier and the number of outgoing messages waiting in its queue (integer).",
            "items": {
              "$ref": "#/components/schemas/OutMsgQueueSize"
            }
          },
          "ext_msg_queue_size_limit": {
            "type": "integer",
            "description": "Limit for the external message queue size."
          }
        },
        "required": [
          "@type",
          "shards",
          "ext_msg_queue_size_limit"
        ]
      },
      "ConfigInfo": {
        "description": "Blockchain configuration data. Contains one or more config parameters as requested. Each parameter controls different aspects of network operation.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for blockchain configuration responses.",
            "type": "string",
            "enum": [
              "configInfo"
            ],
            "default": "configInfo"
          },
          "config": {
            "description": "The requested configuration parameter value as a TVM cell.",
            "$ref": "#/components/schemas/TvmCell"
          }
        },
        "required": [
          "@type",
          "config"
        ]
      },
      "LibraryResult": {
        "description": "Library code fetched by hash. Contains the actual code cells for shared libraries referenced by smart contracts.",
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "@type": {
            "description": "TonLib type identifier for library lookup results.",
            "type": "string",
            "enum": [
              "smc.libraryResult"
            ],
            "default": "smc.libraryResult"
          },
          "result": {
            "description": "Array of library entries. Each entry contains a hash (base64 or hex) identifying the library and a data field with the library code in BoC format (base64).",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/LibraryEntry"
            }
          }
        },
        "required": [
          "@type",
          "result"
        ]
      },
      "BlockTransactions": {
        "type": "object",
        "additionalProperties": false,
        "description": "List of short transaction identifiers found in a specific block, with a flag indicating whether more transactions are available for pagination.",
        "properties": {
          "@type": {
            "description": "TonLib type identifier for block transaction listings.",
            "type": "string",
            "enum": [
              "blocks.transactions"
            ],
            "default": "blocks.transactions"
          },
          "id": {
            "description": "Full block identifier for the queried block.",
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          "req_count": {
            "type": "integer",
            "description": "The maximum number of transactions requested, as specified by the `count` request parameter. If `incomplete` is `true`, more transactions exist beyond this limit."
          },
          "incomplete": {
            "type": "boolean",
            "description": "Returns `true` if there are more transactions in this block; otherwise `false`. Use the last transaction as cursor for pagination."
          },
          "transactions": {
            "type": "array",
            "description": "Array of compact transaction references. Each entry contains the account address (string), logical time (string), and transaction hash (base64 or hex).",
            "items": {
              "$ref": "#/components/schemas/ShortTxId"
            }
          }
        },
        "required": [
          "@type",
          "id",
          "req_count",
          "incomplete",
          "transactions"
        ]
      },
      "BlockTransactionsExt": {
        "type": "object",
        "additionalProperties": false,
        "description": "List of full transaction objects found in a specific block, with a flag indicating whether more transactions are available for pagination.",
        "properties": {
          "@type": {
            "description": "TonLib type identifier for extended block transaction listings.",
            "type": "string",
            "enum": [
              "blocks.transactionsExt"
            ],
            "default": "blocks.transactionsExt"
          },
          "id": {
            "description": "Full block identifier for the queried block.",
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          "req_count": {
            "type": "integer",
            "description": "The maximum number of transactions requested, as specified by the `count` request parameter. If `incomplete` is `true`, more transactions exist beyond this limit."
          },
          "incomplete": {
            "type": "boolean",
            "description": "Returns `true` if there are more transactions in this block; otherwise `false`. Use the last transaction as cursor for pagination."
          },
          "transactions": {
            "type": "array",
            "description": "Array of full transaction objects. Each entry contains the account address, timestamps, inbound/outbound messages, fees (in nanotons), and the raw transaction BoC (base64).",
            "items": {
              "$ref": "#/components/schemas/TransactionExt"
            }
          }
        },
        "required": [
          "@type",
          "id",
          "req_count",
          "incomplete",
          "transactions"
        ]
      },
      "Transactions": {
        "type": "array",
        "items": {
          "$ref": "#/components/schemas/Transaction"
        }
      },
      "TransactionsStd": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "transactions",
          "previous_transaction_id"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for paginated raw transaction lists.",
            "type": "string",
            "enum": [
              "raw.transactions"
            ],
            "default": "raw.transactions"
          },
          "transactions": {
            "description": "Array of transaction objects in standardized format. Each transaction contains address, timestamps, inbound/outbound messages, fees in nanotons, and raw BoC (base64).",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TransactionStd"
            }
          },
          "previous_transaction_id": {
            "description": "Use this as cursor to fetch the next page of older transactions.",
            "$ref": "#/components/schemas/InternalTransactionId"
          }
        }
      },
      "ExtMessageInfo": {
        "description": "Information about a broadcast external message. Contains the message hash which can be used to track processing.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "hash",
          "hash_norm"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for external message info after broadcast.",
            "type": "string",
            "enum": [
              "raw.extMessageInfo"
            ],
            "default": "raw.extMessageInfo"
          },
          "hash": {
            "description": "SHA-256 hash of the external message as accepted by the network.",
            "$ref": "#/components/schemas/TonHash"
          },
          "hash_norm": {
            "$ref": "#/components/schemas/TonHash"
          }
        }
      },
      "ResultOk": {
        "description": "Simple success response with no additional data.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for successful operations with no return data.",
            "type": "string",
            "enum": [
              "ok"
            ],
            "default": "ok"
          }
        }
      },
      "SendBocResult": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/ResultOk"
          },
          {
            "$ref": "#/components/schemas/ExtMessageInfo"
          }
        ],
        "discriminator": {
          "propertyName": "@type",
          "mapping": {
            "ok": "#/components/schemas/ResultOk",
            "ext.messageInfo": "#/components/schemas/ExtMessageInfo"
          }
        }
      },
      "Fees": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "in_fwd_fee",
          "storage_fee",
          "gas_fee",
          "fwd_fee"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for fee breakdown objects.",
            "type": "string",
            "enum": [
              "fees"
            ],
            "default": "fees"
          },
          "in_fwd_fee": {
            "description": "Fee for importing this inbound message, in nanotons.",
            "type": "integer",
            "format": "int64"
          },
          "storage_fee": {
            "description": "Storage fee charged for keeping the contract state on-chain, in nanotons.",
            "type": "integer",
            "format": "int64"
          },
          "gas_fee": {
            "description": "Computation gas fee for executing contract code, in nanotons.",
            "type": "integer",
            "format": "int64"
          },
          "fwd_fee": {
            "description": "Fee for forwarding outbound messages created by this transaction, in nanotons.",
            "type": "integer",
            "format": "int64"
          }
        }
      },
      "QueryFees": {
        "description": "Estimated fees for a transaction. Shows the breakdown between storage fees (for contract state), gas fees (for computation), and forward fees (for message delivery).",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "source_fees",
          "destination_fees"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for fee estimation results.",
            "type": "string",
            "enum": [
              "query.fees"
            ],
            "default": "query.fees"
          },
          "source_fees": {
            "description": "Fees charged on the sending account.",
            "$ref": "#/components/schemas/Fees"
          },
          "destination_fees": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Fees"
            }
          }
        }
      },
      "TvmStackEntrySlice": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "slice"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for slice-typed stack entries.",
            "type": "string",
            "enum": [
              "tvm.stackEntrySlice"
            ],
            "default": "tvm.stackEntrySlice"
          },
          "slice": {
            "description": "The TVM slice value.",
            "$ref": "#/components/schemas/TvmSlice"
          }
        }
      },
      "TvmStackEntryCell": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "cell"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for cell-typed stack entries.",
            "type": "string",
            "enum": [
              "tvm.stackEntryCell"
            ],
            "default": "tvm.stackEntryCell"
          },
          "cell": {
            "description": "The TVM cell value.",
            "$ref": "#/components/schemas/TvmCell"
          }
        }
      },
      "TvmStackEntryNumber": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "number"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for number-typed stack entries.",
            "type": "string",
            "enum": [
              "tvm.stackEntryNumber"
            ],
            "default": "tvm.stackEntryNumber"
          },
          "number": {
            "description": "The TVM number value (arbitrary-precision decimal).",
            "$ref": "#/components/schemas/TvmNumberDecimal"
          }
        }
      },
      "TvmStackEntryTuple": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "tuple"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for tuple-typed stack entries.",
            "type": "string",
            "enum": [
              "tvm.stackEntryTuple"
            ],
            "default": "tvm.stackEntryTuple"
          },
          "tuple": {
            "description": "The TVM tuple value.",
            "$ref": "#/components/schemas/TvmTuple"
          }
        }
      },
      "TvmStackEntryList": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "list"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for list-typed stack entries.",
            "type": "string",
            "enum": [
              "tvm.stackEntryList"
            ],
            "default": "tvm.stackEntryList"
          },
          "list": {
            "description": "The TVM list value.",
            "$ref": "#/components/schemas/TvmList"
          }
        }
      },
      "TvmStackEntryUnsupported": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for stack entries with unsupported types.",
            "type": "string",
            "enum": [
              "tvm.stackEntryUnsupported"
            ],
            "default": "tvm.stackEntryUnsupported"
          }
        }
      },
      "TvmSlice": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "bytes"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for TVM slice values.",
            "type": "string",
            "enum": [
              "tvm.slice"
            ],
            "default": "tvm.slice"
          },
          "bytes": {
            "description": "TVM slice data serialized as base64.",
            "$ref": "#/components/schemas/Bytes"
          }
        }
      },
      "TvmCell": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "bytes"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for TVM cell values.",
            "type": "string",
            "enum": [
              "tvm.cell"
            ],
            "default": "tvm.cell"
          },
          "bytes": {
            "description": "TVM cell data serialized as base64.",
            "$ref": "#/components/schemas/Bytes"
          }
        }
      },
      "TvmNumberDecimal": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "number"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for TVM decimal number values.",
            "type": "string",
            "enum": [
              "tvm.numberDecimal"
            ],
            "default": "tvm.numberDecimal"
          },
          "number": {
            "description": "Integer value as a decimal string (supports arbitrarily large numbers).",
            "$ref": "#/components/schemas/Int256"
          }
        }
      },
      "TvmTuple": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "elements"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for TVM tuple structures.",
            "type": "string",
            "enum": [
              "tvm.tuple"
            ],
            "default": "tvm.tuple"
          },
          "elements": {
            "description": "Ordered tuple of TVM stack entries. Each element is a typed object with `@type` discriminator (`tvm.stackEntryNumber`, `tvm.stackEntryCell`, `tvm.stackEntrySlice`, `tvm.stackEntryTuple`, or `tvm.stackEntryList`).",
            "type": "array",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/TvmStackEntrySlice",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryCell",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryNumber",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryTuple",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryList",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryUnsupported",
                  "x-usrv-cpp-indirect": true
                }
              ],
              "discriminator": {
                "propertyName": "@type",
                "mapping": {
                  "tvm.stackEntrySlice": "#/components/schemas/TvmStackEntrySlice",
                  "tvm.stackEntryCell": "#/components/schemas/TvmStackEntryCell",
                  "tvm.stackEntryNumber": "#/components/schemas/TvmStackEntryNumber",
                  "tvm.stackEntryTuple": "#/components/schemas/TvmStackEntryTuple",
                  "tvm.stackEntryList": "#/components/schemas/TvmStackEntryList",
                  "tvm.stackEntryUnsupported": "#/components/schemas/TvmStackEntryUnsupported"
                }
              }
            }
          }
        }
      },
      "TvmList": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "elements"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for TVM list structures.",
            "type": "string",
            "enum": [
              "tvm.list"
            ],
            "default": "tvm.list"
          },
          "elements": {
            "description": "Ordered list of TVM stack entries. Each element is a typed object with `@type` discriminator (`tvm.stackEntryNumber`, `tvm.stackEntryCell`, `tvm.stackEntrySlice`, `tvm.stackEntryTuple`, or `tvm.stackEntryList`).",
            "type": "array",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/TvmStackEntrySlice",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryCell",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryNumber",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryTuple",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryList",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryUnsupported",
                  "x-usrv-cpp-indirect": true
                }
              ],
              "discriminator": {
                "propertyName": "@type",
                "mapping": {
                  "tvm.stackEntrySlice": "#/components/schemas/TvmStackEntrySlice",
                  "tvm.stackEntryCell": "#/components/schemas/TvmStackEntryCell",
                  "tvm.stackEntryNumber": "#/components/schemas/TvmStackEntryNumber",
                  "tvm.stackEntryTuple": "#/components/schemas/TvmStackEntryTuple",
                  "tvm.stackEntryList": "#/components/schemas/TvmStackEntryList",
                  "tvm.stackEntryUnsupported": "#/components/schemas/TvmStackEntryUnsupported"
                }
              }
            }
          }
        }
      },
      "RunGetMethodStdRequest": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "address",
          "method",
          "stack"
        ],
        "properties": {
          "address": {
            "$ref": "#/components/schemas/TonAddr"
          },
          "method": {
            "description": "The get method name (e.g., `seqno`, `get_wallet_data`) or its numeric ID.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ]
          },
          "stack": {
            "description": "Input arguments as a TVM stack. Each entry is a typed object with `@type` discriminator: `tvm.stackEntryNumber` (decimal string), `tvm.stackEntryCell` (base64 BoC), `tvm.stackEntrySlice` (base64 BoC), `tvm.stackEntryTuple`, or `tvm.stackEntryList`.",
            "type": "array",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/TvmStackEntrySlice",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryCell",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryNumber",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryTuple",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryList",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryUnsupported",
                  "x-usrv-cpp-indirect": true
                }
              ],
              "discriminator": {
                "propertyName": "@type",
                "mapping": {
                  "tvm.stackEntrySlice": "#/components/schemas/TvmStackEntrySlice",
                  "tvm.stackEntryCell": "#/components/schemas/TvmStackEntryCell",
                  "tvm.stackEntryNumber": "#/components/schemas/TvmStackEntryNumber",
                  "tvm.stackEntryTuple": "#/components/schemas/TvmStackEntryTuple",
                  "tvm.stackEntryList": "#/components/schemas/TvmStackEntryList",
                  "tvm.stackEntryUnsupported": "#/components/schemas/TvmStackEntryUnsupported"
                }
              }
            }
          },
          "seqno": {
            "description": "Masterchain block sequence number. Run the get method against the contract state at this specific block height. If omitted, uses the current state.",
            "type": "integer"
          }
        }
      },
      "RunGetMethodStdResult": {
        "description": "Result of executing a smart contract get method. Contains the TVM exit code (0 or 1 means success), gas consumed, and the output stack with typed return values.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "gas_used",
          "stack",
          "exit_code"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for standardized get method execution results.",
            "type": "string",
            "enum": [
              "smc.runResult"
            ],
            "default": "smc.runResult"
          },
          "gas_used": {
            "description": "Gas consumed during execution. Useful for cost estimation.",
            "type": "integer",
            "format": "int64"
          },
          "stack": {
            "description": "Output values as a TVM stack. Each entry is a typed object with `@type` discriminator: `tvm.stackEntryNumber` (decimal string), `tvm.stackEntryCell` (base64 BoC), `tvm.stackEntrySlice` (base64 BoC), `tvm.stackEntryTuple`, or `tvm.stackEntryList`.",
            "type": "array",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/TvmStackEntrySlice",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryCell",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryNumber",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryTuple",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryList",
                  "x-usrv-cpp-indirect": true
                },
                {
                  "$ref": "#/components/schemas/TvmStackEntryUnsupported",
                  "x-usrv-cpp-indirect": true
                }
              ],
              "discriminator": {
                "propertyName": "@type",
                "mapping": {
                  "tvm.stackEntrySlice": "#/components/schemas/TvmStackEntrySlice",
                  "tvm.stackEntryCell": "#/components/schemas/TvmStackEntryCell",
                  "tvm.stackEntryNumber": "#/components/schemas/TvmStackEntryNumber",
                  "tvm.stackEntryTuple": "#/components/schemas/TvmStackEntryTuple",
                  "tvm.stackEntryList": "#/components/schemas/TvmStackEntryList",
                  "tvm.stackEntryUnsupported": "#/components/schemas/TvmStackEntryUnsupported"
                }
              }
            }
          },
          "exit_code": {
            "description": "TVM exit code. `0` or `1` means success; other values indicate errors. Refer to the TVM exit code reference for all values.",
            "type": "integer",
            "format": "int32"
          }
        }
      },
      "LegacyTvmCell": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "data",
          "refs",
          "special"
        ],
        "properties": {
          "data": {
            "description": "Cell binary data.",
            "type": "object",
            "additionalProperties": false,
            "required": [
              "b64",
              "len"
            ],
            "properties": {
              "b64": {
                "description": "Cell data in base64.",
                "$ref": "#/components/schemas/Bytes"
              },
              "len": {
                "description": "Data length in bits.",
                "type": "integer",
                "format": "int32"
              }
            }
          },
          "refs": {
            "description": "Array of child cell references, forming a directed acyclic graph (DAG). Each child is a TVM cell object with its own data (base64), refs, and special flag.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/LegacyTvmCell"
            }
          },
          "special": {
            "description": "Returns `true` if this is a special (exotic) cell type such as a Merkle proof or library reference; otherwise `false`.",
            "type": "boolean"
          }
        }
      },
      "LegacyStackEntryCell": {
        "type": "object",
        "additionalProperties": false,
        "required": [
          "bytes"
        ],
        "properties": {
          "bytes": {
            "description": "Raw cell bytes in base64.",
            "$ref": "#/components/schemas/Bytes"
          },
          "object": {
            "description": "Parsed cell object with data, refs, and type info.",
            "$ref": "#/components/schemas/LegacyTvmCell"
          }
        }
      },
      "LegacyStackEntry": {
        "type": "array",
        "items": {
          "oneOf": [
            {
              "type": "string"
            },
            {
              "type": "integer",
              "format": "int64"
            },
            {
              "$ref": "#/components/schemas/LegacyStackEntryCell"
            },
            {
              "$ref": "#/components/schemas/TvmTuple",
              "x-usrv-cpp-indirect": true
            },
            {
              "$ref": "#/components/schemas/TvmList",
              "x-usrv-cpp-indirect": true
            }
          ]
        },
        "minItems": 2,
        "maxItems": 2
      },
      "RunGetMethodRequest": {
        "description": "Request to execute a smart contract get method. Specify address, method name/ID, and input stack.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "address",
          "method",
          "stack"
        ],
        "properties": {
          "address": {
            "$ref": "#/components/schemas/TonAddr"
          },
          "method": {
            "description": "The get method name (e.g., `seqno`, `get_wallet_data`) or its numeric ID.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "integer",
                "format": "int32"
              }
            ]
          },
          "stack": {
            "description": "Input arguments as a TVM stack. Each entry is a two-element array: `[type, value]` where type is `\"num\"` (decimal string), `\"cell\"` (base64 BoC), or `\"slice\"` (base64 BoC).",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/LegacyStackEntry"
            }
          },
          "seqno": {
            "description": "Masterchain block sequence number. Run the get method against the contract state at this specific block height. If omitted, uses the current state.",
            "type": "integer",
            "format": "int32"
          }
        }
      },
      "RunGetMethodResult": {
        "description": "Result of executing a smart contract get method. Contains the TVM exit code (0 or 1 means success), gas used, and the output stack with return values.",
        "type": "object",
        "additionalProperties": false,
        "required": [
          "@type",
          "gas_used",
          "stack",
          "exit_code",
          "block_id",
          "last_transaction_id"
        ],
        "properties": {
          "@type": {
            "description": "TonLib type identifier for get method execution results.",
            "type": "string",
            "enum": [
              "smc.runResult"
            ],
            "default": "smc.runResult"
          },
          "gas_used": {
            "description": "Gas consumed during execution. Useful for cost estimation.",
            "type": "integer",
            "format": "int64"
          },
          "stack": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/LegacyStackEntry"
            }
          },
          "exit_code": {
            "description": "TVM exit code. `0` or `1` means success; other values indicate errors. Refer to the TVM exit code reference for all values.",
            "type": "integer",
            "format": "int32"
          },
          "block_id": {
            "description": "Block at which the get method was executed.",
            "$ref": "#/components/schemas/TonBlockIdExt"
          },
          "last_transaction_id": {
            "description": "Most recent transaction at the time of execution.",
            "$ref": "#/components/schemas/InternalTransactionId"
          }
        }
      }
    }
  }
}