{"id":49013495,"url":"https://github.com/df-mc/go-xsapi","last_synced_at":"2026-04-19T00:35:57.126Z","repository":{"id":348330331,"uuid":"851043461","full_name":"df-mc/go-xsapi","owner":"df-mc","description":"Go library implementing part of the Xbox Services API (XSAPI).","archived":false,"fork":false,"pushed_at":"2026-04-15T09:26:38.000Z","size":101,"stargazers_count":2,"open_issues_count":2,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-04-15T11:28:48.704Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/df-mc.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,"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":"2024-09-02T10:16:06.000Z","updated_at":"2026-04-15T09:26:42.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/df-mc/go-xsapi","commit_stats":null,"previous_names":["df-mc/go-xsapi"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/df-mc/go-xsapi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/df-mc%2Fgo-xsapi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/df-mc%2Fgo-xsapi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/df-mc%2Fgo-xsapi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/df-mc%2Fgo-xsapi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/df-mc","download_url":"https://codeload.github.com/df-mc/go-xsapi/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/df-mc%2Fgo-xsapi/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31989996,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-18T20:23:30.271Z","status":"ssl_error","status_checked_at":"2026-04-18T20:23:29.375Z","response_time":103,"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":[],"created_at":"2026-04-19T00:35:56.266Z","updated_at":"2026-04-19T00:35:57.106Z","avatar_url":"https://github.com/df-mc.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# go-xsapi\n\n[![Go Reference](https://pkg.go.dev/badge/github.com/df-mc/go-xsapi.svg)](https://pkg.go.dev/github.com/df-mc/go-xsapi)\n\n\u003eA Go library for communicating with Xbox Live API.\n\n![Azure_Bit_Gopher.png](https://github.com/ashleymcnamara/gophers/blob/2951dcaac888f5489f762c959b1e1c31af48e92d/Azure_Bit_Gopher.png?raw=true)\n\n## Example\n\nThis code demonstrates Device Authorization Code Flow to retrieve access token, and interacts with some of the API endpoints available in Xbox Live.\n\n```go\n// Notify for Ctrl+C and other interrupt signals so the user can abort\n// the device authorization flow or other operations at any time.\nsignals, cancel := signal.NotifyContext(context.Background(), os.Interrupt)\ndefer cancel()\n\n// Use the Device Authorization Flow to sign in to a Microsoft Account.\nda, err := MinecraftAndroid.DeviceAuth(signals)\nif err != nil {\n\tpanic(fmt.Sprintf(\"error requesting device authorization flow: %s\", err))\n}\n\n// We print out the verification URI and the user code to [os.Stderr]\n// so it doesn't need to be captured by Output: line in this example.\n_, _ = fmt.Fprintf(os.Stderr,\n\t\"Sign in to your Microsoft Account at %s using the code %s.\",\n\tda.VerificationURI, da.UserCode,\n)\n\n// Make a context for polling the access token while the user completes sign-in.\n// In this case, we allow one minute to complete login (you may configure a longer timeout).\npollCtx, cancel := context.WithTimeout(signals, time.Minute)\ndefer cancel()\ntoken, err := MinecraftAndroid.DeviceAccessToken(pollCtx, da)\nif err != nil {\n\tpanic(fmt.Sprintf(\"error polling access token in device authorization flow: %s\", err))\n}\n// Use TokenSource so we can always use a valid token in fresh state.\nmsa := MinecraftAndroid.TokenSource(context.Background(), token)\n\n// Make a SISU session using the Microsoft Account token source.\nsession := MinecraftAndroid.New(msa, nil)\n\n// Log in to Xbox Live services using the SISU session.\nclient, err := NewClient(session)\nif err != nil {\n\tpanic(fmt.Sprintf(\"error creating API client: %s\", err))\n}\n// Make sure to close the client when it's done.\ndefer func() {\n\tif err := client.Close(); err != nil {\n\t\tpanic(fmt.Sprintf(\"error closing API client: %s\", err))\n\t}\n}()\n\n// Use social (peoplehub) endpoint to search a user using the query.\nctx, cancel := context.WithTimeout(signals, time.Second*15)\ndefer cancel()\nusers, err := client.Social().Search(ctx, \"Lactyy\")\nif err != nil {\n\tpanic(fmt.Sprintf(\"error searching for users: %s\", err))\n}\nif len(users) == 0 {\n\tpanic(\"no users found\")\n}\n\n// Use the first user present in the result.\nuser := users[0]\nfmt.Println(user.GamerTag)\n```\n\n## Contact\n\n[![Discord Banner 2](https://discordapp.com/api/guilds/623638955262345216/widget.png?style=banner2)](https://discord.gg/U4kFWHhTNR)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdf-mc%2Fgo-xsapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdf-mc%2Fgo-xsapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdf-mc%2Fgo-xsapi/lists"}