{"id":34197468,"url":"https://github.com/codeindex2937/oojson","last_synced_at":"2026-03-11T11:36:27.359Z","repository":{"id":199236108,"uuid":"702418438","full_name":"codeindex2937/oojson","owner":"codeindex2937","description":"Generate code from JSON","archived":false,"fork":false,"pushed_at":"2025-10-04T06:07:31.000Z","size":17,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-04T08:22:42.230Z","etag":null,"topics":["codegen","json"],"latest_commit_sha":null,"homepage":"","language":"Go","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/codeindex2937.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-10-09T09:26:56.000Z","updated_at":"2025-10-04T06:07:35.000Z","dependencies_parsed_at":null,"dependency_job_id":"d2d08cbc-16fe-4f54-8637-005d488a094c","html_url":"https://github.com/codeindex2937/oojson","commit_stats":null,"previous_names":["codeindex2937/oojson"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/codeindex2937/oojson","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codeindex2937%2Foojson","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codeindex2937%2Foojson/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codeindex2937%2Foojson/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codeindex2937%2Foojson/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/codeindex2937","download_url":"https://codeload.github.com/codeindex2937/oojson/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codeindex2937%2Foojson/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30379962,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-11T06:09:32.197Z","status":"ssl_error","status_checked_at":"2026-03-11T06:09:17.086Z","response_time":84,"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":["codegen","json"],"created_at":"2025-12-15T17:39:22.683Z","updated_at":"2026-03-11T11:36:27.354Z","avatar_url":"https://github.com/codeindex2937.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# oojson\n\nGenerate data object code from JSON\n\n## Example\n\n```go\nd := json.NewDecoder(bytes.NewBufferString(`{\n  \"name\": \"Tom\",\n  \"age\": 50,\n  \"height\": 175.0,\n  \"trace\": [[0.0, 0.0], [0.1, 0.2]],\n  \"properties\": [{\"type\": \"pet\", \"value\": \"cat\"}]\n}`))\nd.UseNumber()\n\nvar obj interface{}\nif err := d.Decode(\u0026obj); err != nil {\n\tlog.Fatal(err)\n}\n\nvalue := \u0026oojson.Value{}\nvalue.Observe(obj)\n\nrawCode, _ := oojson.GetGoType(value, 0, oojson.DefaultGoOption())\ngoCode, err := format.Source([]byte(rawCode))\nif err != nil {\n\tlog.Fatal(err)\n}\nfmt.Printf(\"go:\\n%v\\n\", string(goCode))\n\n_, javaCode := oojson.GetJavaType(value, \"Test\", \"  \", oojson.DefaultJavaOption())\nfmt.Printf(\"java:\\n%v\\n\", string(javaCode))\n```\n\n## Reference\n\n[go-jsonstruct](https://github.com/twpayne/go-jsonstruct)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodeindex2937%2Foojson","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcodeindex2937%2Foojson","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodeindex2937%2Foojson/lists"}