If a function fails, this property will contain the last error as a string message, otherwise it will be
If a function succeeds, this property will contain the last response returned by Notion. The JSON returned by Notion will be parsed to an object and placed in this property. Refer to Notion API documentation for details on the contents of this object based on call made.
Release version of the Notion API to target. Default is "2022-02-22". If you need capabilities not available in a particular version, you can override the value. See Notion's versioning docs for details.
Execute a request against the Notion API. For successful requests, the HTTPResponse object will contain an object or array or objects decoded from the JSON returned by Notion as appropriate to the request made. Refer to Notion's API documentation for details about the expected parameters and responses. Drafts will handle wrapping the request in the appropriate OAuth authentication flow.
an object configuring the request.
An object contain key-values to be added as custom headers in the request. There is no need to provide authorization headers, Drafts will add those. Drafts will automatically include required authentication and versioning headers.
The HTTP method, like "GET", "POST", etc.
An object containing key-values to be added to the request as URL parameters.
The full URL to the endpoint in the Notion REST API.
Creates a new Notion object.
Optional string value used to identify a Notion account. Typically this can be omitted if you only work with one Notion account in Drafts. Each unique identifier used for Notion accounts will share credentials - across both action steps and scripts.
Generated using TypeDoc
Script integration with Notion. This object handles OAuth authentication and request signing. The entire Notion REST API can be used with the