---
title: "Bulk update page messages."
method: PATCH
path: "/api/v1/projects/{projectId}/contextual-rag/messages"
tags: ["Webpage Awareness"]
---

# Bulk update page messages.

`PATCH /api/v1/projects/{projectId}/contextual-rag/messages`

## Request

- Base URL: `https://app.customgpt.ai`
- URL: `https://app.customgpt.ai/api/v1/projects/{projectId}/contextual-rag/messages`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/poll-the-people/apis/customgpt-ai/docs/api/v1/projects/:projectId/contextual-rag/messages/patch.ts> (a function with typed inputs; its response is checked against the schema)

Updates `auto_message` and/or `display_message` for one or more webpage context entries.
Requires the **Webpage Awareness** tool to be enabled on the agent.

## Path parameters

- `projectId` integer, required

## Request body

- object
  - `updates` object[], required: Array of page message updates. Each entry must include the page ID.
    - `id` string, required: The page ID in the Webpage Awareness service.
    - `auto_message` string, nullable: Auto-generated contextual message for the page. Maximum 500 characters.
    - `display_message` string, nullable: Custom display message shown to visitors on this page. Maximum 500 characters.

## Response `200`

Updated page context entries after bulk message update.

- object
  - `status` 'error' | 'success': The status of the response
  - `data` object
    - `updated_count` integer: Number of page context entries updated.

## Other responses

- `401`: API Token is either missing or invalid
- `403`: Webpage Awareness tool must be enabled to use this endpoint.
- `404`: Agent not found
- `429`: Too many requests. You have exceeded your API rate limit.
- `500`: Internal Server Error

## Changes

- **2026-11-03** `77aab4354382`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/poll-the-people/apis/customgpt-ai/changes/api/v1/projects/:projectId/contextual-rag/messages/patch.md)

---

[API](https://skmtc.dev/poll-the-people/apis/customgpt-ai.md) - [All operations](https://skmtc.dev/poll-the-people/apis/customgpt-ai/llms.txt) - [OpenAPI document](https://skmtc.dev/poll-the-people/apis/customgpt-ai/revisions/77aab4354382?raw)
