github-actions-artifact-budget-audit
Audit GitHub Actions artifact storage usage from JSON exports so bloated artifacts are flagged before they inflate CI cost.
Install via CLI (Recommended)
clawhub install openclaw/skills/skills/daniellummis/github-actions-artifact-budget-auditGitHub Actions Artifact Budget Audit
Use this skill to detect oversized or stale GitHub Actions artifacts across repositories.
What this skill does
- Reads one or more GitHub artifact JSON exports (
gh apioutput) - Calculates artifact size in MB and totals by repository + artifact name
- Flags warn/critical artifacts by configurable size thresholds
- Highlights soon-to-expire artifact volume to prioritize cleanup
- Supports text and JSON output for terminal or dashboards
Inputs
Optional:
ARTIFACT_GLOB(default:artifacts/github-actions-artifacts/*.json)TOP_N(default:20)OUTPUT_FORMAT(textorjson, default:text)WARN_MB(default:250)CRITICAL_MB(default:750)SOON_EXPIRES_DAYS(default:7)FAIL_ON_CRITICAL(0or1, default:0)REPO_MATCH(regex, optional)REPO_EXCLUDE(regex, optional)ARTIFACT_MATCH(regex, optional)ARTIFACT_EXCLUDE(regex, optional)
Collect artifact JSON
Single repository:
gh api repos/<owner>/<repo>/actions/artifacts --paginate \
> artifacts/github-actions-artifacts/<owner>-<repo>.json
Combined multi-repo payloads are also supported as long as each file includes an artifacts array.
Run
Text report:
ARTIFACT_GLOB='artifacts/github-actions-artifacts/*.json' \
WARN_MB=300 \
CRITICAL_MB=900 \
bash skills/github-actions-artifact-budget-audit/scripts/artifact-budget-audit.sh
JSON output for automation:
ARTIFACT_GLOB='artifacts/github-actions-artifacts/*.json' \
OUTPUT_FORMAT=json \
FAIL_ON_CRITICAL=1 \
bash skills/github-actions-artifact-budget-audit/scripts/artifact-budget-audit.sh
Filter to one repo and artifact family:
ARTIFACT_GLOB='artifacts/github-actions-artifacts/*.json' \
REPO_MATCH='^flowcreatebot/' \
ARTIFACT_MATCH='(test-results|coverage)' \
bash skills/github-actions-artifact-budget-audit/scripts/artifact-budget-audit.sh
Run with bundled fixtures:
ARTIFACT_GLOB='skills/github-actions-artifact-budget-audit/fixtures/*.json' \
bash skills/github-actions-artifact-budget-audit/scripts/artifact-budget-audit.sh
Output contract
- Exit
0in reporting mode (default) - Exit
1ifFAIL_ON_CRITICAL=1and at least one artifact is at/aboveCRITICAL_MB - In
textmode: prints summary and top oversized artifact groups - In
jsonmode: prints summary, grouped artifact stats, and critical artifact instances
Metadata
Not sure this is the right skill?
Describe what you want to build — we'll match you to the best skill from 16,000+ options.
Find the right skillPaste this into your clawhub.json to enable this plugin.
{
"plugins": {
"official-daniellummis-github-actions-artifact-budget-audit": {
"enabled": true,
"auto_update": true
}
}
}Related Skills
github-actions-recovery-latency-audit
Measure GitHub Actions failure recovery latency and unresolved incident age by workflow group.
github-actions-cache-hardening-audit
Audit GitHub Actions workflow cache usage for poisoning, keying, and secret-path risks.
render-env-guard
Preflight-check Render service environment variables before deploys; catches missing keys and placeholder/template values that commonly break production rollouts.
github-actions-trigger-health-audit
Audit GitHub Actions run health by trigger event and workflow so flaky or noisy automation sources are easy to prioritize.
github-actions-run-gap-audit
Detect GitHub Actions workflow groups that stopped running on their normal cadence using median run intervals and current inactivity gap.