---
title: "Patch Workspace File"
method: PATCH
path: "/api/files/content"
tags: ["workspace-files"]
---

# Patch Workspace File

`PATCH /api/files/content`

## Request body

- WorkspaceFilePatchRequest
  - `path` string, required
  - `old` string, required
  - `new` string, required
  - `expected_sha256` string, nullable

## Response `200`

Successful Response

- WorkspaceFileEntryResponse
  - `path` string, required
  - `kind` 'file' | 'directory', required
  - `byte_size` integer, nullable
  - `modified_at` string, nullable
  - `checksum_sha256` string, nullable

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/qredence/apis/fleet-rlm.md) · [All operations](https://skmtc.net/qredence/apis/fleet-rlm/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/qredence/fleet-rlm/revisions/c47be4a3f07e/schema)
