{"id":18733163,"url":"https://github.com/bioforestchain/bfmeta-transaction-maker","last_synced_at":"2025-11-14T00:30:16.738Z","repository":{"id":115189923,"uuid":"608027696","full_name":"BioforestChain/BFMeta-Transaction-Maker","owner":"BioforestChain","description":null,"archived":false,"fork":false,"pushed_at":"2024-06-06T07:46:52.000Z","size":384,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-12-28T15:46:01.846Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/BioforestChain.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-03-01T06:56:55.000Z","updated_at":"2024-06-06T07:46:55.000Z","dependencies_parsed_at":null,"dependency_job_id":"c567cbbd-535d-41c1-97e1-45248f014e4f","html_url":"https://github.com/BioforestChain/BFMeta-Transaction-Maker","commit_stats":null,"previous_names":[],"tags_count":67,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BioforestChain%2FBFMeta-Transaction-Maker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BioforestChain%2FBFMeta-Transaction-Maker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BioforestChain%2FBFMeta-Transaction-Maker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BioforestChain%2FBFMeta-Transaction-Maker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/BioforestChain","download_url":"https://codeload.github.com/BioforestChain/BFMeta-Transaction-Maker/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239605124,"owners_count":19666998,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-07T15:08:54.410Z","updated_at":"2025-11-14T00:30:16.693Z","avatar_url":"https://github.com/BioforestChain.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# BFMeta-Transaction-Maker\n\n## Installation - 安装\n\n`$ npm install @bfmeta/transaction-maker-api`\n\n### Requrements - 必要条件\n\n-   npm\n\n-   typescript\n\n\u003c!-- ## Docs \u0026 Community - 文档 \u0026 社区 --\u003e\n\n\u003c!-- 这里写我们的社区及文档的地址 --\u003e\n\n## Usage - 用法\n\n### Server\n\n```ts\n\n// 运行目录下建 config/config.json 填入以下内容\n{\n    \"//port\": \"事件服务器监听的端口号\",\n    port: 8888,\n    \"//loggerConfig\": \"日志配置\",\n    loggerConfig: {\n        \"//level\": \"日志等级，info warn debug error，默认 error\",\n        level: \"debug\",\n        \"//limit\": \"单文件日志大小 mb\",\n        limit: 100,\n        \"//backup\": \"日志保留份数\",\n        backup: 100,\n        \"//dateExpire\": \"根据时间切割\",\n        dateExpire: false,\n        \"//daysToRotate\": \"日志滚动时间 天\",\n        daysToRotate: 30\n    },\n    \"//chainNodeIps\": \"可用的链节点 ip\",\n    chainNodeIps: [\"127.0.0.1\"],\n    \"//broadcastTimeout\": \"广播超时时间，默认 30000\",\n    broadcastTimeout: 30000,\n    \"//genesisInfoConfig\": \"创世块信息\",\n    genesisInfoConfig: {\n        \"//genesisBlockPath\": \"创世块路径\",\n        genesisBlockPath: \"genesisInfos/bfmtest-genesisBlock-testnet.json\",\n        \"//genesisBlockLicensePath\": \"创世块授权文件路径\",\n        genesisBlockLicensePath: \"genesisInfos/bfmtest-license-testnet.json\"\n    },\n    \"//lang\": \"密钥类型 cn 汉语、jp 日语、sp 西班牙语、it 意大利语、fr 法语、en 英语\",\n    lang: \"en\"\n}\n// 运行 transaction-marker-server 服务\n\n```\n\n-   程序位于 https://github.com/BioforestChain/BFMeta-Transaction-Maker/releases/tag/v1.0.8\n-   step\n    1. 新建 config/config.json 于项目目录中\n    2. 将下载的程序解压至项目根目录\n    3. 执行程序 transaction-maker-server\n\n### Client\n\n```ts\nimport { BFMetaTrMaker } from \"@bfmeta/transaction-maker-api\";\nimport { PARENT_ASSET_TYPE } from \"@bfmeta/transaction-maker-core\";\n\nconst config: TransactionMaker.Api.ConfigOptions = {\n    \"//ips\": \"事件服务器的 ip，端口\",\n    ips: [\"127.0.0.1:8888\"],\n    \"//requestTimeout\": \"请求超时时间，默认 10000\",\n    requestTimeout: 10000,\n};\n\nconst bfmetaTrMaker = new BFMetaTrMaker(config);\n\n// 生成事件然后广播\nconst result = await bfmetaTrMaker.transaction.generateTransferAny(argv, ipInfo.ip);\n\nif (result.success) {\n    const resp = await bfmetaTrMaker.transaction.broadcastTransaction({\n        transaction: result.result,\n        ip: ipInfo.nodeIp,\n    });\n    if (resp.success) {\n        console.log(resp.result);\n    } else {\n        console.log(resp);\n    }\n} else {\n    console.log(result);\n}\n\n// 或者\n\n// 生成事件并且广播\n\nconst result = await bfmetaTrMaker.transaction.sendTransferAny(argv, ipInfo);\nconsole.log(result);\n```\n\n## Changelog - 更新日志\n\n-   1.0.8\n    -   更新文档，发布 1.0.8server 程序\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbioforestchain%2Fbfmeta-transaction-maker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbioforestchain%2Fbfmeta-transaction-maker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbioforestchain%2Fbfmeta-transaction-maker/lists"}