---
title: "Set GitHub Actions cache usage policy for a repository"
method: PATCH
path: "/repos/{owner}/{repo}/actions/cache/usage-policy"
tags: ["actions"]
---

# Set GitHub Actions cache usage policy for a repository

`PATCH /repos/{owner}/{repo}/actions/cache/usage-policy`

Sets GitHub Actions cache usage policy for a repository.
You must authenticate using an access token with the `repo` scope to use this endpoint.
GitHub Apps must have the `actions:write` permission to use this endpoint.

## Path parameters

- `owner` string, required
- `repo` string, required

## Request body

- ActionsCacheUsagePolicyForRepository — GitHub Actions cache usage policy for repository.
  - `repo_cache_size_limit_in_gb` integer, required — The size limit for the sum of all caches, in gigabytes.

## Response `204`

Response

---

[API](https://skmtc.net/github/apis/github-v3-rest-api-6.md) · [All operations](https://skmtc.net/github/apis/github-v3-rest-api-6/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/github/github-v3-rest-api-6/versions/15db3fa0759b/schema)
