Skip to content

CAP-PFM-QRY-005Provide a customer with a tailored dataset

Markdown

CAP-PFM-QRY-005

Provide a customer with a tailored dataset

Markdown
  • DocumentDraft
  • Product intentProposed
  • ImplementationObserved

KindCapabilityProduct areaPlatformModuleQuestions, record exploration and data deliveryRevision1

Read atservices-platform ad3f6a65react-console baf6dae3

The Formal Contract

The narrative above explains; the sections below are authoritative — the rules, scenarios and tests this document binds.

Outcomes
Selected customers receive a tailored dataset.Publication checks identify affected saved questions.Reader permissions still govern custom data.
Surfaces
consoleapi
Intent sources
services-platform:docs/queries/custom-query-tables/rhythm-custom-query-tables-architecture.md#Status (Phase 1 accepted by Andrew on 2026-10-12)

Controls

31 controls apply, from the corpus control catalogue.

TC-AVL-005 TC-AZ-001 TC-AZ-002 TC-AZ-003 TC-AZ-004 TC-AZ-005 TC-AZ-006 TC-CRY-001 TC-CRY-002 TC-CRY-003 TC-CRY-004 TC-IAM-001 TC-IAM-002 TC-IAM-003 TC-IAM-004 TC-IAM-005 TC-LOG-001 TC-LOG-002 TC-LOG-003 TC-LOG-004 TC-LOG-005 TC-MON-001 TC-PI-001 TC-PI-003 TC-PI-005 TC-TEN-001 TC-TEN-002 TC-TEN-003 TC-VEN-001 TC-VEN-002 TC-VEN-003

Permissions

KeyChecked atScope
hq.custom-query-tables.readapiglobal
hq.custom-query-tables.authorapiglobal
hq.custom-query-tables.publishapiglobal
hq.custom-query-tables.assignapiglobal

Business Rules

16 rules, 16 to be proved before approval. A rule's product intent is derived from its origin: 0 confirmed by a product decision, the rest inheriting this capability's proposed.

IdRuleKindEnforced atProvenance
01must prove
Proposed
Staff permissions separately govern custom-table reading, drafting and preview, publication and lifecycle changes, and assignment; customer users cannot reach these routes and authoring does not grant publication.
permissionapitest
services-platform:modules/queries/tests/e2e/custom-tables.e2e.spec.js#is refused to a caller who may author but not publish, the two being separate keys
02must prove
Proposed
A custom-table identity cannot be reused for a second definition.
validationservice, databasetest
services-platform:modules/queries/tests/e2e/custom-tables.e2e.spec.js#refuses a second definition under the same id, an id being permanent and never reused
03must prove
Proposed
Draft analysis checks permitted read behaviour, identifies source access requirements and proposes output fields, returning rejected statements as analysis problems.
validationservicetest
services-platform:modules/queries/tests/e2e/custom-tables.e2e.spec.js#answers a statement the rules refuse as 200 and its problems, an analysis being data and not an error
04must prove
Proposed
Custom definitions accept only supported platform placeholders and reject user-declared parameters or unknown placeholders.
origin: services-platform:docs/queries/semantic-query-layer.md#A value asked for when a saved query runs (`$parameter`, 2026-10-13) (Andrew, 2026-10-13)
validationservicetest
services-platform:modules/queries/tests/e2e/custom-tables.e2e.spec.js#refuses a draft that declares parameters as 400, a definition taking only the platform's own placeholders
05must prove
Proposed
Analysis, draft validation, publication and preview use the configured validation workspace; absent configuration leaves reads available but returns unavailable for those operations, and another workspace cannot be previewed.
policyservicetest
services-platform:modules/queries/tests/e2e/custom-tables.e2e.spec.js#refuses a preview of any other tenant, a customer’s rows needing a staff access grant there is no way to hold
06must prove
Proposed
A breaking publication waits for acknowledgment of every affected saved query and otherwise returns the changes and dependent query identities.
policyservicetest
services-platform:modules/queries/tests/e2e/custom-tables.e2e.spec.js#refuses the publish as 409 rather than breaking the query quietly
07must prove
Proposed
Assigned active publications appear in the dataset catalog; deprecated publications still resolve and disabled publications produce an explicit execution refusal.
policyserviceobserved
08must prove
Proposed
A custom dataset requires every permission its statement reads, marks readers without them unauthorized, and refuses execution with the missing permission identified.
permissionservicedocumented
services-platform:docs/queries/semantic-query-layer.md#14.2 What resolves a custom dataset
09must prove
Proposed
Pins reference published versions, with the most specific covering pin taking precedence; unpinned grants preserve broader pins, and clearing a pin follows another covering pin or the latest publication.
lifecycleserviceobserved
10must prove
Proposed
Deprecation removes a custom dataset from selection lists while preserving execution, whereas disabling it refuses execution with a reason.
lifecycleservicetest
services-platform:modules/queries/tests/e2e/custom-tables.e2e.spec.js#disables it, which refuses a run of it rather than answering nothing
11must prove
Proposed
A published statement whose stored fingerprint no longer matches is refused without exposing statement text.
invariantservicedocumented
services-platform:docs/queries/semantic-query-layer.md#14.2 What resolves a custom dataset
12must prove
Proposed
Custom-table history attributes lifecycle actions to their actors without retaining statement text or record values.
invariantservicetest
services-platform:modules/queries/tests/e2e/custom-tables.e2e.spec.js#keeps no statement and no value of the data in the history, which is what it is allowed to carry
13must prove
Proposed
An assigned custom table’s reference exposes a reverse one-to-many relationship from its referenced dataset only in workspaces covered by the assignment.
policyservicetest
services-platform:modules/queries/tests/e2e/custom-tables.e2e.spec.js#is refused the join by the tenant no assignment names, the definition not being a dataset there
14must prove
Proposed
Changes to definitions, drafts and assignments must use their read versions, and stale versions are rejected.
validationservicetest
services-platform:modules/queries/tests/e2e/custom-tables.e2e.spec.js#refuses a save at a version somebody else has moved on from as 409
15must prove
Proposed
Revalidation revisits active or deprecated publications and pinned versions, records meaningful health changes without statement text or data, limits repeated passing history to once daily, and skips without a validation workspace.
lifecycleserviceobserved
16must prove
Proposed
Analysis rejects statements that write or lock records, contain recursion, use forbidden schemas or functions, or fail the single permitted-read requirement.
validationserviceobserved

Scenarios

IdGivenWhenThenProvenance
01Rhythm staff publish an organization-count definition assigned to one customer.That customer lists and executes its new dataset.The definition is available and returns only the workspace’s own organizations.test
services-platform:modules/queries/tests/e2e/custom-tables.e2e.spec.js#runs it and answers rows of the tenant’s own organizations

The Markdown files under specs/ in rhythmsoftware/rhythm-v2-docs are the canonical source of truth. This reader is a generated, read-only projection of them.