@xyo-network/diviner-jsonpath-model 5.2.25 → 5.3.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.
- package/dist/neutral/Config.d.ts +8 -6
- package/dist/neutral/Config.d.ts.map +1 -1
- package/dist/neutral/index.mjs +4 -1
- package/dist/neutral/index.mjs.map +1 -1
- package/dist/neutral/jsonpath/SchemaToJsonPathTransformExpressionDictionary.d.ts +3 -2
- package/dist/neutral/jsonpath/SchemaToJsonPathTransformExpressionDictionary.d.ts.map +1 -1
- package/package.json +7 -7
- package/src/Config.ts +8 -5
- package/src/jsonpath/SchemaToJsonPathTransformExpressionDictionary.ts +3 -1
package/dist/neutral/Config.d.ts
CHANGED
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
import type { DivinerConfig } from '@xyo-network/diviner-model';
|
|
2
|
+
import type { Schema } from '@xyo-network/payload-model';
|
|
2
3
|
import type { JsonPathTransformExpression } from './jsonpath/index.ts';
|
|
3
|
-
import { JsonPathDivinerSchema } from './Schema.ts';
|
|
4
4
|
/**
|
|
5
|
-
* The config schema
|
|
5
|
+
* The config schema for the JSON Path diviner
|
|
6
6
|
*/
|
|
7
|
-
export
|
|
7
|
+
export declare const JsonPathDivinerConfigSchema: string & {
|
|
8
|
+
readonly __schema: true;
|
|
9
|
+
};
|
|
8
10
|
/**
|
|
9
|
-
* The config schema for the JSON Path diviner
|
|
11
|
+
* The config schema type for the JSON Path diviner
|
|
10
12
|
*/
|
|
11
|
-
export
|
|
13
|
+
export type JsonPathDivinerConfigSchema = typeof JsonPathDivinerConfigSchema;
|
|
12
14
|
/**
|
|
13
15
|
* The configuration for the JSON Path diviner
|
|
14
16
|
*/
|
|
@@ -16,7 +18,7 @@ export type JsonPathDivinerConfig = DivinerConfig<{
|
|
|
16
18
|
/**
|
|
17
19
|
* The schema to use for the destination payloads
|
|
18
20
|
*/
|
|
19
|
-
destinationSchema?:
|
|
21
|
+
destinationSchema?: Schema;
|
|
20
22
|
/**
|
|
21
23
|
* The JSON Path transform expressions to apply to the payloads
|
|
22
24
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Config.d.ts","sourceRoot":"","sources":["../../src/Config.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAA;
|
|
1
|
+
{"version":3,"file":"Config.d.ts","sourceRoot":"","sources":["../../src/Config.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAA;AAC/D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,4BAA4B,CAAA;AAGxD,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,qBAAqB,CAAA;AAGtE;;GAEG;AACH,eAAO,MAAM,2BAA2B;;CAAoD,CAAA;AAE5F;;GAEG;AACH,MAAM,MAAM,2BAA2B,GAAG,OAAO,2BAA2B,CAAA;AAE5E;;GAEG;AACH,MAAM,MAAM,qBAAqB,GAAG,aAAa,CAC/C;IACE;;OAEG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B;;OAEG;IACH,UAAU,CAAC,EAAE,2BAA2B,EAAE,CAAA;CAC3C,GAAG;IAAE,MAAM,EAAE,2BAA2B,CAAA;CAAE,CAC5C,CAAA"}
|
package/dist/neutral/index.mjs
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
|
+
// src/Config.ts
|
|
2
|
+
import { asSchema } from "@xyo-network/payload-model";
|
|
3
|
+
|
|
1
4
|
// src/Schema.ts
|
|
2
5
|
var JsonPathDivinerSchema = "network.xyo.diviner.jsonpath";
|
|
3
6
|
|
|
4
7
|
// src/Config.ts
|
|
5
|
-
var JsonPathDivinerConfigSchema = `${JsonPathDivinerSchema}.config
|
|
8
|
+
var JsonPathDivinerConfigSchema = asSchema(`${JsonPathDivinerSchema}.config`, true);
|
|
6
9
|
export {
|
|
7
10
|
JsonPathDivinerConfigSchema,
|
|
8
11
|
JsonPathDivinerSchema
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/
|
|
1
|
+
{"version":3,"sources":["../../src/Config.ts","../../src/Schema.ts"],"sourcesContent":["import type { DivinerConfig } from '@xyo-network/diviner-model'\nimport type { Schema } from '@xyo-network/payload-model'\nimport { asSchema } from '@xyo-network/payload-model'\n\nimport type { JsonPathTransformExpression } from './jsonpath/index.ts'\nimport { JsonPathDivinerSchema } from './Schema.ts'\n\n/**\n * The config schema for the JSON Path diviner\n */\nexport const JsonPathDivinerConfigSchema = asSchema(`${JsonPathDivinerSchema}.config`, true)\n\n/**\n * The config schema type for the JSON Path diviner\n */\nexport type JsonPathDivinerConfigSchema = typeof JsonPathDivinerConfigSchema\n\n/**\n * The configuration for the JSON Path diviner\n */\nexport type JsonPathDivinerConfig = DivinerConfig<\n {\n /**\n * The schema to use for the destination payloads\n */\n destinationSchema?: Schema\n /**\n * The JSON Path transform expressions to apply to the payloads\n */\n transforms?: JsonPathTransformExpression[]\n } & { schema: JsonPathDivinerConfigSchema }\n>\n","/**\n * The schema type used for the JSONPath Diviner.\n */\nexport type JsonPathDivinerSchema = 'network.xyo.diviner.jsonpath'\n/**\n * The schema used for the JSONPath Diviner.\n */\nexport const JsonPathDivinerSchema: JsonPathDivinerSchema = 'network.xyo.diviner.jsonpath'\n"],"mappings":";AAEA,SAAS,gBAAgB;;;ACKlB,IAAM,wBAA+C;;;ADGrD,IAAM,8BAA8B,SAAS,GAAG,qBAAqB,WAAW,IAAI;","names":[]}
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
+
import type { Schema } from '@xyo-network/payload-model';
|
|
1
2
|
import type { JsonPathTransformExpression } from './JsonPathTransformExpression.ts';
|
|
2
3
|
/**
|
|
3
4
|
* A dictionary of schema to JSON Path transform expressions.
|
|
4
5
|
*/
|
|
5
6
|
export type SchemaToJsonPathTransformExpressionsDictionary<T extends {
|
|
6
|
-
[schema:
|
|
7
|
+
[schema: Schema]: unknown;
|
|
7
8
|
} = {
|
|
8
|
-
[schema:
|
|
9
|
+
[schema: Schema]: unknown;
|
|
9
10
|
}> = {
|
|
10
11
|
[key in keyof T]: JsonPathTransformExpression[];
|
|
11
12
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SchemaToJsonPathTransformExpressionDictionary.d.ts","sourceRoot":"","sources":["../../../src/jsonpath/SchemaToJsonPathTransformExpressionDictionary.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,kCAAkC,CAAA;AAEnF;;GAEG;AACH,MAAM,MAAM,8CAA8C,CAAC,CAAC,SAAS;IAAE,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAA;CAAE,GAAG;IAAE,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAA;CAAE,IAAI;KACnI,GAAG,IAAI,MAAM,CAAC,GAAG,2BAA2B,EAAE;CAChD,CAAA"}
|
|
1
|
+
{"version":3,"file":"SchemaToJsonPathTransformExpressionDictionary.d.ts","sourceRoot":"","sources":["../../../src/jsonpath/SchemaToJsonPathTransformExpressionDictionary.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,4BAA4B,CAAA;AAExD,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,kCAAkC,CAAA;AAEnF;;GAEG;AACH,MAAM,MAAM,8CAA8C,CAAC,CAAC,SAAS;IAAE,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAA;CAAE,GAAG;IAAE,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAA;CAAE,IAAI;KACnI,GAAG,IAAI,MAAM,CAAC,GAAG,2BAA2B,EAAE;CAChD,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xyo-network/diviner-jsonpath-model",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.3.0",
|
|
4
4
|
"description": "Primary SDK for using XYO Protocol 2.0",
|
|
5
5
|
"homepage": "https://xyo.network",
|
|
6
6
|
"bugs": {
|
|
@@ -36,14 +36,14 @@
|
|
|
36
36
|
"!**/*.test.*"
|
|
37
37
|
],
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@xylabs/sdk-js": "~5.0.
|
|
40
|
-
"@xyo-network/diviner-model": "~5.
|
|
41
|
-
"@xyo-network/module-model": "~5.
|
|
42
|
-
"@xyo-network/payload-model": "~5.
|
|
39
|
+
"@xylabs/sdk-js": "~5.0.64",
|
|
40
|
+
"@xyo-network/diviner-model": "~5.3.0",
|
|
41
|
+
"@xyo-network/module-model": "~5.3.0",
|
|
42
|
+
"@xyo-network/payload-model": "~5.3.0"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
|
-
"@xylabs/ts-scripts-yarn3": "~7.2
|
|
46
|
-
"@xylabs/tsconfig": "~7.2
|
|
45
|
+
"@xylabs/ts-scripts-yarn3": "~7.3.2",
|
|
46
|
+
"@xylabs/tsconfig": "~7.3.2",
|
|
47
47
|
"typescript": "~5.9.3"
|
|
48
48
|
},
|
|
49
49
|
"publishConfig": {
|
package/src/Config.ts
CHANGED
|
@@ -1,16 +1,19 @@
|
|
|
1
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'
|
|
2
4
|
|
|
3
5
|
import type { JsonPathTransformExpression } from './jsonpath/index.ts'
|
|
4
6
|
import { JsonPathDivinerSchema } from './Schema.ts'
|
|
5
7
|
|
|
6
8
|
/**
|
|
7
|
-
* The config schema
|
|
9
|
+
* The config schema for the JSON Path diviner
|
|
8
10
|
*/
|
|
9
|
-
export
|
|
11
|
+
export const JsonPathDivinerConfigSchema = asSchema(`${JsonPathDivinerSchema}.config`, true)
|
|
12
|
+
|
|
10
13
|
/**
|
|
11
|
-
* The config schema for the JSON Path diviner
|
|
14
|
+
* The config schema type for the JSON Path diviner
|
|
12
15
|
*/
|
|
13
|
-
export
|
|
16
|
+
export type JsonPathDivinerConfigSchema = typeof JsonPathDivinerConfigSchema
|
|
14
17
|
|
|
15
18
|
/**
|
|
16
19
|
* The configuration for the JSON Path diviner
|
|
@@ -20,7 +23,7 @@ export type JsonPathDivinerConfig = DivinerConfig<
|
|
|
20
23
|
/**
|
|
21
24
|
* The schema to use for the destination payloads
|
|
22
25
|
*/
|
|
23
|
-
destinationSchema?:
|
|
26
|
+
destinationSchema?: Schema
|
|
24
27
|
/**
|
|
25
28
|
* The JSON Path transform expressions to apply to the payloads
|
|
26
29
|
*/
|
|
@@ -1,8 +1,10 @@
|
|
|
1
|
+
import type { Schema } from '@xyo-network/payload-model'
|
|
2
|
+
|
|
1
3
|
import type { JsonPathTransformExpression } from './JsonPathTransformExpression.ts'
|
|
2
4
|
|
|
3
5
|
/**
|
|
4
6
|
* A dictionary of schema to JSON Path transform expressions.
|
|
5
7
|
*/
|
|
6
|
-
export type SchemaToJsonPathTransformExpressionsDictionary<T extends { [schema:
|
|
8
|
+
export type SchemaToJsonPathTransformExpressionsDictionary<T extends { [schema: Schema]: unknown } = { [schema: Schema]: unknown }> = {
|
|
7
9
|
[key in keyof T]: JsonPathTransformExpression[]
|
|
8
10
|
}
|