Skip to main content
Version: 202607

Batch theme operations

POST 

/openapi/2026-07/themes/edit-sessions/:oseid/files/:doc_id/operations

Execute multiple theme edit operations in one request; each op is applied and persisted independently, and a failure on one does not stop the others.

Request

Path Parameters

    oseid stringrequired

    Edit session ID (oseid)

    doc_id stringrequired

    Document ID of the file within the session

Bodyrequired

    operations object[]required

    Ordered list of theme operations executed in one batch. Each op is applied and persisted independently, and a failure on one does not stop the others. See ThemeOperation.

  • Array [
  • opstringrequired

    The operation to perform. One of: add_section, remove_section, move_section, replace_props, set_visibility, append_array_item, remove_array_item, update_slot, replace_global, set_script_visibility.

    targetstring

    Path to the target card or block; its meaning depends on op. Pass a section's id to address a section, or a dotted path such as sec1.blocks.0 (or deeper, sec1.blocks.0.blocks.2) to address a nested block.

    valueGoogleProtobufValue

    The new card, block, or blocks-array content. Applies to add_section, append_array_item, and update_slot.

    propsobject

    The settings fields to merge in. Applies to replace_props and replace_global.

    visibleboolean

    Target visibility. Applies to set_visibility and set_script_visibility.

    positionstring

    Placement relative to the target: before or after. Applies to add_section and move_section.

    move_targetstring

    Id of the reference card next to which the target is placed. Applies to move_section.

  • ]

Responses

OK

Schema
    codestring

    error code

    messagestring

    error message

    data object
    data object[]

    The result of each operation.

  • Array [
  • opstring

    The operation type, echoing the op of the corresponding request item.

    resultstring

    Outcome of the operation: success if it succeeded, otherwise an error code (which may include a :detail suffix).

  • ]