Add page element
add_page_elementInsert one element into a slot of a board's published page, or into a column of a section element when parent_element_id is given. Returns the slot as it now stands plus element_id. Supply element.id yourself: re-sending the same add then converges (200, nothing inserted), while the same id with DIFFERENT content is 409 element_exists — pick another id or use update_page_element. Props that carry HTML or a URL must be strings. An asset_token prop takes a token from list_assets; the server copies that asset into the page's library and stores the copy's token. To add several elements, or a section plus its contents, prefer apply_page_operations (atomic). Requires modify on the board and page-layout API writes enabled for the workspace — otherwise 403 page_layout_api_disabled, which only Playbook can turn on; retrying does not help. Concurrency: pass the version_token from get_page_layout as expected_version_token; if the page changed since, the call answers 409 stale_document and applies NOTHING — read again, re-decide, re-send. A successful write that sent a token returns the NEW version_token: send that on your next write, because your own write already made the old one stale. Of the 409s only lock_wait_timeout and page_layout_library_locked are safe to repeat unchanged. converged: true in the response means nothing changed (the goal state already held); materialized: true means the page had no stored document and this call saved the template's defaults. Both keys are ABSENT when false. The public page can keep showing the old version for up to an hour after a successful write, so a reload may not show the change.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| token | Yes | Board token of the published board | |
| element | Yes | ||
| slot_id | Yes | A slot's id from get_page_layout, or its NAME (e.g. `menu`, `grid`). Use the name when get_page_layout reports `slots: null`: the write stores the template defaults and the response carries real ids to address from then on. | |
| at_index | Yes | 0-based position in the slot (or column). Past the end appends. | |
| column_id | No | Id to give a column this call CREATES (with create_new_column, or when column_index is past the last column). It does NOT pick an existing column: without column_index the element lands in column 0. Address an existing column with column_index. | |
| column_index | No | Section column to insert into, by 0-based position. | |
| organization | No | Workspace slug, as returned by list_organizations. Omit it when the account has a single workspace — it is then resolved from your token. Pass it only when the account has several, or when you mean a workspace other than the obvious one. | |
| subboard_token | No | Edit a nested board's section of this page instead of the page itself: the `collectionToken` of an entry in get_page_layout's `subboards_settings`. Omit for the main page. | |
| create_new_column | No | Create a new column in the section for this element. | |
| parent_element_id | No | Insert into this `section` element's columns instead of at slot top level. | |
| expected_version_token | No | The `version_token` from get_page_layout, echoed verbatim to make this write a compare-and-swap. Omit to write unconditionally. |