---
title: "POST /api/files/move"
method: POST
path: "/api/files/move"
---

# POST /api/files/move

`POST /api/files/move`

## Request body

- FileMoveRequest
  - `newPath` string, required
  - `path` string, required

## Response `200`

Move a file or directory

- FileMoveResponse
  - `info` FileInfo
    - `children` FileInfo[]
    - `id` string, required
    - `isDirectory` boolean, required
    - `isMarimoFile` boolean, required
    - `lastModified` number, nullable
    - `name` string, required
    - `opengraph` OpenGraphMetadata — OpenGraph-style metadata for a notebook. The `image` field may be either: - a relative path (typically under `__marimo__/`), or - an absolute HTTPS URL.
      - `description` string, nullable
      - `image` string, nullable
      - `title` string, nullable
    - `path` string, required
    - `size` integer, nullable
  - `message` string, nullable
  - `success` boolean, required

## Changes

- **2026-07-24** `a6054d54dad6` — 1 info
  - added the optional property `info/anyOf[subschema #2: FileInfo]/size` to the response with the `200` status

[Change history](https://skmtc.dev/marimo-team/apis/marimo-api/changes/api/files/move/post.md)

---

[API](https://skmtc.dev/marimo-team/apis/marimo-api.md) · [All operations](https://skmtc.dev/marimo-team/apis/marimo-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/marimo-team/marimo-api/revisions/a39082aac3ce/schema)
