Create a saved view. This playground calls the live API and will create data.
Save a configuration of the entities grid as a new view, private or shared with the brand.
POST https://api.commerceclarity.com/api/2026-05/entities/viewsThe new view is owned by the caller and appended to the end of its list: the caller's private views, or the brand's shared views. Creating a shared view requires a contributing member (brand admin or editor, the workspace owner, or CommerceClarity staff). See Visibility and permissions.
| Parameter | Type | Required | Description |
|---|---|---|---|
name | string | Required | Display name, max 255 characters. Must not match a view the caller can see: see Name uniqueness. |
definition | object | Required | Grid configuration. Only filters, sort and columns are kept; any other key is dropped. Their content is not validated by the server. |
definition.filters | object|null | Optional | Filter tree, as in List / Query entities. |
definition.sort | array | Optional | [{ "field": "...", "dir": "asc"|"desc" }]. Defaults to []. |
definition.columns | array | Optional | [{ colId, visible, width?, pinned?, order }]. Defaults to []. See Columns and attributes. |
visibility | string | Optional | private (default) or shared. |
brand_id | string | Optional | Create the view in this brand instead of the active one. |
curl -X POST "https://api.commerceclarity.com/api/2026-05/entities/views" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d '{
"name": "EU products missing weight",
"visibility": "shared",
"definition": {
"filters": {
"operator": "and",
"conditions": [
{ "field": "country", "op": "in", "value": ["it", "de", "fr"] },
{ "field": "attr.peso", "op": "is empty" }
]
},
"sort": [{ "field": "attr.cc_title", "dir": "asc" }],
"columns": [
{ "colId": "cc_title", "visible": true, "width": 240, "pinned": "left", "order": 0 },
{ "colId": "code", "visible": true, "width": 120, "pinned": null, "order": 1 }
]
}
}'
{
"status": "success",
"data": {
"_id": "664f1a2b3c4d5e6f7a8b9c0d",
"owner_user_id": "62b1f1a2b3c4d5e6f7a8b9c0",
"owner_email": "anna.rossi@example.com",
"name": "EU products missing weight",
"visibility": "shared",
"position": 3,
"definition": { ... },
...
}
}The full field list is in The view object.
| Trigger | Status | Message |
|---|---|---|
name or definition missing or invalid, visibility not private / shared | 422 | The validation message. |
| The name is already used by a view the caller can see | 422 | A view with this name already exists. |
visibility: "shared" without being a contributing member | 403 | You are not allowed to create a shared view in this brand. |
A name must be unique among the views the caller can see in the brand: their own views plus every shared view. Names are compared exactly (case-sensitive) after trimming surrounding spaces. A collision returns an error_code so a client can attach the error to the name field:
{
"status": "error",
"message": "A view with this name already exists.",
"error_code": "view_name_taken"
}