{"id":20063892,"url":"https://github.com/writeas/go-nodeinfo","last_synced_at":"2026-02-27T16:35:10.170Z","repository":{"id":57490395,"uuid":"142029483","full_name":"writeas/go-nodeinfo","owner":"writeas","description":"NodeInfo server implemented in Go","archived":false,"fork":false,"pushed_at":"2019-01-14T16:55:26.000Z","size":7,"stargazers_count":10,"open_issues_count":0,"forks_count":1,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-04-27T17:02:07.040Z","etag":null,"topics":["federation","fediverse","go","nodeinfo"],"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/writeas.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-07-23T14:57:12.000Z","updated_at":"2023-11-07T17:15:04.000Z","dependencies_parsed_at":"2022-09-02T12:44:27.781Z","dependency_job_id":null,"html_url":"https://github.com/writeas/go-nodeinfo","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/writeas%2Fgo-nodeinfo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/writeas%2Fgo-nodeinfo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/writeas%2Fgo-nodeinfo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/writeas%2Fgo-nodeinfo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/writeas","download_url":"https://codeload.github.com/writeas/go-nodeinfo/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252542525,"owners_count":21764984,"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":["federation","fediverse","go","nodeinfo"],"created_at":"2024-11-13T13:44:07.890Z","updated_at":"2026-02-27T16:35:05.117Z","avatar_url":"https://github.com/writeas.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# go-nodeinfo\n\n[![GoDoc](https://godoc.org/github.com/writeas/go-nodeinfo?status.svg)](https://godoc.org/github.com/writeas/go-nodeinfo)\n[![Discuss on our forum](https://img.shields.io/discourse/https/discuss.write.as/users.svg?label=forum)](https://discuss.write.as/c/development)\n\ngo-nodeinfo is an implementation of [NodeInfo](https://github.com/jhass/nodeinfo), a standard metadata format for federated social networks, in Go (golang).\n\n## Usage\n\n`nodeinfo.Service` integrates with your existing `net/http` server.\n\n```go\npackage main\n\nimport (\n\t\"github.com/writeas/go-nodeinfo\"\n\t\"net/http\"\n)\n\nfunc main() {\n\tcfg := nodeinfo.Config{\n\t\tBaseURL: \"http://localhost:8080\",\n\t\tInfoURL: \"/api/nodeinfo\",\n\n\t\tMetadata: nodeinfo.Metadata{\n\t\t\tNodeName:        \"Agora\",\n\t\t\tNodeDescription: \"A federated something-something.\",\n\t\t\tPrivate:         false,\n\t\t},\n\t\tProtocols: []nodeinfo.NodeProtocol{\n\t\t\tnodeinfo.ProtocolActivityPub,\n\t\t},\n\t\tServices: nodeinfo.Services{\n\t\t\tInbound: []nodeinfo.NodeService{},\n\t\t\tOutbound: []nodeinfo.NodeService{\n\t\t\t\tnodeinfo.ServiceTwitter,\n\t\t\t\tnodeinfo.ServiceTumblr,\n\t\t\t},\n\t\t},\n\t\tSoftware: nodeinfo.SoftwareInfo{\n\t\t\tName:    \"Agora\",\n\t\t\tVersion: \"1.0\",\n\t\t},\n\t}\n\tni := nodeinfo.NewService(cfg, nodeInfoResolver{})\n\n\thttp.Handle(nodeinfo.NodeInfoPath, http.HandlerFunc(ni.NodeInfoDiscover))\n\thttp.Handle(cfg.InfoURL, http.HandlerFunc(ni.NodeInfo))\n\n\thttp.ListenAndServe(\":8080\", nil)\n}\n\ntype nodeInfoResolver struct{}\n\nfunc (r nodeInfoResolver) IsOpenRegistration() (bool, error) {\n\treturn true, nil\n}\n\nfunc (r nodeInfoResolver) Usage() (nodeinfo.Usage, error) {\n\tu := nodeinfo.Usage{\n\t\tUsers: nodeinfo.UsageUsers{\n\t\t\tTotal: 1,\n\t\t},\n\t\tLocalPosts: 1,\n\t}\n\treturn u, nil\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwriteas%2Fgo-nodeinfo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwriteas%2Fgo-nodeinfo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwriteas%2Fgo-nodeinfo/lists"}