PUT/api/v1/artifacts/{slug}/file

Replace a file

Swaps the file behind a link for one uploaded with Get a single upload URL, keeping the link and its settings. The previous file is kept as a version.

API token required20 per minute per IPCLI: markdrop replace

Guide: Replace and versions

Code samples and Try it

Path parameters

#
  • slugstringRequired

    The document's address: the part after markdrop.in/.

Request body

#

application/json, required

  • blob_keystringRequired

    1–300 characters.

  • filenamestring

    Up to 255 characters.

Responses

#
  • 200OK.
  • 401No token, or the token is revoked or mistyped.
  • 422The request didn't validate. detail lists each problem, with where it is (loc) and why (msg).
  • 429Too many requests from your IP address. Wait the seconds in Retry-After.
  • 507The owner's storage is full.
200 response: 20 fields (ArtifactResponse)
  • slugstring
  • urlstring
  • titlestring | null

    Shown on the page and in link previews.

  • kindstring

    Default "artifact".

  • mimestring
  • rendererstring
  • type_labelstring
  • size_bytesinteger
  • original_filenamestring | null
  • artifact_urlstring
  • workspace_urlstring | null
  • download_urlstring
  • poster_urlstring | null
  • mediaobject | null
  • created_atstring (date-time)

    ISO 8601, for example 2026-11-30T12:00:00Z.

  • updated_atstring (date-time)

    ISO 8601, for example 2026-11-30T12:00:00Z.

  • expires_atstring (date-time) | null

    ISO 8601, for example 2026-11-30T12:00:00Z.

  • viewsinteger

    Default 0.

  • is_password_protectedboolean

    Default false.

  • is_ownerboolean

    Default false.

Did this page help?