dataStoreProvider
The dataStoreProvider router: 18 methods of the data-store-provider capability, with tier, scope, input and output.
Capability data-store-provider · scope system · mode collection · source packages/types/src/capabilities/data-store-provider.cap.ts:77.
Every method is called at /trpc/dataStoreProvider.<method> — queries with GET, mutations with POST. See How to call and Authorization.
| Method | Kind | Tier | Token scope | Viewer |
|---|---|---|---|---|
getEngineInfo | query | admin | admin only | no |
get | query | admin | admin only | no |
set | mutation | admin | admin only | no |
query | query | admin | admin only | no |
insert | mutation | admin | admin only | no |
upsert | mutation | admin | admin only | no |
upsertMany | mutation | admin | admin only | no |
insertMany | mutation | admin | admin only | no |
transact | mutation | admin | admin only | no |
update | mutation | admin | admin only | no |
delete | mutation | admin | admin only | no |
deleteWhere | mutation | admin | admin only | no |
updateWhere | mutation | admin | admin only | no |
count | query | admin | admin only | no |
aggregate | query | admin | admin only | no |
histogram | query | admin | admin only | no |
isEmpty | query | admin | admin only | no |
declareCollection | mutation | admin | admin only | no |
dataStoreProvider.getEngineInfo
- Kind: query —
GET /trpc/dataStoreProvider.getEngineInfo - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.getEngineInfoon your hub
Input
voidOutput
DataStoreEngineInfoSchemaShapes: DataStoreEngineInfoSchema
dataStoreProvider.get
- Kind: query —
GET /trpc/dataStoreProvider.get - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.geton your hub
Input
{ namespace?: string; collection: string; key: string }Output
unknowndataStoreProvider.set
- Kind: mutation —
POST /trpc/dataStoreProvider.set - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.seton your hub
Input
{ namespace?: string; collection: string; key: string; value: unknown }Output
voiddataStoreProvider.query
- Kind: query —
GET /trpc/dataStoreProvider.query - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.queryon your hub
Input
{ namespace?: string; collection: string; filter?: QueryFilterSchema; columns?: string[] }Output
SettingsRecordSchema[]Shapes: QueryFilterSchema · SettingsRecordSchema
dataStoreProvider.insert
- Kind: mutation —
POST /trpc/dataStoreProvider.insert - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.inserton your hub
Input
{ namespace?: string; collection: string; record: { id?: string; data: Record<string, unknown> } }Output
{ id: string | number }dataStoreProvider.upsert
- Kind: mutation —
POST /trpc/dataStoreProvider.upsert - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.upserton your hub
Input
{ namespace?: string; collection: string; conflict: string[]; record: BulkRecordSchema }Output
{ id: string | number }Shapes: BulkRecordSchema
dataStoreProvider.upsertMany
- Kind: mutation —
POST /trpc/dataStoreProvider.upsertMany - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.upsertManyon your hub
Input
{ namespace?: string; collection: string; conflict: string[]; records: BulkRecordSchema[] }Output
{ upserted: number }Shapes: BulkRecordSchema
dataStoreProvider.insertMany
- Kind: mutation —
POST /trpc/dataStoreProvider.insertMany - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.insertManyon your hub
Input
{ namespace?: string; collection: string; records: BulkRecordSchema[] }Output
{ inserted: number }Shapes: BulkRecordSchema
dataStoreProvider.transact
- Kind: mutation —
POST /trpc/dataStoreProvider.transact - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.transacton your hub
Input
{ namespace?: string; guard?: { collection: string; key: string; column: string; equals: unknown }; ops: ({ op: "deleteWhere"; collection: string; filter: MutationFilterSchema } | { op: "insertMany"; collection: string; records: BulkRecordSchema[] } | { op: "update"; collection: string; id: string; data: Record<string, unknown> } | { op: "upsertMany"; collection: string; conflict: string[]; records: BulkRecordSchema[] })[] }Output
{ applied: boolean; current?: unknown }Shapes: MutationFilterSchema · BulkRecordSchema
dataStoreProvider.update
- Kind: mutation —
POST /trpc/dataStoreProvider.update - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.updateon your hub
Input
{ namespace?: string; collection: string; id: string; data: Record<string, unknown> }Output
voiddataStoreProvider.delete
- Kind: mutation —
POST /trpc/dataStoreProvider.delete - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.deleteon your hub
Input
{ namespace?: string; collection: string; key: string }Output
voiddataStoreProvider.deleteWhere
- Kind: mutation —
POST /trpc/dataStoreProvider.deleteWhere - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.deleteWhereon your hub
Input
{ namespace?: string; collection: string; filter: MutationFilterSchema }Output
{ deleted: number }Shapes: MutationFilterSchema
dataStoreProvider.updateWhere
- Kind: mutation —
POST /trpc/dataStoreProvider.updateWhere - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.updateWhereon your hub
Input
{ namespace?: string; collection: string; filter: MutationFilterSchema; data: Record<string, unknown> }Output
{ updated: number }Shapes: MutationFilterSchema
dataStoreProvider.count
- Kind: query —
GET /trpc/dataStoreProvider.count - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.counton your hub
Input
{ namespace?: string; collection: string; filter?: QueryFilterSchema }Output
numberShapes: QueryFilterSchema
dataStoreProvider.aggregate
- Kind: query —
GET /trpc/dataStoreProvider.aggregate - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.aggregateon your hub
Input
{ namespace?: string; collection: string; fields: ({ as: string; field: string; op: "sum" | "min" | "max" })[]; filter?: QueryFilterSchema }Output
{ count: number; values: Record<string, number | null> }Shapes: QueryFilterSchema
dataStoreProvider.histogram
- Kind: query —
GET /trpc/dataStoreProvider.histogram - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.histogramon your hub
Input
{ namespace?: string; collection: string; field: string; bucketSize: number; origin: number; filter?: QueryFilterSchema }Output
({ bucket: number; count: number })[]Shapes: QueryFilterSchema
dataStoreProvider.isEmpty
- Kind: query —
GET /trpc/dataStoreProvider.isEmpty - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.isEmptyon your hub
Input
{ namespace?: string; collection: string }Output
booleandataStoreProvider.declareCollection
- Kind: mutation —
POST /trpc/dataStoreProvider.declareCollection - Tier: admin — an administrator; a viewer only as the Viewer line says; never a scoped token
- Token scope: none — the admin tier needs an administrator (a
*token or an admin session) - Viewer: no
- Try it: open
/system/api-explorer?method=dataStoreProvider.declareCollectionon your hub
Input
DeclareCollectionInputSchemaOutput
voidShapes: DeclareCollectionInputSchema