Skip to content
API reference/Saved sections

Save a section for reuse

Try it

Saves a section of a site's draft (as it is now) to your account's library. With link: true (the default) that section becomes a LINKED placement of it. A contact form can't be saved — it belongs to one site's messages.

POST/api/v1/saved-sections

Authentication

An API key as Authorization: Bearer or x-api-key. It needs the sites:write scope — edit draft pages and sections.

sites:writeChanges the draft or a recordIdempotency-Key requiredMCP tool: create_saved_section

Parameters

Named placeholders go in the path; the rest in a JSON body.

site_idstringBody · required
The site's id.1 to 100 characters
section_idstringBody · required
The section's id.1 to 100 characters
namestringBody · required
The name in your library.1 to 60 characters
linkbooleanBody · optional
Link the section you saved from to the new saved section.Default true

Response

201 with JSON on success (schema on the right). Errors use the standard envelope; a retry with the same Idempotency-Key gets the first answer back (how retries work).

curl
curl -X POST 'https://websites.workflowcorp.com/api/v1/saved-sections' \
  -H "Authorization: Bearer $WEBSITEBUDDY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"site_id":"SITE_ID","section_id":"SECTION_ID","name":"Summer promo band","link":true}'
Example arguments
{
  "site_id": "SITE_ID",
  "section_id": "SECTION_ID",
  "name": "Summer promo band",
  "link": true
}
Response schema
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "type": {
      "type": "string"
    },
    "type_label": {
      "type": "string"
    },
    "content": {
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {},
      "description": "The section's content; its shape is the type's content_schema (List section types)."
    },
    "placements": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991,
      "description": "Linked placements across every site of the account."
    },
    "sites": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991,
      "description": "How many websites show it linked."
    },
    "saved_from": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "description": "The name of the site it was saved from."
    },
    "created_at": {
      "type": "string"
    },
    "updated_at": {
      "type": "string"
    }
  },
  "required": [
    "id",
    "name",
    "type",
    "type_label",
    "content",
    "placements",
    "sites",
    "saved_from",
    "created_at",
    "updated_at"
  ],
  "additionalProperties": false
}