---
title: "Set artifact and log retention settings for an enterprise"
method: PUT
path: "/enterprises/{enterprise}/actions/permissions/artifact-and-log-retention"
tags: ["enterprise-admin"]
---

# Set artifact and log retention settings for an enterprise

`PUT /enterprises/{enterprise}/actions/permissions/artifact-and-log-retention`

Sets artifact and log retention settings for an enterprise.

## Path parameters

- `enterprise` string, required

## Request body

- ActionsArtifactAndLogRetention
  - `days` integer, required — The number of days to retain artifacts and logs

## Response `204`

Successfully updated the artifact and log retention settings

## Other responses

- `404` — Resource not found
- `422` — Validation failed, or the endpoint has been spammed.

---

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