{"id":50711943,"url":"https://github.com/ba0f3/chartbrew-cli","last_synced_at":"2026-06-09T16:03:13.796Z","repository":{"id":357580652,"uuid":"1237507306","full_name":"ba0f3/chartbrew-cli","owner":"ba0f3","description":null,"archived":false,"fork":false,"pushed_at":"2026-05-13T10:29:41.000Z","size":42,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-05-13T12:32:07.438Z","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":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ba0f3.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-05-13T08:45:01.000Z","updated_at":"2026-05-13T10:30:25.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/ba0f3/chartbrew-cli","commit_stats":null,"previous_names":["ba0f3/chartbrew-cli"],"tags_count":3,"template":false,"template_full_name":"ba0f3/agent-cli-template","purl":"pkg:github/ba0f3/chartbrew-cli","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ba0f3%2Fchartbrew-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ba0f3%2Fchartbrew-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ba0f3%2Fchartbrew-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ba0f3%2Fchartbrew-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ba0f3","download_url":"https://codeload.github.com/ba0f3/chartbrew-cli/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ba0f3%2Fchartbrew-cli/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34114437,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-09T02:00:06.510Z","response_time":63,"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":"2026-06-09T16:03:12.393Z","updated_at":"2026-06-09T16:03:13.788Z","avatar_url":"https://github.com/ba0f3.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Chartbrew CLI\n\n`chartbrew` is an agent-first CLI for the Chartbrew API. It is built for scripts and AI agents that need structured, non-interactive access to teams, dashboards, connections, datasets, data requests, and charts.\n\n## Build and Test\n\n```bash\nmake build    # Builds bin/chartbrew\nmake test     # Runs go test -v ./...\nmake vet      # Runs go vet ./...\nmake fmt      # Formats Go source\nmake tidy     # Updates module metadata\n```\n\n## Releases and Homebrew\n\nGitHub Actions runs `go test` and `go vet` on every push and pull request. Pushing a version tag matching `v*` (for example `v0.1.0`) runs [GoReleaser](https://goreleaser.com/), which creates a GitHub release with archives and updates the Homebrew tap repository.\n\nOne-time setup:\n\n1. Create an empty GitHub repository named `homebrew-tap` under the same owner as this project (for example `https://github.com/ba0f3/homebrew-tap`), default branch `main`.\n2. In this repository’s GitHub **Settings → Secrets and variables → Actions**, add `HOMEBREW_TAP_GITHUB_TOKEN`: a personal access token with **Contents: Read and write** on that tap repository (the default `GITHUB_TOKEN` cannot push to another repo).\n\nThen tag and push:\n\n```bash\ngit tag v0.1.0\ngit push origin v0.1.0\n```\n\nInstall from the tap. GoReleaser publishes prebuilt binaries via Homebrew’s **cask** mechanism (replacing the old `brews` path); the CLI is still command-line only:\n\n```bash\nbrew tap ba0f3/tap\nbrew install --cask chartbrew\n```\n\nTo dry-run a release locally:\n\n```bash\ngoreleaser release --snapshot --clean\n```\n\n## Configuration\n\nConfiguration resolves in this priority order:\n\n1. CLI flags\n2. Environment variables\n3. `.env` in the current working directory\n4. `~/.config/chartbrew/config.json`\n\nSupported environment variables:\n\n```bash\nexport CHARTBREW_API_URL=\"https://api.chartbrew.com\"\nexport CHARTBREW_TOKEN=\"your-api-token\"\n```\n\nConfig file example:\n\n```json\n{\n  \"base_url\": \"https://api.chartbrew.com\",\n  \"token\": \"your-api-token\",\n  \"output\": \"json\",\n  \"allow_delete\": false\n}\n```\n\nGlobal flags:\n\n```bash\nchartbrew --base-url https://api.chartbrew.com --token \"$CHARTBREW_TOKEN\" --output json teams list\nchartbrew --config ./chartbrew.json teams list\n```\n\nPrefer `CHARTBREW_TOKEN`, `.env`, or the config file for tokens. The `--token` flag exists for automation override, but command-line secrets can be stored in shell history.\n\n## Commands\n\nAll commands write structured JSON by default. Use `--output markdown` for a fenced JSON block or `--output raw` for compact JSON.\n\nTeams:\n\n```bash\nchartbrew teams list\nchartbrew teams get --team-id 123\nchartbrew teams create --data '{\"name\":\"Demo\"}'\nchartbrew teams update --team-id 123 --data-file team.json\n```\n\nDashboards use Chartbrew `project` API endpoints:\n\n```bash\nchartbrew dashboards list --team-id 123\nchartbrew dashboards get --dashboard-id 456\nchartbrew dashboards create --data-file dashboard.json\nchartbrew dashboards update --dashboard-id 456 --data-file dashboard.json\nchartbrew dashboards delete --dashboard-id 456\n```\n\nConnections:\n\n```bash\nchartbrew connections list --team-id 123\nchartbrew connections get --team-id 123 --connection-id 456\nchartbrew connections create --team-id 123 --data-file connection.json\nchartbrew connections update --team-id 123 --connection-id 456 --data-file connection.json\n```\n\nDatasets:\n\n```bash\nchartbrew datasets list --team-id 123\nchartbrew datasets get --team-id 123 --dataset-id 456\nchartbrew datasets create --team-id 123 --data-file dataset.json\nchartbrew datasets update --team-id 123 --dataset-id 456 --data-file dataset.json\nchartbrew datasets delete --team-id 123 --dataset-id 456\n```\n\nData requests:\n\n```bash\nchartbrew data-requests list --team-id 123 --dataset-id 456\nchartbrew data-requests get --team-id 123 --dataset-id 456 --request-id 789\nchartbrew data-requests create --team-id 123 --dataset-id 456 --data-file request.json\nchartbrew data-requests update --team-id 123 --dataset-id 456 --request-id 789 --data-file request.json\n```\n\nCharts:\n\n```bash\nchartbrew charts list --dashboard-id 456\nchartbrew charts get --dashboard-id 456 --chart-id 789\nchartbrew charts create --dashboard-id 456 --data-file chart.json\nchartbrew charts update --dashboard-id 456 --chart-id 789 --data-file chart.json\nchartbrew charts delete --dashboard-id 456 --chart-id 789\n```\n\n## JSON Bodies\n\nCreate and update commands accept exactly one body source:\n\n```bash\nchartbrew teams create --data '{\"name\":\"Demo\"}'\nchartbrew datasets create --team-id 123 --data-file dataset.json\nprintf '%s' '{\"name\":\"Demo\"}' | chartbrew teams create --data-file -\n```\n\nThe CLI validates JSON before sending the request.\n\n## Delete Safety\n\nDelete commands are available only for Chartbrew endpoints documented as deletable: dashboards, datasets, and charts.\n\nDelete execution is disabled by default. To allow deletes, set `allow_delete` to `true` in the JSON config file:\n\n```json\n{\n  \"base_url\": \"https://api.chartbrew.com\",\n  \"token\": \"your-api-token\",\n  \"output\": \"json\",\n  \"allow_delete\": true\n}\n```\n\nThe delete opt-in is config-file-only. CLI flags, environment variables, and `.env` cannot enable delete execution.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fba0f3%2Fchartbrew-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fba0f3%2Fchartbrew-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fba0f3%2Fchartbrew-cli/lists"}