Skip to main content
POST
/
v1
/
slices
curl --request POST \
  --url https://pnbr.io/v1/slices \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "Companies, last 30 days",
  "cql": "type:Company after:30d",
  "project_id": "9142fa4d-7aad-4a1b-8f99-b522fd37518d"
}
'
{
  "id": "522e9061-2ee0-46b5-8f2d-9c89ee729c7a",
  "name": "Alpha cos since Jan",
  "type": "dynamic",
  "matched": 18,
  "scope_warnings": [],
  "unresolved": {
    "shapes": [],
    "sources": []
  },
  "filter_definition": {
    "entityTypes": [
      "Company"
    ],
    "propertyFilters": [
      {
        "path": "stage",
        "operator": "eq",
        "value": "alpha"
      }
    ],
    "dateRange": {
      "field": "created_at",
      "start": "2026-01-01T00:00:00.000Z"
    }
  },
  "project_id": "9142fa4d-7aad-4a1b-8f99-b522fd37518d",
  "promoted": true,
  "created_at": "2026-06-16T05:08:19.400Z"
}

Authorizations

Authorization
string
header
required

A pnbr- API key. Project-scoped keys make project_id implicit; org-scoped keys require it.

Body

application/json

A developer-intent scope: a CQL string (cql) or a structured filter. Names, not UUIDs. cql is canonical if both are given.

name
string
required
cql
string

CQL filter string. Tokens: type:, shape:, source:, source-shape:, after:, before:. Same-kind tokens union, different-kind intersect. after:/before: accept absolute ISO (YYYY-MM-DD) OR relative expressions resolved server-side in UTC: last-week, last-month, last-year, today, yesterday, now, and signed offsets 7d, -7d, 2w, 3mo, 12h, 1y (sign ignored; past-only). Membership-irrelevant tokens (edge:, agent:, sort:, free text) come back in scope_warnings, never silently dropped.

Example:

"type:Company after:7d"

filter
object

Structured mirror of CQL.

project_id
string

Implicit from a project-scoped key or the X-Penumbra-Project header.

Response

Slice authored.