Notion UpdateTrigger

Notion UpdateTrigger

Certified

React to Notion page updates

Polls the Notion Search API at the configured interval. On each evaluation it collects all pages whose last_edited_time is strictly greater than the watermark (taken from TriggerContext.date, which is the last evaluation timestamp). When at least one updated page is found, a flow execution is fired; otherwise the trigger is silent and waits for the next interval.

Optional query narrows the search server-side using Notion full-text search. Optional parentPageId retains only pages that are direct children of that parent page (client-side filter, because the Notion Search API does not expose a server-side parent filter).

yaml
type: io.kestra.plugin.notion.page.UpdateTrigger

Trigger on any Notion page update every 5 minutes

yaml
id: notion_page_updated
namespace: company.team

tasks:
  - id: log_updated_pages
    type: io.kestra.plugin.core.log.Log
    message: "Updated pages: {{ trigger.updatedPages }}"

triggers:
  - id: watch_pages
    type: io.kestra.plugin.notion.page.UpdateTrigger
    apiToken: "{{ secret('NOTION_API_TOKEN') }}"
    interval: PT5M

Trigger only for pages matching a keyword search

yaml
id: notion_keyword_page_updated
namespace: company.team

tasks:
  - id: process_pages
    type: io.kestra.plugin.core.log.Log
    message: "Sprint pages updated: {{ trigger.updatedPages }}"

triggers:
  - id: watch_sprint_pages
    type: io.kestra.plugin.notion.page.UpdateTrigger
    apiToken: "{{ secret('NOTION_API_TOKEN') }}"
    query: "Sprint"
    interval: PT10M

Trigger only for pages under a specific parent page

yaml
id: notion_child_page_updated
namespace: company.team

tasks:
  - id: handle_update
    type: io.kestra.plugin.core.log.Log
    message: "Child page updated: {{ trigger.updatedPages }}"

triggers:
  - id: watch_child_pages
    type: io.kestra.plugin.notion.page.UpdateTrigger
    apiToken: "{{ secret('NOTION_API_TOKEN') }}"
    parentPageId: "12345678-1234-1234-1234-123456789abc"
    interval: PT15M
Properties

Notion API token

The Notion internal integration token used to authenticate API requests.

Defaultfalse

Specifies whether a trigger is allowed to start a new execution even if a previous run is still in progress.

DefaultPT5M
Formatduration

Interval between polls

ISO 8601 duration. A minimum of PT30S is recommended to avoid overloading the Notion API.

HTTP client configuration

Definitions
allowFailedbooleanstring
Defaultfalse

If true, allow a failed response code (response code >= 400)

allowedResponseCodesarray
SubTypeinteger

List of response code allowed for this request

auth

The authentication to use.

type*object
passwordstring

The password for HTTP basic authentication.

usernamestring

The username for HTTP basic authentication.

type*object
tokenstring

The token for bearer token authentication.

type*object
passwordstring

The password for HTTP Digest authentication.

usernamestring

The username for HTTP Digest authentication.

defaultCharsetstring
DefaultUTF-8

The default charset for the request.

enabledTcpExtendedKeepAlivebooleanstring
Defaulttrue

Whether to enable TCP Keep-Alive extended socket options (TCP_KEEPIDLE, TCP_KEEPINTERVAL, TCP_KEEPCOUNT).

Set to false when running on Windows workers, as these extended socket options are not supported by the Windows JDK and will cause connection failures.

followRedirectsbooleanstring
Defaulttrue

Whether redirects should be followed automatically.

logsarray
SubTypestring
Possible Values
REQUEST_HEADERSREQUEST_BODYRESPONSE_HEADERSRESPONSE_BODY

The enabled log.

proxy

The proxy configuration.

addressstring

The address of the proxy server.

passwordstring

The password for proxy authentication.

portintegerstring

The port of the proxy server.

typestring
DefaultDIRECT
Possible Values
DIRECTHTTPSOCKS

The type of proxy to use.

usernamestring

The username for proxy authentication.

ssl

The SSL request options

insecureTrustAllCertificatesbooleanstring

Whether to disable checking of the remote SSL certificate.

Only applies if no trust store is configured. Note: This makes the SSL connection insecure and should only be used for testing. If you are using a self-signed certificate, set up a trust store instead.

timeout

The timeout configuration.

connectTimeoutstring

The time allowed to establish a connection to the server before failing.

readIdleTimeoutstring
DefaultPT5M

The time allowed for a read connection to remain idle before closing it.

Parent page ID filter

Optional Notion page UUID. When set, only pages whose direct parent is this page are reported. This is a client-side filter applied after the API response because the Notion Search API does not expose a server-side parent filter.

Full-text search query

Optional text passed as the query field of the Notion Search API request. Narrows results server-side to pages whose title or content matches the search terms.

SubTypestring
Possible Values
CREATEDSUBMITTEDRUNNINGPAUSEDRESTARTEDKILLINGSUCCESSWARNINGFAILEDKILLEDCANCELLEDQUEUEDRETRYINGRETRIEDSKIPPEDBREAKPOINTRESUBMITTED

List of execution states after which a trigger should be stopped (a.k.a. disabled).

Defaulttrue

A condition that determines whether the trigger should run.

A Pebble expression evaluated at trigger time. The trigger fires only when the expression evaluates to a truthy value (true, a non-empty string, a non-zero number). Use this to gate trigger execution on dynamic runtime values such as execution labels, flow variables, or environment conditions.

Updated pages

The list of Notion pages that were updated since the last trigger evaluation.

Definitions
lastEditedTimestring
Formatdate-time

Last edited time

The timestamp when the page was last edited.

pageIdstring

Page ID

The unique identifier of the updated Notion page.

titlestring

Page title

The title of the updated page, or null if the title could not be extracted.

urlstring

Page URL

The URL of the updated page in Notion.