API Playground

Create a saved view. This playground calls the live API and will create data.

Authentication Required

You need to Login to test the API playground

Create view

Save a configuration of the entities grid as a new view, private or shared with the brand.

Endpoint URL
POST https://api.commerceclarity.com/api/2026-05/entities/views

The 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.

Body parameters

ParameterTypeRequiredDescription
namestringRequiredDisplay name, max 255 characters. Must not match a view the caller can see: see Name uniqueness.
definitionobjectRequiredGrid configuration. Only filters, sort and columns are kept; any other key is dropped. Their content is not validated by the server.
definition.filtersobject|nullOptionalFilter tree, as in List / Query entities.
definition.sortarrayOptional[{ "field": "...", "dir": "asc"|"desc" }]. Defaults to [].
definition.columnsarrayOptional[{ colId, visible, width?, pinned?, order }]. Defaults to []. See Columns and attributes.
visibilitystringOptionalprivate (default) or shared.
brand_idstringOptionalCreate the view in this brand instead of the active one.

Request Examples

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 }
      ]
    }
  }'

Response Example

Success Response — 201
{
  "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.

Errors

TriggerStatusMessage
name or definition missing or invalid, visibility not private / shared422The validation message.
The name is already used by a view the caller can see422A view with this name already exists.
visibility: "shared" without being a contributing member403You are not allowed to create a shared view in this brand.

Name uniqueness

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:

Error Response - Validation — 422
{
  "status": "error",
  "message": "A view with this name already exists.",
  "error_code": "view_name_taken"
}