@xyo-network/diviner-payload-model 4.0.2 → 4.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,40 @@
1
+ import * as _xylabs_object from '@xylabs/object';
2
+ import { EmptyObject, WithAdditional } from '@xylabs/object';
3
+ import { DivinerConfig, DivinerParams } from '@xyo-network/diviner-model';
4
+ import { Schema, Sequence, Query } from '@xyo-network/payload-model';
5
+ import { AnyConfigSchema } from '@xyo-network/module-model';
6
+
7
+ type PayloadDivinerSchema = 'network.xyo.diviner.payload';
8
+ declare const PayloadDivinerSchema: PayloadDivinerSchema;
9
+
10
+ type PayloadDivinerConfigSchema = `${PayloadDivinerSchema}.config`;
11
+ declare const PayloadDivinerConfigSchema: PayloadDivinerConfigSchema;
12
+ type PayloadDivinerConfig<TAdditional extends EmptyObject | void = void, TSchema extends Schema | void = void> = DivinerConfig<WithAdditional<{
13
+ indexBatchSize?: number;
14
+ maxIndexSize?: number;
15
+ }, TAdditional>, TSchema extends void ? Schema : TSchema>;
16
+
17
+ type Order = 'asc' | 'desc';
18
+
19
+ type PayloadDivinerParams<T extends AnyConfigSchema<PayloadDivinerConfig> | void = void> = DivinerParams<T extends AnyConfigSchema<PayloadDivinerConfig> ? T : AnyConfigSchema<PayloadDivinerConfig>>;
20
+
21
+ type PayloadDivinerPredicate<T extends EmptyObject = EmptyObject> = Partial<{
22
+ cursor: Sequence;
23
+ limit: number;
24
+ order: Order;
25
+ schemas: Schema[];
26
+ } & T>;
27
+
28
+ type PayloadDivinerQuerySchema = `${PayloadDivinerSchema}.query`;
29
+ declare const PayloadDivinerQuerySchema: PayloadDivinerQuerySchema;
30
+ type PayloadDivinerQueryPayload<T extends EmptyObject = EmptyObject> = Query<{
31
+ schema: PayloadDivinerQuerySchema;
32
+ } & PayloadDivinerPredicate<T>>;
33
+ declare const isPayloadDivinerQueryPayload: (x?: unknown | null) => x is PayloadDivinerQueryPayload<object>;
34
+ declare const asPayloadDivinerQueryPayload: _xylabs_object.AsTypeFunction<PayloadDivinerQueryPayload<object>>;
35
+
36
+ /** @deprecated use Order instead */
37
+ type SortDirection = 'asc' | 'desc';
38
+
39
+ export { PayloadDivinerConfigSchema, PayloadDivinerQuerySchema, PayloadDivinerSchema, asPayloadDivinerQueryPayload, isPayloadDivinerQueryPayload };
40
+ export type { Order, PayloadDivinerConfig, PayloadDivinerParams, PayloadDivinerPredicate, PayloadDivinerQueryPayload, SortDirection };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xyo-network/diviner-payload-model",
3
- "version": "4.0.2",
3
+ "version": "4.1.0",
4
4
  "description": "Primary SDK for using XYO Protocol 2.0",
5
5
  "homepage": "https://xyo.network",
6
6
  "bugs": {
@@ -21,22 +21,22 @@
21
21
  "type": "module",
22
22
  "exports": {
23
23
  ".": {
24
- "types": "./dist/types/index.d.ts",
24
+ "types": "./dist/neutral/index.d.ts",
25
25
  "default": "./dist/neutral/index.mjs"
26
26
  },
27
27
  "./package.json": "./package.json"
28
28
  },
29
29
  "module": "dist/neutral/index.mjs",
30
- "types": "dist/types/index.d.ts",
30
+ "types": "dist/neutral/index.d.ts",
31
31
  "dependencies": {
32
- "@xylabs/object": "^4.12.33",
33
- "@xyo-network/diviner-model": "^4.0.2",
34
- "@xyo-network/module-model": "^4.0.2",
35
- "@xyo-network/payload-model": "^4.0.2"
32
+ "@xylabs/object": "^4.13.15",
33
+ "@xyo-network/diviner-model": "^4.1.0",
34
+ "@xyo-network/module-model": "^4.1.0",
35
+ "@xyo-network/payload-model": "^4.1.0"
36
36
  },
37
37
  "devDependencies": {
38
- "@xylabs/ts-scripts-yarn3": "^6.5.12",
39
- "@xylabs/tsconfig": "^6.5.12",
38
+ "@xylabs/ts-scripts-yarn3": "^7.0.0-rc.20",
39
+ "@xylabs/tsconfig": "^7.0.0-rc.20",
40
40
  "typescript": "^5.8.3"
41
41
  },
42
42
  "publishConfig": {
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes