用途:该技能围绕 TON 区块链的静态类型智能合约语言 Tact(v1.6.13)整理参考,面向智能体使用,帮助理解合约结构与消息通信机制。
主要能力与主题:类型系统(基础类型、可选值、map、struct、message、contract、trait);合约与 trait(init、参数、receiver、getter、接口、BaseTrait);结构与消息(定义、实例化、toCell/fromCell、TL-B 布局);接收消息(receive()、文本/二进制/slice 接收器、顺序、外部与退回);发送消息(send()、SendParameters、reply、forward、notify、cashback、deploy、emit);Cell/Builder/Slice(beginCell、store/load、Struct 与 Message 辅助);消息模式与可选标志(SendRemainingValue、SendIgnoreErrors 等);Gas 与费用(getStorageFee、getComputeFee、getForwardFee、setGasLimit、acceptMessage);上下文与状态(sender、context、myAddress、myBalance、now、inMsg、setData、commit、getConfigParam、nativeReserve);地址、加密(checkSignature、sha256、keccak256、SignedBundle)、字符串、数学、退出码、随机数、调试(require、dump、throw、throwIf、throwUnless)、编译期函数及消息生命周期。进阶覆盖可选值、map、initOf 与部署、@stdlib 标准库(config、content、deploy、dns、ownable、stoppable)、tact.config.json 配置、外部消息、常量,以及安全、Gas 优化与退回消息等最佳实践。
使用方式:资料按主题列出参考文档;具体安装命令、调用示例与代码实现暂未提供。
限制:内容基于 Tact v1.6.13(生成于 2026-02-25),未提及收费、价格或平台要求;其他事实以官方文档为准。