{"id":29935039,"url":"https://github.com/enrichman/gaen","last_synced_at":"2025-08-02T20:09:06.203Z","repository":{"id":144223697,"uuid":"300565473","full_name":"enrichman/gaen","owner":"enrichman","description":"A cli to interact with the GAEN (Google Apple Exposure Notification) system","archived":false,"fork":false,"pushed_at":"2020-10-09T19:34:24.000Z","size":48,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2023-10-20T19:41:36.958Z","etag":null,"topics":["apple","covid-19","exposure-notification","gaen","google"],"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/enrichman.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2020-10-02T09:29:41.000Z","updated_at":"2023-10-20T19:41:37.650Z","dependencies_parsed_at":null,"dependency_job_id":"a96fd81a-130a-46b0-88b8-2ee26a368c40","html_url":"https://github.com/enrichman/gaen","commit_stats":null,"previous_names":[],"tags_count":3,"template":null,"template_full_name":null,"purl":"pkg:github/enrichman/gaen","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/enrichman%2Fgaen","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/enrichman%2Fgaen/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/enrichman%2Fgaen/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/enrichman%2Fgaen/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/enrichman","download_url":"https://codeload.github.com/enrichman/gaen/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/enrichman%2Fgaen/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":268448222,"owners_count":24251999,"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-08-02T02:00:12.353Z","response_time":74,"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":["apple","covid-19","exposure-notification","gaen","google"],"created_at":"2025-08-02T20:09:05.610Z","updated_at":"2025-08-02T20:09:06.187Z","avatar_url":"https://github.com/enrichman.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# gaen\n\n`gaen` is a simple cli to interact with the Google-Apple Exposure Notification system.\n\nIf you want to know more about the system please refer to the official Google and Apple documentations:\n- https://www.google.com/covid19/exposurenotifications/\n- https://covid19.apple.com/contacttracing\n\n\n## Install\n\nTo install from source clone the project and run\n\n```bash\ngo install ./...\n```\n\n## Usage\n\nTo download a TEK export run `gaen download` with a supported app (`immuni` or `swisscovid`, at the moment):\n\n```\ngaen download immuni\n```\n\nThis will download the export in a `out/immuni/xxx` folder.\n\nThen you can decode the export running\n\n```\ngaen decode out/immuni/xxx/export.bin\n```\n\nand this will output the decoded JSON\n\n```json\n{\n    \"ID\": \"+wK7aDl5cTC2wbZ4Ux6bvw==\",\n    \"Date\": \"2020-10-02\",\n    \"RPIs\": [\n        [\n            {\n                \"ID\": \"GkUh9M/fYslxaxucp0ayWg==\",\n                \"Interval\": \"2020-09-29T02:00:00+02:00\"\n            }\n        ],\n        ...\n        [\n            {\n                \"ID\": \"N99nmdxpfAvk0ByUGWI6EQ==\",\n                \"Interval\": \"2020-09-29T02:40:00+02:00\"\n            }\n        ]\n    ],\n    ...\n}\n```\n\n### query\n\n`gaen` implements a `--query` flag that follows the [JMESPath specification](https://jmespath.org/) that you can use to filter the output.\n\nFor example if you want to get the first TEK with its first RPI you can run:\n\n```bash\ngaen decode out/immuni/167/export.bin --query '[0].{ ID:ID, Date:Date, RPIS:RPIs[0] }'\n```\n```json\n{\n    \"Date\": \"2020-09-29\",\n    \"ID\": \"+wK7aDl5cTC2wbZ4Ux6bvw==\",\n    \"RPIS\": {\n        \"ID\": \"GkUh9M/fYslxaxucp0ayWg==\",\n        \"Interval\": \"2020-09-29T02:00:00+02:00\"\n    }\n}\n```\n\nor get the first 5 RPIs like this:\n\n```\ngaen decode out/immuni/167/export.bin --query '[0].{ ID:ID, Date:Date, RPIs:RPIs[:5].[{ ID:ID, Interval:Interval }] }'\n```\n\n```json\n{\n    \"Date\": \"2020-09-29\",\n    \"ID\": \"+wK7aDl5cTC2wbZ4Ux6bvw==\",\n    \"RPIs\": [\n        [\n            {\n                \"ID\": \"GkUh9M/fYslxaxucp0ayWg==\",\n                \"Interval\": \"2020-09-29T02:00:00+02:00\"\n            }\n        ],\n        [\n            {\n                \"ID\": \"72eL1vRaRXuRfTFTnR6gDA==\",\n                \"Interval\": \"2020-09-29T02:10:00+02:00\"\n            }\n        ],\n        [\n            {\n                \"ID\": \"itB7DTxs6aCl3FWz5QxQVw==\",\n                \"Interval\": \"2020-09-29T02:20:00+02:00\"\n            }\n        ],\n        [\n            {\n                \"ID\": \"h77WS2cu5x7SHoUw6Tgdfg==\",\n                \"Interval\": \"2020-09-29T02:30:00+02:00\"\n            }\n        ],\n        [\n            {\n                \"ID\": \"N99nmdxpfAvk0ByUGWI6EQ==\",\n                \"Interval\": \"2020-09-29T02:40:00+02:00\"\n            }\n        ]\n    ]\n}\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fenrichman%2Fgaen","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fenrichman%2Fgaen","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fenrichman%2Fgaen/lists"}