---
title: "Rename a file or directory of a hosted project in place"
method: POST
path: "/api/v0/desk/projects/{project_id}/rename"
tags: ["Desk"]
---

# Rename a file or directory of a hosted project in place

`POST /api/v0/desk/projects/{project_id}/rename`

## Request

- Base URL: `https://api.outerport.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.outerport.com/api/v0/desk/projects/{project_id}/rename`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/outerport/apis/outerport-api/docs/api/v0/desk/projects/:project_id/rename/post.ts> (a function with typed inputs; its response is checked against the schema)

## Path parameters

- `project_id` string, uuid, required

## Request body

- DeskProjectRenameEntryRequest
  - `path` string, required
  - `new_name` string, required

## Response `200`

Successful Response

- DeskProjectEntryResponse: The path an operation left behind, the hash it holds, and the revision it moved the project to.
  - `path` string, required
  - `revision` integer, required
  - `sha256` string, nullable

## Other responses

- `422`: Validation Error

## Changes

- **2026-10-26** `07854361a13b`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/outerport/apis/outerport-api/changes/api/v0/desk/projects/:project_id/rename/post.md)

---

[API](https://skmtc.dev/outerport/apis/outerport-api.md) - [All operations](https://skmtc.dev/outerport/apis/outerport-api/llms.txt) - [OpenAPI document](https://skmtc.dev/outerport/apis/outerport-api/revisions/08b5bf6f7f18?raw)
