List saved views of a surface
Returns the caller's saved views of one surface as paged summaries (id, name, position) with the active view key. The All view (__all__) is the surface's own personalization and is not listed; read it with viewKey __all__. Narrow with query by view id or name.
Requires: read access to the surface's page: read access to the record type for a records:<typeId> surface, read on users for Members and Roles, read all on api for Webhooks, read all on activityLog for Activity, read on routines for Routines, and read on inboxMessages plus the messaging entitlement for Inbox. Dashboard and record timeline views need no extra permission. Saved views are personal: only the caller's own views are listed or changed.
Authorization
apiKeyAuth API key authentication. Create an API key in your user profile and include it in the x-api-key header.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://customermates.com/api/v1/data-views/list" \ -H "Content-Type: application/json" \ -d '{ "surfaceKey": "dashboard", "page": 1, "pageSize": 10 }'{
"action": "surfaces",
"surfaceKey": "users-card-store",
"label": "string",
"path": "string",
"section": "overview",
"total": 9007199254740991,
"page": 1,
"pageSize": 1,
"totalPages": 1,
"items": [
{
"id": "string",
"surfaceKey": "users-card-store",
"name": "string",
"label": "string",
"path": "string",
"position": -9007199254740991,
"state": {
"filters": [
{
"field": "string",
"operator": "equals",
"value": "string"
}
],
"searchTerm": "string",
"sortDescriptor": {
"field": "string",
"direction": "asc"
},
"pageSize": 5,
"viewMode": "table",
"grouping": {
"field": "string",
"bucket": "day",
"hidden": [
"string"
],
"hideEmpty": true,
"summaries": [
{
"fieldId": "84922011-b03d-4966-bc95-c5b49bc2e342",
"aggregation": "sum"
}
]
},
"columnOrder": [
"string"
],
"columnWidths": {
"property1": 0,
"property2": 0
},
"hiddenColumns": [
"string"
],
"calendar": {
"dateFieldId": "0e1d975e-73f3-487e-ac80-14e9e130620e",
"endDateFieldId": "258b375b-74ed-4b5e-99a1-3f54c6fea6e5",
"colorFieldId": "fb3508bd-25c6-4412-a3bc-eb958a7aa449",
"mode": "month"
}
},
"field": "string",
"operators": [
"string"
],
"property1": null,
"property2": null
}
],
"totals": {
"property1": 9007199254740991,
"property2": 9007199254740991
},
"supportsSearch": true,
"viewModes": [
"table"
],
"writableStateFields": [
"string"
],
"activeViewKey": "string",
"allState": {
"filters": [
{
"field": "string",
"operator": "equals",
"value": "string"
}
],
"searchTerm": "string",
"sortDescriptor": {
"field": "string",
"direction": "asc"
},
"pageSize": 5,
"viewMode": "table",
"grouping": {
"field": "string",
"bucket": "day",
"hidden": [
"string"
],
"hideEmpty": true,
"summaries": [
{
"fieldId": "84922011-b03d-4966-bc95-c5b49bc2e342",
"aggregation": "sum"
}
]
},
"columnOrder": [
"string"
],
"columnWidths": {
"property1": 0,
"property2": 0
},
"hiddenColumns": [
"string"
],
"calendar": {
"dateFieldId": "0e1d975e-73f3-487e-ac80-14e9e130620e",
"endDateFieldId": "258b375b-74ed-4b5e-99a1-3f54c6fea6e5",
"colorFieldId": "fb3508bd-25c6-4412-a3bc-eb958a7aa449",
"mode": "month"
}
},
"viewKey": "__all__",
"id": "string",
"name": "string",
"position": -9007199254740991,
"state": {
"filters": [
{
"field": "string",
"operator": "equals",
"value": "string"
}
],
"searchTerm": "string",
"sortDescriptor": {
"field": "string",
"direction": "asc"
},
"pageSize": 5,
"viewMode": "table",
"grouping": {
"field": "string",
"bucket": "day",
"hidden": [
"string"
],
"hideEmpty": true,
"summaries": [
{
"fieldId": "84922011-b03d-4966-bc95-c5b49bc2e342",
"aggregation": "sum"
}
]
},
"columnOrder": [
"string"
],
"columnWidths": {
"property1": 0,
"property2": 0
},
"hiddenColumns": [
"string"
],
"calendar": {
"dateFieldId": "0e1d975e-73f3-487e-ac80-14e9e130620e",
"endDateFieldId": "258b375b-74ed-4b5e-99a1-3f54c6fea6e5",
"colorFieldId": "fb3508bd-25c6-4412-a3bc-eb958a7aa449",
"mode": "month"
}
},
"link": "string",
"selected": true,
"deleted": true,
"proposed": true,
"trashBatchId": "f9ad794f-414e-4d2a-bff7-4eedbaa196bb",
"property1": null,
"property2": null
}{
"error": {
"kind": "validation",
"issues": [
{
"code": "string",
"path": [
"string"
],
"message": "string",
"customCode": "recordNotFound",
"entitlement": "string"
}
],
"retryable": true
}
}{
"error": {
"kind": "validation",
"issues": [
{
"code": "string",
"path": [
"string"
],
"message": "string",
"customCode": "recordNotFound",
"entitlement": "string"
}
],
"retryable": true
}
}{
"error": {
"kind": "validation",
"issues": [
{
"code": "string",
"path": [
"string"
],
"message": "string",
"customCode": "recordNotFound",
"entitlement": "string"
}
],
"retryable": true
}
}{
"error": {
"kind": "validation",
"issues": [
{
"code": "string",
"path": [
"string"
],
"message": "string",
"customCode": "recordNotFound",
"entitlement": "string"
}
],
"retryable": true
}
}{
"error": {
"kind": "validation",
"issues": [
{
"code": "string",
"path": [
"string"
],
"message": "string",
"customCode": "recordNotFound",
"entitlement": "string"
}
],
"retryable": true
}
}{
"error": {
"kind": "validation",
"issues": [
{
"code": "string",
"path": [
"string"
],
"message": "string",
"customCode": "recordNotFound",
"entitlement": "string"
}
],
"retryable": true
}
}{
"error": {
"kind": "validation",
"issues": [
{
"code": "string",
"path": [
"string"
],
"message": "string",
"customCode": "recordNotFound",
"entitlement": "string"
}
],
"retryable": true
}
}