{"id":43486852,"url":"https://github.com/swrm-io/go-hevy","last_synced_at":"2026-02-03T09:12:58.203Z","repository":{"id":252735664,"uuid":"840938126","full_name":"swrm-io/go-hevy","owner":"swrm-io","description":"Golang API Client for Hevy","archived":false,"fork":false,"pushed_at":"2025-12-15T23:56:45.000Z","size":61,"stargazers_count":0,"open_issues_count":3,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-12-19T08:35:20.120Z","etag":null,"topics":["api","api-client-go","golang","golang-library","health","hevy","metrics","workout"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/swrm-io.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-08-11T06:35:48.000Z","updated_at":"2025-12-15T23:56:28.000Z","dependencies_parsed_at":"2024-11-04T08:25:30.056Z","dependency_job_id":"1da84eb4-2c55-4297-aeae-9af9e0f8d793","html_url":"https://github.com/swrm-io/go-hevy","commit_stats":null,"previous_names":["swrm-io/go-hevy"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/swrm-io/go-hevy","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swrm-io%2Fgo-hevy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swrm-io%2Fgo-hevy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swrm-io%2Fgo-hevy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swrm-io%2Fgo-hevy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/swrm-io","download_url":"https://codeload.github.com/swrm-io/go-hevy/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swrm-io%2Fgo-hevy/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29039347,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-03T08:41:49.363Z","status":"ssl_error","status_checked_at":"2026-02-03T08:40:19.255Z","response_time":96,"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":["api","api-client-go","golang","golang-library","health","hevy","metrics","workout"],"created_at":"2026-02-03T09:12:57.282Z","updated_at":"2026-02-03T09:12:58.196Z","avatar_url":"https://github.com/swrm-io.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n\u003ca href=\"https://github.com/swrm-io/go-heyv/actions/workflows/github-code-scanning/codeql\"\u003e\n    \u003cimg alt=\"CodeQL Status\" src=\"https://github.com/swrm-io/go-hevy/actions/workflows/github-code-scanning/codeql/badge.svg\"\u003e\n\u003c/a\u003e\n\u003ca href=\"https://pkg.go.dev/github.com/swrm-io/go-hevy\"\u003e\n    \u003cimg alt=\"GoDoc\" src=\"https://pkg.go.dev/badge/github.com/swrm-io/go-hevy.svg\"\u003e\n\u003c/a\u003e\n\n# go-hevy\n\n\u003e [!IMPORTANT]  \n\u003e This is still a work in progress and may have bugs and is not feature complete.\n\nGolang Client for working with the [Hevy](https://www.hevyapp.com/) API.\n\n\u003e [!NOTE]\n\u003e The API is only avaliable to `Hevy Pro` users.\n\nTo generate your API key visit the [Developer Portal](https://hevy.com/settings?developer).\n\n## Usage\n\n### Creating a Client\n\n```go\nimport \"github.com/swrm-io/go-hevy\"\n\nclient := hevy.NewClient(\"your-api-key\")\n```\n\n### Fetching Workouts\n\n```go\n// Get all workouts (handles pagination automatically)\nworkouts, err := client.AllWorkouts()\nif err != nil {\n    // handle error\n}\n\n// Iterate over workouts one by one (memory efficient for large datasets)\nfor workout := range client.Workouts() {\n    // process workout\n}\n\n// Get a paginated list of workouts\nworkouts, nextPage, err := client.GetWorkouts(1, 10)\nif err != nil {\n    // handle error\n}\ncurrentPage = nextPage\nworkouts, nextPage, err := client.Getworkouts(currentPage, 10)\n\n// Get a specific workout by ID\nworkoutID := uuid.MustParse(\"workout-uuid\")\nworkout, err := client.Workout(workoutID)\nif err != nil {\n    // handle error\n}\n\n// Get workout count\ncount, err := client.WorkoutCount()\nif err != nil {\n    // handle error\n}\n\n// Get all workout events since a specific time (for syncing)\nsince := time.Now().AddDate(0, -1, 0) // Last month\nevents, err := client.AllWorkoutEvents(since)\nif err != nil {\n    // handle error\n}\n\n// Iterate over workout events (memory efficient)\nsince := time.Now().AddDate(0, -1, 0) // Last month\nfor event := range client.WorkoutEvents(since) {\n    // process event\n}\n\n// Get a paginated list of workout events\nsince := time.Now().AddDate(0, -1, 0) // Last month\nevents, nextPage, err := client.GetWorkoutEvents(1, 10, since)\nif err != nil {\n    // handle error\n}\ncurrentPage = nextPage\nevents, nextPage, err := client.GetWorkoutEvents(currentPage, 10, since)\n```\n\n### Fetching Routines\n\n```go\n// Get all routines\nroutines, err := client.Routines()\nif err != nil {\n    // handle error\n}\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fswrm-io%2Fgo-hevy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fswrm-io%2Fgo-hevy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fswrm-io%2Fgo-hevy/lists"}