Back to Content Management API
collectionPageAddSectionsBulk
Add multiple sections to multiple pages.
Arguments
- Name
ids- Type
- [ID!]!
- Description
Array of page IDs that you want to add sections to.
- Name
input- Type
- [CollectionPageAddSectionsInput!]!
- Description
An object that takes in an array of
sectionIdsand astrategyfor how to handle the sections attached to the pages.sectionIds:[ID!]!The IDs of the sections to add.strategy:DuplicateSectionStrategy!cloneadds a new copy of each section;linkadds the existing section, shared with the content it already appears on.
Returns
- Name
Job.*- Type
- Job
- Description
The
idof the background job that runs the bulk operation.
Request
import { PackClient } from '@pack/client'
const packClient = new PackClient({
token: 'YOUR-PACK-TOKEN'
});
const response = await packClient.fetch(query, { variables: variables });
console.log(response.data);
Response
{
"data": {
"collectionPageAddSectionsBulk": {
"id": "1"
}
}
}