Skip to main content
Version: 202601

Update edit session file

PATCH 

/openapi/2026-01/themes/edit-sessions/:oseid/files/:doc_id

Overwrite a template file in the edit session with the given card configs; cards missing from the list are removed. For partial changes, use Batch edit operations.

Request

Path Parameters

    oseid stringrequired

    Edit session ID

    doc_id stringrequired

    Document ID of the file within the session

Bodyrequired

    config object[]

    The file's complete, ordered list of section configs. This is a whole-file write: the list REPLACES the file's current sections and any section omitted here is removed. Array order is the on-page render order. For incremental edits use the batch-operations endpoint

  • Array [
  • idint64

    Numeric section instance ID (the timestamp-style id stored in the file). Name-addressed global cards (header, footer, announcement, cart_drawer) cannot be expressed here

    settingsobject

    Section settings object

    with_hook_setboolean

    Read-only render flag echoed back from the rendering service; sending it in a request has no effect. Defaults to false

  • ]
  • global_config object

    Global config

    libsstring

    Theme-level library (libs) config. This whole-file write endpoint does not consume it — it only reads each config item's id and settings, plus layout. Pass "" here

    layoutstring

    Layout name, e.g. theme

Responses

OK

Schema
    codestring

    error code

    messagestring

    error message

    data object
    template_dataobject

    Updated template data ({sections, content_for_page})