---
title: "Create Cache"
method: POST
path: "/cache/create"
tags: ["Cache"]
---

# Create Cache

`POST /cache/create`

Create a persistent cache for low-latency completions.

Args:
    name: Unique identifier for the cache.
    model: The model name to use when generating completions.
    gguf_file: Path to the ``gguf`` weights file to load.
    filters: Optional metadata filters used to select documents.
    docs: Explicit list of document IDs to include in the cache.
    auth: Authentication context used for permission checks.

Returns:
    A dictionary describing the created cache.

## Query parameters

- `name` string, required
- `model` string, required
- `gguf_file` string, required

## Headers

- `authorization` string

## Request body

- BodyCreateCacheCacheCreatePost
  - `filters` object, nullable
  - `docs` string[], nullable

## Response `200`

Successful Response

- object

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.dev/morphik-org/apis/fastapi.md) · [All operations](https://skmtc.dev/morphik-org/apis/fastapi/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/morphik-org/fastapi/revisions/9ade02dd7b1d/schema)
