API Playground

Set or clear the view your entities grid opens on. This playground calls the live API and will modify your preferences.

Authentication Required

You need to Login to test the API playground

Set last-active view

Remember which view the current user applied last, so the entities grid opens on it next time.

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

This is a per-user preference. When the grid opens without an explicit view in the URL, it loads the last-active view; if that view was deleted or is no longer visible, it falls back to the default grid. The preference is also returned in the authenticated user payload (preferences.entities_last_active_view_id).

Body parameters

ParameterTypeRequiredDescription
view_idstring|nullRequiredA view the caller can see (their own, or any shared view in the brand), or null to clear the preference. The key must be present even when the value is null.

Request Examples

Set the last-active view
curl -X POST "https://api.commerceclarity.com/api/2026-05/entities/views/last-active" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -d '{ "view_id": "664f1a2b3c4d5e6f7a8b9c0d" }'
Clear it
curl -X POST "https://api.commerceclarity.com/api/2026-05/entities/views/last-active" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -d '{ "view_id": null }'

Response Example

Success Response
{
  "status": "success"
}

Errors

TriggerStatusMessage
view_id is not a view the caller can see in the brand404View not found.
view_id is missing from the body422The validation message.