帮助文档
文档中心
开发者文档
  • AVATA API 文档
  • 底层链 SDK 文档
开发者社区
区块链浏览器
  • 文昌链网浏览器
  • 文昌链极速网
  • 文昌链-天舟
关于文昌链
文档中心
开发者文档
  • AVATA API 文档
  • 底层链 SDK 文档
开发者社区
区块链浏览器
  • 文昌链网浏览器
  • 文昌链极速网
  • 文昌链-天舟
关于文昌链
AVATA API 文档
  • AVATA API 文档
接入说明AVATA v3 API 文档AVATA v1 API 文档AVATA v2 API 文档
接入说明AVATA v3 API 文档AVATA v1 API 文档AVATA v2 API 文档
  1. 查询交易结果接口
  • API 版本简介
  • 链账户接口
    • 创建链账户
      POST
    • 批量创建链账户
      POST
    • 查询链账户
      GET
    • 查询链账户操作记录
      GET
  • NFT 接口
    • 创建 NFT 类别
      POST
    • 查询 NFT 类别详情
      GET
    • 查询 NFT 类别
      GET
    • 转让 NFT 类别
      POST
    • 发行 NFT
      POST
    • 转让 NFT
      POST
    • 编辑 NFT
      PATCH
    • 销毁 NFT
      DELETE
    • 批量发行 NFT
      POST
    • 批量转让 NFT
      POST
    • 批量编辑 NFT
      PATCH
    • 批量销毁 NFT
      DELETE
    • 查询 NFT
      GET
    • 查询 NFT 详情
      GET
    • 查询 NFT 操作记录
      GET
  • MT 接口
    • 创建 MT 类别
      POST
    • 查询 MT 类别
      GET
    • 查询 MT 类别详情
      GET
    • 转让 MT 类别
      POST
    • 增发 MT
      POST
    • 发行 MT
      POST
    • 转让 MT
      POST
    • 编辑 MT
      PATCH
    • 销毁 MT
      DELETE
    • 查询 MT
      GET
    • 查询 MT 操作记录
      GET
    • 查询 MT 余额
      GET
    • 查询 MT 详情
      GET
  • 区块链存证接口
    • 数字作品存证接口
  • 购买能量值接口
    • 购买能量值
    • 批量购买能量值
    • 查询能量值购买结果
    • 查询能量值购买结果列表
  • 查询交易结果接口
    • 查询上链交易排队状态
      GET
    • 查询上链交易结果
      GET
  1. 查询交易结果接口

查询上链交易结果

生产环境
https://apis.avata.bianjie.ai
生产环境
https://apis.avata.bianjie.ai
GET
https://apis.avata.bianjie.ai
/v1beta1/tx/{operation_id}
根据在接口请求时自定义的 Operation ID ,查询相关的链上操作结果。每笔交易会产生唯一的 Operation ID,根据 Operation ID,可以查询具体的交易结果,包含交易状态、交易信息及交易详情。 Operation ID 的值为原 Task ID 对应的值,建议程序中尽早将 Task ID 替换为 Operation ID。
当前支持查询当月及上个月的交易结果,其它月历史数据已归档,暂不支持查询对应结果。
注意:
若查询出的链上操作结果 status 为 2(失败),请在业务侧做容错处理。可以参考接口返回的 message(交易失败的错误描述信息) 对 NFT / MT / 业务接口的请求参数做适当调整后,使用「新的 Operation ID 」 重新发起 NFT / MT / 业务接口请求。

请求参数

Path 参数

Header 参数

请求示例代码

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request GET 'https://apis.avata.bianjie.ai/v1beta1/tx/' \
--header 'X-Api-Key;' \
--header 'X-Api-Key;' \
--header 'X-Timestamp;' \
--header 'X-Timestamp;' \
--header 'X-Signature;' \
--header 'X-Signature;'

返回响应

🟢200successful operation
application/json
Body

示例
{
    "data": {
        "type": "issue_class",
        "module": "nft",
        "tx_hash": "string",
        "status": 0,
        "message": "string",
        "block_height": 0,
        "timestamp": "string",
        "nft": {
            "issue_class": {
                "class_id": "string",
                "nft_id": "string"
            },
            "transfer_class": {
                "class_id": "string",
                "nft_id": "string"
            },
            "mint": {
                "class_id": "string",
                "nft_id": "string"
            },
            "edit": {
                "class_id": "string",
                "nft_id": "string"
            },
            "transfer": {
                "class_id": "string",
                "nft_id": "string"
            },
            "burn": {
                "class_id": "string",
                "nft_id": "string"
            },
            "mint_nft_batch": {
                "class_id": "string",
                "nft_id": "string"
            },
            "edit_nft_batch": {
                "class_id": "string",
                "nft_id": "string"
            },
            "transfer_nft_batch": {
                "class_id": "string",
                "nft_id": "string"
            },
            "burn_nft_batch": {
                "class_id": "string",
                "nft_id": "string"
            }
        },
        "mt": {
            "issue_class": {
                "class_id": "string",
                "mt_id": "string"
            },
            "transfer_class": {
                "class_id": "string",
                "mt_id": "string"
            },
            "issue": {
                "class_id": "string",
                "mt_id": "string"
            },
            "mint": {
                "class_id": "string",
                "mt_id": "string"
            },
            "edit": {
                "class_id": "string",
                "mt_id": "string"
            },
            "transfer": {
                "class_id": "string",
                "mt_id": "string"
            },
            "burn": {
                "class_id": "string",
                "mt_id": "string"
            }
        },
        "record": {
            "create_record": {
                "record_id": "string",
                "certificate_url": "string"
            }
        }
    }
}

扫码加入文昌链微信技术交流群

在这里,获得 Avata 使用上的任何帮助,快速上手让你的研测效率大幅提升

扫码添加小助手
修改于 2023-07-14 15:01:31
上一页
查询上链交易排队状态
Built with