Notion: Retrieve a view
Notion views.retrieveAView: arguments, response, policy and SDK examples.
← Views operations · Get started
Operation notion.retrieve_a_view
Provider route: GET /v1/views/{view_id}. Alter supplies the connection’s credentials and routing.
Call through Alter
Section titled “Call through Alter”Install @alter-ai/sdk @alter-ai/notion with npm, or alter-sdk-notion with pip. Supply your connected customer’s grant ID and the arguments described below.
import { App } from "@alter-ai/sdk";import { NotionIntegration } from "@alter-ai/notion";
async function execute(input: Parameters<NotionIntegration["views"]["retrieveAView"]>[0]) { const app = new App({ apiKey: process.env.ALTER_API_KEY! }); try { const provider = new NotionIntegration(app, { grantId: process.env.PROVIDER_GRANT_ID! }); const call = await provider.views.retrieveAView(input); const result = await call.wait(); return result.bodyJson(); } finally { await app.close(); }}import osfrom alter_sdk import Appfrom alter_sdk_notion import NotionIntegration
async def execute(arguments): async with App(api_key=os.environ["ALTER_API_KEY"]) as app: provider = NotionIntegration(app, {"grant_id": os.environ["PROVIDER_GRANT_ID"]}) call = await provider.views.retrieve_a_view(arguments) result = await call.wait() return result.body_json()| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: not allowed |
path | object | Required within parent | Additional keys: not allowed |
path.view_id | string | Required within parent | ID of a Notion view. |
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 Delete a view — response body |
$ (anyOf 2) | Model | Alternative | Expand Retrieve a view — response body — object view |
Referenced models: Retrieve a view — response body — object view, Delete a view — response body
Schemas
Section titled “Schemas”39 more schemas are linked from the tables above, on the schema pages.
Retrieve a view — response body — object view
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: allowed |
configuration | JSON | Optional | View presentation configuration. |
configuration (anyOf 1) | Model | Alternative | Expand Retrieve a view — response body — object view configuration value |
configuration (anyOf 2) | null | Alternative | |
created_by | JSON | Optional | The user who created the view, or null if not available. |
created_by (anyOf 1) | Model | Alternative | Expand Update page — response body — object page created by |
created_by (anyOf 2) | null | Alternative | |
created_time | string | Required within parent | The time when the view was created. Format: date-time |
dashboard_view_id | string | Optional | For dashboard widget views, the ID of the parent dashboard view. Only present when this view is a widget inside a dashboard. |
data_source_id | JSON | Optional | The ID of the data source this view is scoped to, or null for dashboard views. |
data_source_id (anyOf 1) | string | Alternative | |
data_source_id (anyOf 2) | null | Alternative | |
filter | JSON | Optional | The filter applied to this view (same shape as data source query filter). |
filter (anyOf 1) | Model | Alternative | Expand Retrieve a view — response body — object view filter value |
filter (anyOf 2) | null | Alternative | |
id | string | Required within parent | The ID of the view. Format: uuid |
last_edited_by | JSON | Optional | The user who last edited the view, or null if not available. |
last_edited_by (anyOf 1) | Model | Alternative | Expand Update page — response body — object page created by |
last_edited_by (anyOf 2) | null | Alternative | |
last_edited_time | string | Required within parent | The time when the view was last edited. Format: date-time |
name | string | Required within parent | The name of the view. |
object | string | Required within parent | The object type name. Must equal: view |
parent | Model | Required within parent | Expand Delete a view — response body — parent The parent database of the view. |
quick_filters | JSON | Optional | Quick filters pinned to the view's filter bar. Keys are property IDs. Values are filter conditions (same shape as a property filter without the property field). Null when no quick filters are set. |
quick_filters (anyOf 1) | object | Alternative | Additional keys: see wildcard field |
quick_filters (anyOf 1).* | Model | Additional keys | Expand Retrieve a view — response body — object view quick filters object value |
quick_filters (anyOf 2) | null | Alternative | |
sorts | JSON | Optional | The sorts applied to this view (same shape as data source query sorts). |
sorts (anyOf 1) | array | Alternative | Maximum items: 100 |
sorts (anyOf 1)[] | Model | Each item | Expand Retrieve a view — response body — object view sorts array item |
sorts (anyOf 2) | null | Alternative | |
type | string | Required within parent | The view type. Known values: table, board, list, calendar, timeline, gallery, form, chart, map, dashboard |
url | string | Required within parent | Canonical deep link to the view in Notion. |
Referenced models: Delete a view — response body — parent, Update page — response body — object page created by, Retrieve a view — response body — object view quick filters object value, Retrieve a view — response body — object view configuration value, Retrieve a view — response body — object view filter value, Retrieve a view — response body — object view sorts array item
Delete a view — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: allowed |
id | string | Required within parent | The ID of the view. Format: uuid |
object | string | Required within parent | The object type name. Must equal: view |
parent | Model | Required within parent | Expand Delete a view — response body — parent The parent database of the view. |
type | string | Required within parent | The view type. Known values: table, board, list, calendar, timeline, gallery, form, chart, map, dashboard |
Referenced models: Delete a view — response body — parent
Delete a view — response body — parent
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: allowed |
database_id | string | Required within parent | The ID of the parent database. Format: uuid |
type | string | Required within parent | The parent type. Must equal: database_id |
Update page — response body — object page created by
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: allowed |
id | string | Required within parent | Format: uuid |
object | string | Required within parent | Always `user` Must equal: user |
Retrieve a view — response body — object view quick filters object value
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A property filter condition. Same shape as a property filter but without the "property" field. For example: { "select": { "equals": "High" } }. An empty object means the quick filter has no criteria yet. |
Retrieve a view — response body — object view filter value
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | JSON | Root | Filter for the view. Can be a property filter (filter by property value), timestamp filter (filter by created_time or last_edited_time), or compound filter (combine filters with and/or logic). Compound filters support up to 2 levels of nesting. |
$ (anyOf 1) | object | Alternative | A filter condition on a specific property. The property field specifies which property to filter, and an additional field specifies the filter type and condition (e.g., title, rich_text, number, checkbox, select, multi_select, date, people, files, relation, formula, rollup, etc.). Additional keys: allowed |
$ (anyOf 1).property | string | Required within parent | The name or ID of the property to filter on. |
$ (anyOf 2) | object | Alternative | A filter condition on a timestamp (created_time or last_edited_time). The timestamp field specifies which timestamp, and a matching field contains the date filter condition. Additional keys: allowed |
$ (anyOf 2).timestamp | string | Required within parent | The timestamp to filter on. Known values: created_time, last_edited_time |
$ (anyOf 3) | object | Alternative | A compound filter that combines multiple filters with AND or OR logic. Supports up to 2 levels of nesting. |
$ (anyOf 3).and | array | Optional | Filters combined with AND logic. |
$ (anyOf 3).and[] | JSON | Each item | A filter that can be a property filter, timestamp filter, or nested compound filter. |
$ (anyOf 3).and[] (anyOf 1) | object | Alternative | A filter condition on a specific property. The property field specifies which property to filter, and an additional field specifies the filter type and condition (e.g., title, rich_text, number, checkbox, select, multi_select, date, people, files, relation, formula, rollup, etc.). Additional keys: allowed |
$ (anyOf 3).and[] (anyOf 1).property | string | Required within parent | The name or ID of the property to filter on. |
$ (anyOf 3).and[] (anyOf 2) | object | Alternative | A filter condition on a timestamp (created_time or last_edited_time). The timestamp field specifies which timestamp, and a matching field contains the date filter condition. Additional keys: allowed |
$ (anyOf 3).and[] (anyOf 2).timestamp | string | Required within parent | The timestamp to filter on. Known values: created_time, last_edited_time |
$ (anyOf 3).and[] (anyOf 3) | Model | Alternative | Expand Retrieve a view — response body — object view filter value and, or or item and, or |
$ (anyOf 3).or | array | Optional | Filters combined with OR logic. |
$ (anyOf 3).or[] | JSON | Each item | A filter that can be a property filter, timestamp filter, or nested compound filter. |
$ (anyOf 3).or[] (anyOf 1) | object | Alternative | A filter condition on a specific property. The property field specifies which property to filter, and an additional field specifies the filter type and condition (e.g., title, rich_text, number, checkbox, select, multi_select, date, people, files, relation, formula, rollup, etc.). Additional keys: allowed |
$ (anyOf 3).or[] (anyOf 1).property | string | Required within parent | The name or ID of the property to filter on. |
$ (anyOf 3).or[] (anyOf 2) | object | Alternative | A filter condition on a timestamp (created_time or last_edited_time). The timestamp field specifies which timestamp, and a matching field contains the date filter condition. Additional keys: allowed |
$ (anyOf 3).or[] (anyOf 2).timestamp | string | Required within parent | The timestamp to filter on. Known values: created_time, last_edited_time |
$ (anyOf 3).or[] (anyOf 3) | Model | Alternative | Expand Retrieve a view — response body — object view filter value and, or or item and, or |
Referenced models: Retrieve a view — response body — object view filter value and, or or item and, or
Retrieve a view — response body — object view / sorts / array / item / direction: ascending, descending
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: allowed |
direction | string | Required within parent | Sort direction. Known values: ascending, descending |
property | string | Required within parent | The name or ID of the property to sort by. |
Policy, approvals and errors
Section titled “Policy, approvals and errors”SDK function policy ID: notion.retrieve_a_view. Catalog operation: retrieve_a_view. 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.
Pinned headers: {"Notion-Version": "2026-03-11"}