{"id":43880929,"url":"https://github.com/deloz/sid","last_synced_at":"2026-02-06T15:20:28.427Z","repository":{"id":231702036,"uuid":"782507885","full_name":"deloz/sid","owner":"deloz","description":"The main purpose of SID is to seamlessly convert between a JSON-formatted string representation of an ID and its uint64 counterpart when interacting with a database.","archived":false,"fork":false,"pushed_at":"2025-07-07T07:12:16.000Z","size":51,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-07-07T08:27:26.712Z","etag":null,"topics":["large-number","uint64"],"latest_commit_sha":null,"homepage":"","language":"Go","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/deloz.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"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}},"created_at":"2024-04-05T12:37:38.000Z","updated_at":"2025-07-07T07:12:09.000Z","dependencies_parsed_at":"2024-09-05T18:29:48.278Z","dependency_job_id":"1ed137b6-172d-4e86-9721-24233b2b8cb5","html_url":"https://github.com/deloz/sid","commit_stats":null,"previous_names":["deloz/sid"],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/deloz/sid","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deloz%2Fsid","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deloz%2Fsid/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deloz%2Fsid/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deloz%2Fsid/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/deloz","download_url":"https://codeload.github.com/deloz/sid/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/deloz%2Fsid/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29166419,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-06T14:37:12.680Z","status":"ssl_error","status_checked_at":"2026-02-06T14:36:22.973Z","response_time":59,"last_error":"SSL_read: 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":["large-number","uint64"],"created_at":"2026-02-06T15:20:27.520Z","updated_at":"2026-02-06T15:20:28.418Z","avatar_url":"https://github.com/deloz.png","language":"Go","readme":"# SID\n\nThe main purpose of SID is to seamlessly convert between a JSON-formatted string representation of an ID and its int64 counterpart when interacting with a database.\n\n## Installation\n\nYou can install SID using `go get`:\n\n```bash\ngo get -u -v github.com/deloz/sid\n```\n\n## Usage\n\nHere's a basic example of how to use SID:\n\n```go\npackage main\n\nimport (\n\t\"encoding/json\"\n\t\"fmt\"\n\n\t\"github.com/deloz/sid\"\n)\n\nfunc main() {\n\t// Create a new ID\n\tid := sid.New(18283195028008204)\n\n\t// Print the ID as a string\n\tfmt.Println(\"ID:\", id.String())\n\n\t// Check if the ID is zero\n\tfmt.Println(\"IsZero:\", id.IsZero())\n\n\t// Marshal the ID to JSON\n\tjsonData, _ := json.Marshal(id)\n\tfmt.Println(\"JSON:\", string(jsonData))\n\n\t// Unmarshal the ID from JSON\n\tvar newID sid.ID\n\t_ = json.Unmarshal(jsonData, \u0026newID)\n\tfmt.Println(\"Unmarshaled ID:\", newID)\n}\n```\n\n[[play](https://go.dev/play/p/Fie93MkAzmq)]\n\n## Features\n\n- Support creation of IDs from `uint64` (up to `math.MaxInt64`), `int64`, and numeric string representations.\n- Implement JSON (de)serialization, comparison, and sorting for custom ID types in Go.\n\n## Contributing\n\nContributions are welcome! If you find a bug or want to propose a new feature, feel free to open an issue or submit a pull request.\n\n## License\n\nSID is licensed under the MIT License. See [LICENSE](LICENSE) for details.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeloz%2Fsid","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdeloz%2Fsid","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeloz%2Fsid/lists"}