versions

Update an existing version

Updates the data in an existing version, keeping the same version and the same link. By default the version's own content is preserved - including any manual edits made to it in the editor - and only the fields you send in data are changed. Pass force: true only to DISCARD those edits and re-render the version from the master story template.

post/v2/versions/{versionId}

Request

  • Base URL
    https://api.storydoc.com
  • Auth
    HTTP bearer

Path parameters

versionIdstring required
Example:61b1f40a3a86b7a96d0d8ccc

The ID of the version to update

Request body

senderEmailstring email required

Email of the sender (must exist in organization)

forceboolean

DESTRUCTIVE. Re-renders the version from the master story template and discards any manual edits made to it in the editor. Leave unset to update the version in place, preserving its content.

Example request

{
  "senderEmail": "john.doe@company.com",
  "data": {
    "title": "Sales Presentation",
    "company": "ACME Corp",
    "custom_field_1": "Any value",
    "custom_field_2": 12345,
    "logo": {
      "domain": "acme.com",
      "theme": "dark"
    },
    "partner_logo": {
      "domain": "microsoft.com",
      "theme": "light"
    }
  }
}

Response

Version updated successfully

urlstring uri

Public URL for the version

shortUrlstring uri

Shortened URL for the version

editorUrlstring uri

URL to edit the version in Storydoc editor

versionUrlstring uri

URL to view version details in Storydoc platform

versionIdstring

Unique identifier for the version (only in create response)

Example response

{
  "url": "https://www.storydoc.com/5d7d8922e00d9265/2e91b144-092f-456b-8f2e-0bae9f7f3355",
  "shortUrl": "https://view.storydoc.com/4GdDGt",
  "editorUrl": "https://app.storydoc.com/pages/editor/61b1e50223b713000a41ca74/61b1f40a3a86b7a96d0d8ccc",
  "versionUrl": "https://app.storydoc.com/pages/editor/61b1e50223b713000a41ca74/versions/61b1f40a3a86b7a96d0d8ccc",
  "versionId": "61b1f40a3a86b7a96d0d8ccc"
}

Changes

No recorded changes to this operation across all 1 revision of this API.