HubSpot: Update a batch of Blog Posts
HubSpot blogPosts.batchUpdatePosts: arguments, response, policy and SDK examples.
← Blog posts operations · Get started
Operation hubspot.blog_posts_batch_update_posts
Provider route: POST /cms/blogs/2026-09/posts/batch/update. Alter supplies the connection’s credentials and routing.
Call through Alter
Section titled “Call through Alter”Install @alter-ai/sdk @alter-ai/hubspot with npm, or alter-sdk-hubspot with pip. Supply your connected customer’s grant ID and the arguments described below.
import { App } from "@alter-ai/sdk";import { HubSpotIntegration } from "@alter-ai/hubspot";
async function execute(input: Parameters<HubSpotIntegration["blogPosts"]["batchUpdatePosts"]>[0]) { const app = new App({ apiKey: process.env.ALTER_API_KEY! }); try { const provider = new HubSpotIntegration(app, { grantId: process.env.PROVIDER_GRANT_ID! }); const call = await provider.blogPosts.batchUpdatePosts(input); const result = await call.wait(); return result.bodyJson(); } finally { await app.close(); }}import osfrom alter_sdk import Appfrom alter_sdk_hubspot import HubSpotIntegration
async def execute(arguments): async with App(api_key=os.environ["ALTER_API_KEY"]) as app: provider = HubSpotIntegration(app, {"grant_id": os.environ["PROVIDER_GRANT_ID"]}) call = await provider.blog_posts.batch_update_posts(arguments) result = await call.wait() return result.body_json()| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: not allowed |
query | object | Optional | Additional keys: not allowed |
query.archived | boolean | Optional | |
body | object | Required within parent | |
body.inputs | array | Required within parent | The records to update, each with its id. |
body.inputs[] | Model | Each item | Expand Update a post — request body — body |
Referenced models: Update a post — request body — body
Response
Section titled “Response”Response media type: application/json. The table describes the pinned successful response. Referenced models link to their complete fields.
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | JSON | Root | |
$ (anyOf 1) | Model | Alternative | Expand Create a batch of blog posts — response body — status: CANCELED, COMPLETE, PENDING, PROCESSING — Batch Response Blog Post |
$ (anyOf 2) | Model | Alternative | Expand Create a batch of blog posts — response body — status: CANCELED, COMPLETE, PENDING, PROCESSING — Batch Response Blog Post With Errors |
Referenced models: Create a batch of blog posts — response body — status: CANCELED, COMPLETE, PENDING, PROCESSING — Batch Response Blog Post, Create a batch of blog posts — response body — status: CANCELED, COMPLETE, PENDING, PROCESSING — Batch Response Blog Post With Errors
Schemas
Section titled “Schemas”27 more schemas are linked from the tables above, on the schema pages.
Create a batch of blog posts — response body — status: CANCELED, COMPLETE, PENDING, PROCESSING — Batch Response Blog Post
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
completedAt | string | Required within parent | Time of batch operation completion. Format: date-time |
links | object | Optional | Links associated with batch operation. Additional keys: see wildcard field |
links.* | string | Additional keys | |
requestedAt | string | Optional | Time of batch operation request. Format: date-time |
results | array | Required within parent | Results of batch operation. |
results[] | Model | Each item | Expand Update a post — response body |
startedAt | string | Required within parent | Time of batch operation start. Format: date-time |
status | string | Required within parent | Status of batch operation. Known values: CANCELED, COMPLETE, PENDING, PROCESSING |
Referenced models: Update a post — response body
Create a batch of blog posts — response body — status: CANCELED, COMPLETE, PENDING, PROCESSING — Batch Response Blog Post With Errors
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
completedAt | string | Required within parent | Time of batch operation completion. Format: date-time |
errors | array | Optional | Errors in batch operation. |
errors[] | Model | Each item | Expand Create folders — response body — status: CANCELED, COMPLETE, PENDING, PROCESSING errors item |
links | object | Optional | Links associated with batch operation. Additional keys: see wildcard field |
links.* | string | Additional keys | |
numErrors | JSON | Optional | |
numErrors (anyOf 1) | integer | Alternative | Number of errors. Format: int32 |
numErrors (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
requestedAt | string | Optional | Time of batch operation request. Format: date-time |
results | array | Required within parent | Results of batch operation. |
results[] | Model | Each item | Expand Update a post — response body |
startedAt | string | Required within parent | Time of batch operation start. Format: date-time |
status | string | Required within parent | Status of batch operation. Known values: CANCELED, COMPLETE, PENDING, PROCESSING |
Referenced models: Create folders — response body — status: CANCELED, COMPLETE, PENDING, PROCESSING errors item, Update a post — response body
Update a post — request body — body translations value
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
archivedInDashboard | boolean | Required within parent | If True, the variant will not show up in your dashboard, although the post could still be live. |
authorName | string | Required within parent | The name of the user who last published the blog post. For posts that haven't been published yet, this property will reflect the user who initially created the draft. |
campaign | string | Required within parent | The GUID of the marketing campaign this page is a part of. |
campaignName | string | Required within parent | Name of the associated marketing campaign. |
created | string | Required within parent | The timestamp (ISO8601 format) when this Blog Post was created. Format: date-time |
id | integer | Required within parent | ID of object to set as primary in multi-language group. Format: int64 |
name | string | Required within parent | The internal name of the content language variation. |
password | string | Required within parent | Set this to create a password protected page. Entering the password will be required to view the page. |
publicAccessRules | array | Required within parent | The set of rules governing public access to this language variation. |
publicAccessRules[] | Model | Each item | Expand List tags — response body |
publicAccessRulesEnabled | boolean | Required within parent | Boolean to determine whether or not to respect publicAccessRules. |
publishDate | string | Required within parent | The date (ISO8601 format) the page is to be published at. Format: date-time |
slug | string | Required within parent | The path of the this page. This field is appended to the domain to construct the url of this page. |
state | string | Required within parent | An ENUM describing the current state of this page. Maximum string length: 25 |
tagIds | array | Optional | An array of tag identifiers associated with this language variation. |
tagIds[] | integer | Each item | Format: int64 |
updated | string | Required within parent | The timestamp (ISO8601 format) when this Blog Post was updated. Format: date-time |
Referenced models: List tags — response body
Update a post — request body — body layout Sections value
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
cells | array | Required within parent | The cells contained within the layout section, defining its structure. |
cells[] | Model | Each item | Expand Update a post — request body — body layout Sections value |
cssClass | string | Required within parent | The CSS class applied to the layout section. |
cssId | string | Required within parent | The CSS ID applied to the layout section. |
cssStyle | string | Required within parent | Custom CSS styles applied to the layout section. |
label | string | Required within parent | The label for the layout section. |
name | string | Required within parent | The name assigned to the layout section. |
params | object | Required within parent | Additional parameters for the layout section, typically used for configuration. Additional keys: see wildcard field |
params.* | object | Additional keys | |
rowMetaData | array | Required within parent | Metadata associated with the rows in the layout section. |
rowMetaData[] | Model | Each item | Expand Update a post — request body — body layout Sections value row Meta Data item |
rows | array | Required within parent | The number of rows in the layout section. |
rows[] | object | Each item | Additional keys: see wildcard field |
rows[].* | Model | Additional keys | Expand Update a post — request body — body layout Sections value |
styles | Model | Required within parent | Expand Update a post — request body — body layout Sections value styles |
type | string | Required within parent | The type of the layout section. |
w | integer | Required within parent | The width of the layout section. Format: int32 |
x | integer | Required within parent | The x-coordinate position of the layout section. Format: int32 |
Referenced models: Update a post — request body — body layout Sections value, Update a post — request body — body layout Sections value row Meta Data item, Update a post — request body — body layout Sections value styles
List tags — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root |
Create folders — response body — status: CANCELED, COMPLETE, PENDING, PROCESSING errors item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Ye olde error |
category | string | Required within parent | Error category. |
context | object | Required within parent | Error context. Additional keys: see wildcard field |
context.* | array | Additional keys | |
context.*[] | string | Each item | |
errors | array | Required within parent | List of error details. |
errors[] | Model | Each item | Expand Batch insert events — response body — errors item errors item |
id | string | Optional | Error ID. |
links | object | Required within parent | Error links. Additional keys: see wildcard field |
links.* | string | Additional keys | |
message | string | Required within parent | Error message. |
status | string | Required within parent | Error status. |
subCategory | object | Optional | Error subcategory. |
Referenced models: Batch insert events — response body — errors item errors item
Update a post — request body — body layout Sections value row Meta Data item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
cssClass | string | Required within parent | The CSS class applied to the row. |
styles | Model | Required within parent | Expand Update a post — request body — body layout Sections value styles |
Referenced models: Update a post — request body — body layout Sections value styles
Policy, approvals and errors
Section titled “Policy, approvals and errors”SDK function policy ID: hubspot.blog_posts_batch_update_posts. Catalog operation: blog_posts_batch_update_posts. Rules can name either ID; function rules distinguish managed calls and conservatively cover raw calls sharing the route. Existing grant permissions and policy rules apply. wait() returns an immediate result or waits for a required approval; it never approves the request itself. Persist the approval ID to resume after a restart.
Provider errors retain their response; JSON decoding raises ProviderAPIError for provider failures. ManagedOperationError identifies contract/input/retention errors. See error handling and provider-specific behavior. Sensitive input may be refused before approval storage. A decoding error never resubmits a write.
Required provider scopes: ["content"]