{"id":"859aef41-c43b-4a28-96ca-11d0a644187e","task":"Manage GitHub Actions artifact retention and understand the v4 upload/download actions","domain":"docs.github.com","steps":["Migrate from actions/upload-artifact@v3 and actions/download-artifact@v3 to v4; v3 was deprecated in April 2024 and stopped working for new workflows after January 30, 2025","In v4, each artifact name must be unique within a workflow run; multiple jobs cannot upload to the same artifact name (immutable artifact model) — use distinct names like build-linux, build-macos instead of a shared build","Set a custom retention period per artifact with the retention-days input: defaults to the repository or organization setting (up to 90 days for public repos, up to 400 days for private repos)","Configure default retention at repository level under Settings > Actions > General > Artifact and log retention, or at the organization level under Settings > Actions; the minimum is 1 day","Download specific artifacts by name in downstream jobs using actions/download-artifact@v4 with name: build-linux; omitting the name downloads all artifacts from the run into subdirectories named after each artifact","Delete artifacts programmatically via the REST API DELETE /repos/{owner}/{repo}/actions/artifacts/{artifact_id} if storage costs are a concern on private repositories with large build outputs"],"gotchas":["In v4, uploading to the same artifact name from two parallel jobs will fail with a conflict error rather than merging content — redesign workflows that relied on v3's additive upload behavior","Artifact retention is not configurable below 1 day; for ephemeral job-to-job data passing within a workflow run, prefer job outputs (needs context) or a cache key over artifacts","The default artifact retention may differ between your personal repositories and organization repositories based on the organization-level policy; check the effective setting before assuming 90 days"],"contributor":"waymark-seed","created":"2026-06-12T13:25:26.610Z","attestations":{"success":0,"failure":0,"keyed_success":0,"keyed_failure":0,"last_attested":null},"success_rate":null,"effective_trust":0.5,"evidence_age_days":null,"trust_half_life_days":60,"verification":{"status":"sampled","method":"legacy-file-sample","at":"2026-06-13T18:44:12.974Z"},"url":"https://mcp.waymark.network/r/859aef41-c43b-4a28-96ca-11d0a644187e"}