{"id":27362547,"url":"https://github.com/tailscale/tailscale-client-go-v2","last_synced_at":"2026-02-06T14:23:31.392Z","repository":{"id":276179231,"uuid":"928404525","full_name":"tailscale/tailscale-client-go-v2","owner":"tailscale","description":null,"archived":false,"fork":false,"pushed_at":"2025-08-26T15:28:32.000Z","size":198,"stargazers_count":21,"open_issues_count":9,"forks_count":6,"subscribers_count":16,"default_branch":"main","last_synced_at":"2025-08-26T21:27:12.683Z","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/tailscale.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}},"created_at":"2025-02-06T15:29:04.000Z","updated_at":"2025-08-26T15:28:36.000Z","dependencies_parsed_at":"2025-03-04T17:25:58.904Z","dependency_job_id":"62424a7e-644a-4100-ac5d-f1fa26233137","html_url":"https://github.com/tailscale/tailscale-client-go-v2","commit_stats":null,"previous_names":["tailscale/tailscale-client-go-v2"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/tailscale/tailscale-client-go-v2","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tailscale%2Ftailscale-client-go-v2","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tailscale%2Ftailscale-client-go-v2/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tailscale%2Ftailscale-client-go-v2/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tailscale%2Ftailscale-client-go-v2/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tailscale","download_url":"https://codeload.github.com/tailscale/tailscale-client-go-v2/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tailscale%2Ftailscale-client-go-v2/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":273182006,"owners_count":25059809,"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","status":"online","status_checked_at":"2025-09-01T02:00:09.058Z","response_time":120,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":"2025-04-13T03:21:27.429Z","updated_at":"2026-02-06T14:23:31.385Z","avatar_url":"https://github.com/tailscale.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tailscale.com/client/tailscale/v2\n\n[![Go Reference](https://pkg.go.dev/badge/tailscale.com/client/tailscale/v2.svg)](https://pkg.go.dev/tailscale.com/client/tailscale/v2)\n[![Github Actions](https://github.com/tailscale/tailscale-client-go-v2/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/tailscale/tailscale-client-go-v2/actions/workflows/ci.yml)\n\nThe official client implementation for the [Tailscale](https://tailscale.com) HTTP API.\nFor more details, please see [API documentation](https://tailscale.com/api).\n\n## Example (Using API Key)\n\n```go\npackage main\n\nimport (\n\t\"context\"\n\t\"os\"\n\n\t\"tailscale.com/client/tailscale/v2\"\n)\n\nfunc main() {\n\tclient := \u0026tailscale.Client{\n\t\tTailnet: os.Getenv(\"TAILSCALE_TAILNET\"),\n\t\tAPIKey:  os.Getenv(\"TAILSCALE_API_KEY\"),\n\t}\n\n\tdevices, err := client.Devices().List(context.Background())\n}\n```\n\n## Example (Using OAuth)\n\n```go\npackage main\n\nimport (\n\t\"context\"\n\t\"os\"\n\n\t\"tailscale.com/client/tailscale/v2\"\n)\n\nfunc main() {\n\tclient := \u0026tailscale.Client{\n\t\tTailnet: os.Getenv(\"TAILSCALE_TAILNET\"),\n\t\tAuth: \u0026tailscale.OAuth{\n\t\t\tClientID:     os.Getenv(\"TAILSCALE_OAUTH_CLIENT_ID\"),\n\t\t\tClientSecret: os.Getenv(\"TAILSCALE_OAUTH_CLIENT_SECRET\"),\n\t\t\tScopes:       []string{\"all:write\"},\n\t\t},\n\t}\n\t\n\tdevices, err := client.Devices().List(context.Background())\n}\n```\n\n## Example (Using Identity Federation)\n\n```go\npackage main\n\nimport (\n\t\"context\"\n\t\"os\"\n\n\t\"tailscale.com/client/tailscale/v2\"\n)\n\nfunc main() {\n\tclient := \u0026tailscale.Client{\n\t\tTailnet: os.Getenv(\"TAILSCALE_TAILNET\"),\n\t\tAuth: \u0026tailscale.IdentityFederation{\n\t\t\tClientID: os.Getenv(\"TAILSCALE_OAUTH_CLIENT_ID\"),\n\t\t\tIDTokenFunc: func() (string, error) {\n\t\t\t\treturn os.Getenv(\"IDENTITY_TOKEN\"), nil\n            },\n\t\t},\n\t}\n\n\tdevices, err := client.Devices().List(context.Background())\n}\n```\n\n## Example (Using Your Own Authentication Mechanism)\n\n```go\npackage main\n\nimport (\n\t\"context\"\n\t\"os\"\n\n\t\"tailscale.com/client/tailscale/v2\"\n)\n\ntype MyAuth struct {...}\n\nfunc (a *MyAuth) HTTPClient(orig *http.Client, baseURL string) *http.Client {\n\t// build an HTTP client that adds authentication to outgoing requests\n\t// see tailscale.OAuth for an example.\n}\n\nfunc main() {\n\tclient := \u0026tailscale.Client{\n\t\tTailnet: os.Getenv(\"TAILSCALE_TAILNET\"),\n\t\tAuth: \u0026MyAuth{...},\n\t}\n\t\n\tdevices, err := client.Devices().List(context.Background())\n}\n```\n\n## Releasing\n\nPushing a tag of the format `vX.Y.Z` will trigger the [release workflow](./.github/workflows/release.yml) which uses\n[goreleaser](https://github.com/goreleaser/goreleaser) to build and sign artifacts and generate a\n[GitHub release](https://github.com/tailscale/tailscale-client-go-v2/releases).\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftailscale%2Ftailscale-client-go-v2","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftailscale%2Ftailscale-client-go-v2","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftailscale%2Ftailscale-client-go-v2/lists"}