---
title: "Prefetch content"
method: POST
path: "/cdn/resources/{resource_id}/prefetch"
tags: ["Tools"]
---

# Prefetch content

`POST /cdn/resources/{resource_id}/prefetch`

Pre-populate files to a CDN cache before users requests. Prefetch is recommended only for files that **more than 200 MB** and **less than 5 GB**.

You can make one prefetch request for a CDN resource per minute. One request for prefetch may content only up to 100 paths to files.

The time of procedure depends on the number and size of the files.

If you need to update files stored in the CDN, first purge these files and then prefetch.

## Path parameters

- `resource_id` integer, required

## Request body

- ResourcePrefetch
  - `paths` string[], required — Paths to files that should be pre-populated to the CDN. Paths to the files should be specified without a domain name.

## Response `201`

Successful.

## Other responses

- `400` — Prefetch request validation is failed.
- `429` — You have exceeded number of allowed prefetch requests for your CDN resource.

---

[API](https://skmtc.dev/g-core/apis/gcore-openapi.md) · [All operations](https://skmtc.dev/g-core/apis/gcore-openapi/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/g-core/gcore-openapi/revisions/09e652815095/schema)
