@xyo-network/diviner-jsonpath-model 5.3.22 → 5.3.25

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xyo-network/diviner-jsonpath-model",
3
- "version": "5.3.22",
3
+ "version": "5.3.25",
4
4
  "description": "Primary SDK for using XYO Protocol 2.0",
5
5
  "homepage": "https://xyo.network",
6
6
  "bugs": {
@@ -30,35 +30,31 @@
30
30
  "types": "dist/neutral/index.d.ts",
31
31
  "files": [
32
32
  "dist",
33
- "src",
34
33
  "!**/*.bench.*",
35
34
  "!**/*.spec.*",
36
35
  "!**/*.test.*",
37
36
  "README.md"
38
37
  ],
39
38
  "dependencies": {
40
- "@xyo-network/diviner-model": "~5.3.22",
41
- "@xyo-network/module-model": "~5.3.22",
42
- "@xyo-network/payload-model": "~5.3.22"
39
+ "@xyo-network/diviner-model": "~5.3.25",
40
+ "@xyo-network/module-model": "~5.3.25",
41
+ "@xyo-network/payload-model": "~5.3.25"
43
42
  },
44
43
  "devDependencies": {
45
44
  "@opentelemetry/api": "^1.9.1",
46
45
  "@types/node": "^25.5.0",
47
- "@xylabs/sdk-js": "^5.0.91",
48
- "@xylabs/ts-scripts-common": "~7.6.8",
49
- "@xylabs/ts-scripts-yarn3": "~7.6.8",
50
- "@xylabs/tsconfig": "~7.6.8",
51
- "@xyo-network/diviner-model": "~5.3.22",
52
- "@xyo-network/module-model": "~5.3.22",
53
- "@xyo-network/payload-model": "~5.3.22",
46
+ "@xylabs/sdk-js": "^5.0.93",
47
+ "@xylabs/ts-scripts-common": "~7.6.16",
48
+ "@xylabs/ts-scripts-pnpm": "~7.6.16",
49
+ "@xylabs/tsconfig": "~7.6.16",
54
50
  "acorn": "^8.16.0",
55
51
  "axios": "^1.14.0",
56
- "cosmiconfig": "^9.0.1",
57
- "esbuild": "^0.27.4",
58
- "eslint": "^10.1.0",
59
- "rollup": "^4.60.1",
52
+ "esbuild": "^0.28.0",
60
53
  "typescript": "~5.9.3",
61
- "zod": "^4.3.6"
54
+ "zod": "^4.3.6",
55
+ "@xyo-network/module-model": "~5.3.25",
56
+ "@xyo-network/diviner-model": "~5.3.25",
57
+ "@xyo-network/payload-model": "~5.3.25"
62
58
  },
63
59
  "peerDependencies": {
64
60
  "@xylabs/sdk-js": "^5",
@@ -67,4 +63,4 @@
67
63
  "publishConfig": {
68
64
  "access": "public"
69
65
  }
70
- }
66
+ }
package/src/Config.ts DELETED
@@ -1,32 +0,0 @@
1
- import type { DivinerConfig } from '@xyo-network/diviner-model'
2
- import type { Schema } from '@xyo-network/payload-model'
3
- import { asSchema } from '@xyo-network/payload-model'
4
-
5
- import type { JsonPathTransformExpression } from './jsonpath/index.ts'
6
- import { JsonPathDivinerSchema } from './Schema.ts'
7
-
8
- /**
9
- * The config schema for the JSON Path diviner
10
- */
11
- export const JsonPathDivinerConfigSchema = asSchema(`${JsonPathDivinerSchema}.config`, true)
12
-
13
- /**
14
- * The config schema type for the JSON Path diviner
15
- */
16
- export type JsonPathDivinerConfigSchema = typeof JsonPathDivinerConfigSchema
17
-
18
- /**
19
- * The configuration for the JSON Path diviner
20
- */
21
- export type JsonPathDivinerConfig = DivinerConfig<
22
- {
23
- /**
24
- * The schema to use for the destination payloads
25
- */
26
- destinationSchema?: Schema
27
- /**
28
- * The JSON Path transform expressions to apply to the payloads
29
- */
30
- transforms?: JsonPathTransformExpression[]
31
- } & { schema: JsonPathDivinerConfigSchema }
32
- >
package/src/Params.ts DELETED
@@ -1,9 +0,0 @@
1
- import type { DivinerParams } from '@xyo-network/diviner-model'
2
- import type { AnyConfigSchema } from '@xyo-network/module-model'
3
-
4
- import type { JsonPathDivinerConfig } from './Config.ts'
5
-
6
- /**
7
- * The params type the JSON Path diviner
8
- **/
9
- export type JsonPathDivinerParams = DivinerParams<AnyConfigSchema<JsonPathDivinerConfig>>
package/src/Schema.ts DELETED
@@ -1,10 +0,0 @@
1
- import { asSchema } from '@xyo-network/payload-model'
2
- /**
3
- * The schema used for the JSONPath Diviner.
4
- */
5
- export const JsonPathDivinerSchema = asSchema('network.xyo.diviner.jsonpath', true)
6
-
7
- /**
8
- * The schema type used for the JSONPath Diviner.
9
- */
10
- export type JsonPathDivinerSchema = typeof JsonPathDivinerSchema
package/src/index.ts DELETED
@@ -1,4 +0,0 @@
1
- export * from './Config.ts'
2
- export * from './jsonpath/index.ts'
3
- export * from './Params.ts'
4
- export * from './Schema.ts'
@@ -1,20 +0,0 @@
1
- import type { JsonValue } from '@xylabs/sdk-js'
2
-
3
- /**
4
- * Describes the JSON-path transformation to retrieve a field on a source object
5
- * and the target field to store the value to on a destination object
6
- */
7
- export interface JsonPathTransformExpression {
8
- /**
9
- * The default value to use if the source field does not exist
10
- */
11
- defaultValue?: JsonValue
12
- /**
13
- * The target field to store the source field into on the destination object
14
- */
15
- destinationField: string
16
- /**
17
- * The JSON path expressions for the source field on the source object
18
- */
19
- sourcePathExpression: string
20
- }
@@ -1,5 +0,0 @@
1
- import type { Payload } from '@xyo-network/payload-model'
2
-
3
- // TODO: Support for multiple return values from a single transformer
4
- // export type PayloadTransformer = (x: Payload) => Partial<Payload> | Partial<Payload>[]
5
- export type PayloadTransformer = (x: Payload) => Partial<Payload>
@@ -1,10 +0,0 @@
1
- import type { Schema } from '@xyo-network/payload-model'
2
-
3
- import type { JsonPathTransformExpression } from './JsonPathTransformExpression.ts'
4
-
5
- /**
6
- * A dictionary of schema to JSON Path transform expressions.
7
- */
8
- export type SchemaToJsonPathTransformExpressionsDictionary<T extends { [schema: Schema]: unknown } = { [schema: Schema]: unknown }> = {
9
- [key in keyof T]: JsonPathTransformExpression[]
10
- }
@@ -1,6 +0,0 @@
1
- import type { PayloadTransformer } from './PayloadTransformer.ts'
2
-
3
- /**
4
- * A dictionary of schema to payload transformers
5
- */
6
- export type SchemaToPayloadTransformersDictionary = { [schema: string]: PayloadTransformer[] }
@@ -1,4 +0,0 @@
1
- export * from './JsonPathTransformExpression.ts'
2
- export * from './PayloadTransformer.ts'
3
- export * from './SchemaToJsonPathTransformExpressionDictionary.ts'
4
- export * from './SchemaToPayloadTransformersDictionary.ts'