{"id":21846910,"url":"https://github.com/duyet/gaxy","last_synced_at":"2025-04-14T13:32:52.788Z","repository":{"id":37898796,"uuid":"300133874","full_name":"duyet/gaxy","owner":"duyet","description":"Google Analytics / Google Tag Manager Proxy","archived":false,"fork":false,"pushed_at":"2025-03-04T20:23:59.000Z","size":446,"stargazers_count":15,"open_issues_count":3,"forks_count":3,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-28T02:39:05.060Z","etag":null,"topics":["golang","google-analytics","hacktoberfest","proxy"],"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/duyet.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}},"created_at":"2020-10-01T03:51:55.000Z","updated_at":"2025-03-07T04:17:16.000Z","dependencies_parsed_at":"2024-02-07T08:32:35.509Z","dependency_job_id":"053a23fa-2846-469b-82bd-5660eb2b14e5","html_url":"https://github.com/duyet/gaxy","commit_stats":{"total_commits":80,"total_committers":8,"mean_commits":10.0,"dds":0.4375,"last_synced_commit":"23584c9fe160948a84f078a1f189f598ee0eac62"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/duyet%2Fgaxy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/duyet%2Fgaxy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/duyet%2Fgaxy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/duyet%2Fgaxy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/duyet","download_url":"https://codeload.github.com/duyet/gaxy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248888682,"owners_count":21178093,"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":["golang","google-analytics","hacktoberfest","proxy"],"created_at":"2024-11-27T23:16:06.365Z","updated_at":"2025-04-14T13:32:52.706Z","avatar_url":"https://github.com/duyet.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# gaxy\n\nDeployment: https://project-gaxy.appspot.com/ga.js\n\n![Docker](https://github.com/duyet/gaxy/workflows/Docker/badge.svg)\n![Go test](https://github.com/duyet/gaxy/workflows/Go/badge.svg)\n\nGoogle Analytics / Google Tag Manager Proxy by Go.\n\n![How it works?](.github/screenshot/how-gaxy-works.png)\n\u003c!-- https://sketchviz.com/@duyet/d4c36c277140a24111a723c439291303/9b91c5b780ff792c7dc08f70d22442a3ac523096 --\u003e\n\n## Development\n\nStart server in local:\n\n```sh\ngo run *.go\n```\n\nBuild binary:\n\n```sh\ngo build -o gaxy .\n./gaxy\n```\n\nTesting:\n\n```sh\ngo test\n```\n\n## Installation\n\n### Using Docker\n\nhttps://github.com/users/duyet/packages/container/package/gaxy\n\n```sh\ndocker run -it -p 3000:3000 \\\n    -e ROUTE_PREFIX=/analytics \\\n    -e GOOGLE_ORIGIN=https://www.google-analytics.com \\\n    ghcr.io/duyet/gaxy:latest\n```\n\n### Using Helm\n\nhttps://github.com/duyet/charts/tree/master/gaxy\n\n```sh\nhelm repo add duyet https://duyet.github.io/charts\nhelm install google-analytics-proxy duyet/gaxy\n```\n\n### Using Google App Engine\n\nhttps://cloud.google.com/appengine/docs/standard/go/quickstart\n\n```sh\n# 1. install gcloud\n# 2. install app-engine-go component\ngcloud components install app-engine-go\n# 3. deploy\ngcloud app deploy\n```\n\n### Environment variables\n\nThe following environment values are provided to customize Gaxy:\n\n- `ROUTE_PREFIX`: Gaxy proxy prefix (e.g. `/analytics`). Default **\"\"**\n- `GOOGLE_ORIGIN`: Hostname to Google Analytics. Default **https://www.google-analytics.com**\n- `INJECT_PARAMS_FROM_REQ_HEADERS`: Convert header fields (if gaxy is behind reverse proxy) to request parameters.\n  - e.g. `INJECT_PARAMS_FROM_REQ_HEADERS=uip,user-agent` will be add this to the collector URI: `?uip=[VALUE]\u0026user-agent=[VALUE]`\n  - To rename the key, use `[HEADER_NAME]__[NEW_NAME]` e.g. `INJECT_PARAMS_FROM_REQ_HEADERS=x-email__uip,user-agent__ua`\n  - List all the parameters of Google Analytics:\n\n        - https://developers.google.com/analytics/devguides/collection/protocol/v1/parameters\n        - https://developers.google.com/analytics/devguides/collection/analyticsjs/field-reference\n\n- `PORT`: Gaxy webserver port. Default: **8080**\n\n## Usage\n\n```html\n\u003c!-- Google Analytics --\u003e\n\u003cscript\u003e\nwindow.ga=window.ga||function(){(ga.q=ga.q||[]).push(arguments)};ga.l=+new Date;\nga('create', 'UA-XXXXX-Y', 'auto');\nga('send', 'pageview');\n\u003c/script\u003e\n\u003cscript async src='https://project-gaxy.appspot.com/analytics.js'\u003e\u003c/script\u003e\n\u003c!-- End Google Analytics --\u003e\n```\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fduyet%2Fgaxy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fduyet%2Fgaxy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fduyet%2Fgaxy/lists"}