3行代码接入子舟链区块链存证 · Python & JavaScript
from zizhou_chain import ZizhouClient client = ZizhouClient(base_url="https://art.z-zbc.com") result = client.create_proof( file_path="artwork.jpg", title="洛神赋图", author="顾恺之" ) # result.proof_id → "c7967ea3" # result.tx_hash → "0x21b83c..." # result.certificate_id → "ZZ-C7967EA3"
import { ZizhouClient } from 'zizhou-chain'; const client = new ZizhouClient({ baseUrl: 'https://art.z-zbc.com' }); const result = await client.createProof({ file: fileBlob, title: '洛神赋图', author: '顾恺之' }); // result.proofId, result.txHash, result.certificateId
创建区块链存证,返回证书编号和交易哈希
验证存证真伪,确认链上状态
获取公开作品列表
获取链上统计数据
┌──────────────┐ ┌──────────────┐ ┌──────────────┐
│ Python SDK │ │ JS SDK │ │ REST API │
└──────┬───────┘ └──────┬───────┘ └──────┬───────┘
│ │ │
└────────────────────┼────────────────────┘
│
┌────────▼────────┐
│ Nginx (HTTPS) │
└────────┬────────┘
│
┌─────────────┼─────────────┐
│ │ │
┌─────▼─────┐ ┌────▼────┐ ┌─────▼─────┐
│ Flask API │ │ Flask │ │ Flask │
│ :8001 存证 │ │ :8002 │ │ :8003 积分│
└─────┬─────┘ └────┬────┘ └─────┬─────┘
│ │ │
└──────┬──────┘─────────────┘
│
┌──────▼──────┐
│ PostgreSQL │
└──────┬──────┘
│
┌──────▼──────┐
│ Besu QBFT │
│ 8 Nodes │
└─────────────┘