Skip to main content

Overview

Audit, block, or mask Notion AI chat prompts with Formal Endpoint. The HTTP policies leave ordinary edits, comments, and sync alone. To govern MCP tool calls instead, see Notion MCP.

1. Add a network rule

  1. Enable Transparent Mode and trust the Formal CA.
  2. Create this network rule and set it to Active. No Connector is required.
  3. Open Notion in your browser and in Notion Desktop. Confirm the app loads and the hostname appears in Logs.
The rule matches app.notion.com, www.notion.so, and their realtime and msgstore hosts, including numbered hosts like msgstore-001.app.notion.com. The policies below match AI POSTs on the two app hosts only. To restrict workspace access instead, see Notion’s network control guidance.

2. Policy examples

To scope a policy to one user, add input.user.email == "alice@example.com" to its request rule. Dry run logs policy decisions without enforcing them.

2.1 Audit prompt requests

Set this policy to Dry run. In Logs, filter for createAgentThread or sendEventToAgentThread. A matching request shows a dry-run block decision but still reaches Notion.

2.2 Block chat requests

Set this policy to Active to block new chats, follow-ups, and legacy inference. Notion may show its own error instead of the policy message.

2.3 Block requests containing sensitive data

This policy looks for emails, OpenAI and Anthropic key patterns, and AWS access key IDs. It scans the full body, including metadata.

2.4 Redact matching prompt text

This body rewrite replaces matching prompt text with [REDACTED] in new chats and follow-ups. It strips annotations from changed spans so links cannot carry the original value. It does not rewrite legacy inference requests. Start in Dry run. Activate redaction for one user and check the forwarded body in Logs. A block policy on the same request takes precedence.
To exclude original bodies from Logs, drop log.request.http.body.received in the Endpoint log schema. Policy inputs have separate retention settings.
Redaction and the raw-body block can miss values split across formatted text spans.

3. Verify on a pilot device

In Logs, check the policy decision and, for redaction, the forwarded body.

Reference: Notion AI request shapes

Each prompt span starts with a string and can include annotations such as links.

New chat

Follow-up message

Limitations

  • Private API: Notion can change request paths and payloads without notice.
  • Answers are not inspected: A follow-up request can return a disposition of steered. Notion can send the answer separately over its realtime sync channel. These policies block or redact prompts, not answers.
  • Logs show raw request JSON: When body logging is enabled, Logs show the HTTP body. Formal does not extract separate Notion AI prompt or answer fields as it does for ChatGPT, Claude, and Cursor.
  • Chat only: Inline Ask AI, AI blocks, database autofill, and meeting notes may use different request paths.
  • Shared writes: Some Notion clients can save a prompt through a shared transaction path before inference. These policies leave those writes alone.
  • Body capture: HTTP audit events have a shared body budget of about 500 KiB. Larger bodies can be truncated in Logs.
  • Workspace-wide stop: To stop AI across the workspace, disable Notion AI in Notion’s workspace settings where available.