On September 25th, 2024, we released v2 of the Apps SDK. To learn what’s new and how to upgrade, see Migration FAQ and Migration guide.

editContent

API reference for the editContent method.
This version of the API is a preview. Preview APIs are unstable and may change without warning. You can't release public apps using this API until it's stable.

Reads and edits fill content from the user's design.

Parameters

optionsobject
Required

Options for configuring how a design is read. Must specify contentType: 'fill'.

targetstring
Required

This must be "current_page".

contentTypestring
Required

This must be "fill".

callbackfunction
Required

A callback that receives a FillContentSession for editing.

Parameters

sessionFillContentSession
Required

Session for reading and updating fill content in a user's design.

contentsFillContent[]Read-only
Required
typestring
Required

This must be "image".

refImageRef
Required
deletedboolean
Required
typestring
Required

This must be "video".

refVideoRef
Required
deletedboolean
Required
syncfunction
Required

Returns

Promise<void>

Returns

void or Promise<void>

Returns

A promise that resolves when editing is complete.

Promise<void>