Skip to content

js-bao-wss-client


js-bao-wss-client / TestRuleSetParams

Interface: TestRuleSetParams ​

Simulated request parameters for ruleSets.test(): the category and operation to evaluate, plus a fully synthetic user/group context to evaluate the rules against.

Properties ​

category ​

category: string

The resource category being accessed (e.g., "members", "documents")


group? ​

optional group?: object

The group context for group-scoped rule evaluation

createdBy ​

createdBy: string

groupId ​

groupId: string

groupType ​

groupType: string

name ​

name: string


memberships? ​

optional memberships?: object[]

Group memberships to simulate for the user

groupId ​

groupId: string

groupType ​

groupType: string


operation ​

operation: string

The operation being performed (e.g., "read", "write", "delete")


record? ​

optional record?: Record<string, unknown>

Arbitrary record data to evaluate field-level rules against


target? ​

optional target?: object

The target user of the operation, if applicable

userId ​

userId: string


user ​

user: object

The simulated user performing the action, with userId and optional role

role? ​

optional role?: string

userId ​

userId: string

Documentation validated against js-bao-wss-client 3.4.0 · js-bao 0.11.0 · primitive-admin 1.0.62 · primitive-app 3.1.0 — 2026-09-30