Client area

POST · File manager

Write a file, make a directory, copy, move or set permissions

Write a file, make a directory, copy, move or set permissions

POST /api/v1/files/move
W Write
Scope write:files

Description

action=write needs path and content; mkdir needs path; copy/move need source and destination; permissions needs path and an octal mode (e.g. 0644). Every path is confined to the account home. All actions require write:files.

Body

Send as application/json.

Name Type Description
input required string A domain, email address, website URL, or Inleed service id — for example example.se, [email protected] or 42976. Resolved to the owning account automatically, and the resolved target is echoed back in the response.
action required enum write a text file, mkdir a directory, copy or move an entry, or set permissions. All require write:files. One of write, mkdir, copy, move, permissions.
path string The target path, relative to the account home (e.g. /domains/example.com/public_html/.htaccess).
content string The full new text content for action=write (max 256 KB). It is treated as data and never echoed back or logged.
source string The path to copy or move from, relative to the account home. Required for copy and move.
destination string The directory to copy or move into, relative to the account home. Required for copy and move.
mode string The octal permission mode for action=permissions, e.g. 0644 or 755.

Responses

The specification does not describe this response body; the note in the rail says what to expect. Every non-2xx response is an RFC 7807 problem with a stable code.

Commonly returned errors

The codes this operation reaches on its own path: the auth stack, its own validation and ownership checks, and the transport. Not a closed set — a shared code from the full registry can still surface. Each links to the code’s own page, the same URL its type dereferences to.

401 No token was presented, or the token is revoked, expired or unknown.
403 The token lacks a required scope, or this account does not own the resource.
404 No such resource for this account.
422 Validation error
429 The rate limit for this token is exhausted. See `Retry-After`.
500 Something went wrong on our side. The failure is logged against `requestId`.
Esc
navigate open Esc close