Skip to Content

Stores

A Store is a low-latency serving cache populated from your warehouse models. Use Stores when decisioning systems — web personalization, edge functions, ad bidders — need attribute lookups in milliseconds rather than warehouse round-trip times.

Model to Store sync to Store to Stores API

How Stores Work

  1. You define one or more Store syncs that map a model’s columns into a named Store, running in mirror mode on a schedule.
  2. Each sync run writes (or removes) the mapped fields for every row in the model into the Store, keyed by the row’s id value.
  3. Multiple syncs can compose a single Entry — each sync owns a disjoint set of fields.
  4. Your application queries the Stores API at GET /v1/stores/{store}/entries/id/{value} to read the merged attribute set for any id in low-tens-milliseconds.

Prerequisites

  • A configured warehouse and at least one Model with an id column.
  • A read:store API key (issued from the Store detail page).

Creating a Store

  1. Navigate to Stores in the left sidebar.
  2. Click New Store.
  3. Enter a Store name (lowercase letters, numbers, and hyphens only; must start with a letter).
  4. Click Create Store.

Adding a Store Sync

A Store sync connects a model to the Store and maps which fields to write.

  1. Open the Store and click Add sync.
  2. Select the Model to sync.
  3. Configure the Field mapping: choose which model columns to write as Entry fields. The id column is always the Entry key and cannot be remapped.
  4. Set the Deletion behavior for this sync (see Deletion behavior below).
  5. Set the Schedule (e.g., Every 1 hour).
  6. Click Save.

Composed Entries

Multiple syncs can write to the same Store. Each sync owns its mapped fields exclusively — a field written by sync A cannot be mapped by sync B. On each run, the sync updates only its owned fields. The Stores API returns the union of all syncs’ fields as a single JSON object.

Deletion Behavior

When a row is removed from the model (and mirror mode detects the deletion), each sync decides independently what to do with its owned fields:

SettingBehavior
do_nothingOwned fields are left in the Store untouched.
clear_mineOwned fields are removed from the Entry. If another sync still owns fields, the Entry remains (without this sync’s fields).
clear_and_gcOwned fields are removed. If no fields remain after removal, the Entry itself is deleted (returns 404).

Stores API

Query a Store entry by id using a Bearer API key with the read:store scope.

Endpoint

GET /v1/stores/{store}/entries/id/{value}
ParameterDescription
storeThe Store name (as created in the UI).
valueThe id value to look up.

Authentication

Pass your read:store API key as a Bearer token:

curl https://composable.zeotap.com/v1/stores/my-store/entries/id/user-123 \ -H "Authorization: Bearer <your-api-key>"

Response

A 200 OK with the merged Entry fields as a JSON object:

{ "plan": "pro", "tier": "gold", "loyalty_points": 4200, "first_name": "Alex" }

Returns 404 when the id does not exist in the Store (or all fields have been cleared by clear_and_gc deletions).

Error responses

StatusMeaning
401 UnauthorizedMissing or invalid Bearer token.
403 ForbiddenAPI key does not have the read:store scope.
404 Not FoundNo Entry found for the given id.
429 Too Many RequestsRate limit exceeded; retry after the Retry-After header value (seconds).

Issuing a read:store API Key

  1. Open the Store in the UI.
  2. Click Issue API key.
  3. Copy the key immediately — it is shown only once.

Each key is scoped to read:store and is tied to your workspace. Revoke keys from the same page.

Next Steps

Last updated on