{"id":22243435,"url":"https://github.com/ton-community/tlb-parser","last_synced_at":"2026-01-12T08:39:20.322Z","repository":{"id":65338096,"uuid":"562531429","full_name":"ton-community/tlb-parser","owner":"ton-community","description":"Parse TL-B definitions into TypeScript objects","archived":false,"fork":false,"pushed_at":"2025-12-05T14:40:40.000Z","size":579,"stargazers_count":26,"open_issues_count":1,"forks_count":9,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-12-07T11:59:43.597Z","etag":null,"topics":["tlb","ton","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ton-community.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"contributing.md","funding":null,"license":"LICENSE","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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2022-11-06T16:38:31.000Z","updated_at":"2025-12-02T06:54:30.000Z","dependencies_parsed_at":"2023-12-06T10:56:40.901Z","dependency_job_id":"a6e133e1-0b0a-40b9-a67f-a6c1645eabc4","html_url":"https://github.com/ton-community/tlb-parser","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/ton-community/tlb-parser","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ton-community%2Ftlb-parser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ton-community%2Ftlb-parser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ton-community%2Ftlb-parser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ton-community%2Ftlb-parser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ton-community","download_url":"https://codeload.github.com/ton-community/tlb-parser/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ton-community%2Ftlb-parser/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28337599,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-12T06:09:07.588Z","status":"ssl_error","status_checked_at":"2026-01-12T06:05:18.301Z","response_time":98,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["tlb","ton","typescript"],"created_at":"2024-12-03T04:26:51.191Z","updated_at":"2026-01-12T08:39:20.314Z","avatar_url":"https://github.com/ton-community.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tlb-parser\n\n[![npm @ton-community/tlb-parser version](https://img.shields.io/npm/v/@ton-community/tlb-parser)](https://www.npmjs.com/package/@ton-community/tlb-parser)\n[![qa](https://github.com/ton-community/tlb-parser/actions/workflows/qa.yml/badge.svg)](https://github.com/ton-community/tlb-parser/actions/workflows/qa.yml)\n\n## Installation\n\n```bash\nnpm install @ton-community/tlb-parser\n```\n\n## Usage\n\nCreate a file with TLB scheme according to the [documentation](https://docs.ton.org/develop/data-formats/tl-b-language). This is an example of such a file (call it `example.tlb`):\n```\nt$_ x:# y:(uint 5) = A;\n```\n\nThen do:\n```bash\nnpx tlb-parser example.tlb\n```\n\nOr you can use the tool from inside JS or TS code.\n\n```typescript\nimport { ast, NodeVisitor, ASTRootBase } from \"@ton-community/tlb-parser\";\n\nclass TestVisitor extends NodeVisitor {\n  public visited: { [key: string]: number };\n\n  constructor() {\n    super();\n    this.visited = {};\n  }\n\n  override genericVisit(node: nodes.ASTRootBase): void {\n    if (this.visited[node.constructor.name] === undefined) {\n      this.visited[node.constructor.name] = 0;\n    }\n\n    this.visited[node.constructor.name] += 1;\n    return super.genericVisit(node);\n  }\n}\n\nconst scheme = `\nt$_ x:# y:(uint 5) = A;\n`;\n\nconst tree = ast(scheme);\nconst visitor = new TestVisitor();\nvisitor.visit(tree);\n\nconsole.log(\n  util.inspect(\n    visitor.visited,\n    {showHidden: false, depth: null, colors: true},\n  ),\n);\n\nconsole.log(\n  util.inspect(\n    tree,\n    {showHidden: false, depth: null, colors: true},\n  ),\n);\n```\n\n## Related\n\n- IntelliJ plugin: https://github.com/ton-blockchain/intellij-ton\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fton-community%2Ftlb-parser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fton-community%2Ftlb-parser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fton-community%2Ftlb-parser/lists"}