{"id":18309050,"url":"https://github.com/tekintian/bencode","last_synced_at":"2025-04-09T11:30:26.151Z","repository":{"id":40428588,"uuid":"507522443","full_name":"tekintian/bencode","owner":"tekintian","description":"A tiny torrent magnet file  Bencode encoding/decoding  package. ","archived":false,"fork":false,"pushed_at":"2022-06-28T01:28:57.000Z","size":14,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-15T05:28:33.533Z","etag":null,"topics":["bencode","bencode-parser","go","golang","golang-library","magnet","torrent"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tekintian.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}},"created_at":"2022-06-26T08:49:51.000Z","updated_at":"2024-02-20T21:46:13.000Z","dependencies_parsed_at":"2022-07-20T00:48:36.548Z","dependency_job_id":null,"html_url":"https://github.com/tekintian/bencode","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tekintian%2Fbencode","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tekintian%2Fbencode/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tekintian%2Fbencode/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tekintian%2Fbencode/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tekintian","download_url":"https://codeload.github.com/tekintian/bencode/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248030946,"owners_count":21036299,"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":["bencode","bencode-parser","go","golang","golang-library","magnet","torrent"],"created_at":"2024-11-05T16:10:03.320Z","updated_at":"2025-04-09T11:30:26.122Z","avatar_url":"https://github.com/tekintian.png","language":"Go","readme":"# tiny Bencode encoding/decoding  package.\nUses similar API design to Go's json package.\ntiny from https://github.com/anacrolix/torrent\n\n\n## Install\n\n```sh\ngo get github.com/tekintian/bencode\n```\n\n## Usage\n\n```go\npackage demo\n\nimport (\n\tbencode \"github.com/tekintian/bencode\"\n)\n\ntype Message struct {\n\tQuery    string `json:\"q,omitempty\" bencode:\"q,omitempty\"`\n}\n\nvar v Message\n\nfunc main(){\n\t// encode\n\tdata, err := bencode.Marshal(v)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\t//decode\n\terr := bencode.Unmarshal(data, \u0026v)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\tfmt.Println(v)\n}\n```\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftekintian%2Fbencode","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftekintian%2Fbencode","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftekintian%2Fbencode/lists"}