@xyo-network/diviner-hash-lease 3.5.2 → 3.6.0-rc.10
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.
|
@@ -23,19 +23,21 @@ export type HashLeaseEstimate = Payload<HashLeaseEstimateFields, HashLeaseEstima
|
|
|
23
23
|
/**
|
|
24
24
|
* Identity function for HashLeaseEstimate payload
|
|
25
25
|
*/
|
|
26
|
-
export declare const isHashLeaseEstimate: (x?: unknown | null) => x is import("@
|
|
27
|
-
schema: "network.xyo.hash.lease.estimate";
|
|
28
|
-
};
|
|
29
|
-
/**
|
|
30
|
-
* Identity function for HashLeaseEstimate payload with meta
|
|
31
|
-
*/
|
|
32
|
-
export declare const isHashLeaseEstimateWithMeta: (x?: unknown | null) => x is import("@xyo-network/payload-model").WithMeta<import("@xyo-network/payload-model").SchemaFields & import("@xyo-network/payload-model").PayloadFields & HashLeaseEstimateFields & {
|
|
26
|
+
export declare const isHashLeaseEstimate: (x?: unknown | null) => x is import("@xylabs/object").DeepRestrictToStringKeys<{
|
|
33
27
|
schema: "network.xyo.hash.lease.estimate";
|
|
28
|
+
currency: string;
|
|
29
|
+
exp: number;
|
|
30
|
+
nbf: number;
|
|
31
|
+
price: number;
|
|
34
32
|
}>;
|
|
35
33
|
/**
|
|
36
34
|
* Identity function for HashLeaseEstimate payload with sources
|
|
37
35
|
*/
|
|
38
|
-
export declare const isHashLeaseEstimateWithSources: (x?: unknown | null) => x is import("@xyo-network/payload-model").WithSources<import("@
|
|
36
|
+
export declare const isHashLeaseEstimateWithSources: (x?: unknown | null) => x is import("@xyo-network/payload-model").WithSources<import("@xylabs/object").DeepRestrictToStringKeys<{
|
|
39
37
|
schema: "network.xyo.hash.lease.estimate";
|
|
40
|
-
|
|
38
|
+
currency: string;
|
|
39
|
+
exp: number;
|
|
40
|
+
nbf: number;
|
|
41
|
+
price: number;
|
|
42
|
+
}>>;
|
|
41
43
|
//# sourceMappingURL=HashLeaseEstimate.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HashLeaseEstimate.d.ts","sourceRoot":"","sources":["../../../src/Payload/HashLeaseEstimate.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAA;
|
|
1
|
+
{"version":3,"file":"HashLeaseEstimate.d.ts","sourceRoot":"","sources":["../../../src/Payload/HashLeaseEstimate.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAA;AAGzD,eAAO,MAAM,uBAAuB,EAAG,iCAA0C,CAAA;AACjF,MAAM,MAAM,uBAAuB,GAAG,OAAO,uBAAuB,CAAA;AAEpE,MAAM,WAAW,uBAAuB;IACtC;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAA;IAChB;;OAEG;IACH,GAAG,EAAE,MAAM,CAAA;IACX;;OAEG;IACH,GAAG,EAAE,MAAM,CAAA;IACX;;OAEG;IACH,KAAK,EAAE,MAAM,CAAA;CACd;AAED,MAAM,MAAM,iBAAiB,GAAG,OAAO,CAAC,uBAAuB,EAAE,uBAAuB,CAAC,CAAA;AAEzF;;GAEG;AACH,eAAO,MAAM,mBAAmB;;cApBpB,MAAM;SAIX,MAAM;SAIN,MAAM;WAIJ,MAAM;EAQqF,CAAA;AAEpG;;GAEG;AACH,eAAO,MAAM,8BAA8B;;cAzB/B,MAAM;SAIX,MAAM;SAIN,MAAM;WAIJ,MAAM;GAa2G,CAAA"}
|
package/dist/neutral/index.mjs
CHANGED
|
@@ -12,10 +12,9 @@ import { creatableModule } from "@xyo-network/module-model";
|
|
|
12
12
|
var HashLeaseSchema = "network.xyo.hash.lease";
|
|
13
13
|
|
|
14
14
|
// src/Payload/HashLeaseEstimate.ts
|
|
15
|
-
import { isPayloadOfSchemaType,
|
|
15
|
+
import { isPayloadOfSchemaType, isPayloadOfSchemaTypeWithSources } from "@xyo-network/payload-model";
|
|
16
16
|
var HashLeaseEstimateSchema = "network.xyo.hash.lease.estimate";
|
|
17
17
|
var isHashLeaseEstimate = isPayloadOfSchemaType(HashLeaseEstimateSchema);
|
|
18
|
-
var isHashLeaseEstimateWithMeta = isPayloadOfSchemaTypeWithMeta(HashLeaseEstimateSchema);
|
|
19
18
|
var isHashLeaseEstimateWithSources = isPayloadOfSchemaTypeWithSources(HashLeaseEstimateSchema);
|
|
20
19
|
|
|
21
20
|
// src/Diviner.ts
|
|
@@ -49,7 +48,6 @@ export {
|
|
|
49
48
|
HashLeaseEstimateSchema,
|
|
50
49
|
HashLeaseSchema,
|
|
51
50
|
isHashLeaseEstimate,
|
|
52
|
-
isHashLeaseEstimateWithMeta,
|
|
53
51
|
isHashLeaseEstimateWithSources
|
|
54
52
|
};
|
|
55
53
|
//# sourceMappingURL=index.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/Config.ts","../../src/Diviner.ts","../../src/Payload/HashLease.ts","../../src/Payload/HashLeaseEstimate.ts"],"sourcesContent":["import type { DivinerConfig } from '@xyo-network/diviner-model'\n\nexport const HashLeaseEstimateDivinerConfigSchema = 'network.xyo.diviner.hash.lease.estimate.config' as const\nexport type HashLeaseEstimateDivinerConfigSchema = typeof HashLeaseEstimateDivinerConfigSchema\n\nexport type HashLeaseEstimateDivinerConfig = DivinerConfig<\n\n {\n //\n },\n HashLeaseEstimateDivinerConfigSchema\n>\n","import { AbstractDiviner } from '@xyo-network/diviner-abstract'\nimport { DivinerInstance, DivinerModuleEventData } from '@xyo-network/diviner-model'\nimport { creatableModule } from '@xyo-network/module-model'\nimport { Payload, Schema } from '@xyo-network/payload-model'\n\nimport { HashLeaseEstimateDivinerConfigSchema } from './Config.ts'\nimport { HashLeaseEstimateDivinerParams } from './Params.ts'\nimport { HashLeaseEstimate, HashLeaseEstimateSchema } from './Payload/index.ts'\n\n@creatableModule()\nexport class HashLeaseEstimateDiviner<\n TParams extends HashLeaseEstimateDivinerParams = HashLeaseEstimateDivinerParams,\n TIn extends Payload = Payload,\n TOut extends HashLeaseEstimate | Payload = HashLeaseEstimate | Payload,\n TEventData extends DivinerModuleEventData<DivinerInstance<TParams, TIn, TOut>, TIn, TOut> = DivinerModuleEventData<\n DivinerInstance<TParams, TIn, TOut>,\n TIn,\n TOut\n >,\n> extends AbstractDiviner<TParams, TIn, TOut, TEventData> {\n static override readonly configSchemas: Schema[] = [...super.configSchemas, HashLeaseEstimateDivinerConfigSchema]\n static override readonly defaultConfigSchema: Schema = HashLeaseEstimateDivinerConfigSchema\n static override targetSchema = HashLeaseEstimateSchema\n\n protected override async divineHandler(_payloads: TIn[] = []): Promise<TOut[]> {\n return await Promise.resolve([])\n }\n}\n","import type { Payload } from '@xyo-network/payload-model'\n\nexport const HashLeaseSchema = 'network.xyo.hash.lease' as const\nexport type HashLeaseSchema = typeof HashLeaseSchema\n\nexport type HashLease = Payload<\n {\n /**\n * The desired duration of the lease\n */\n duration: number\n },\n HashLeaseSchema\n>\n","import type { Payload } from '@xyo-network/payload-model'\nimport {
|
|
1
|
+
{"version":3,"sources":["../../src/Config.ts","../../src/Diviner.ts","../../src/Payload/HashLease.ts","../../src/Payload/HashLeaseEstimate.ts"],"sourcesContent":["import type { DivinerConfig } from '@xyo-network/diviner-model'\n\nexport const HashLeaseEstimateDivinerConfigSchema = 'network.xyo.diviner.hash.lease.estimate.config' as const\nexport type HashLeaseEstimateDivinerConfigSchema = typeof HashLeaseEstimateDivinerConfigSchema\n\nexport type HashLeaseEstimateDivinerConfig = DivinerConfig<\n\n {\n //\n },\n HashLeaseEstimateDivinerConfigSchema\n>\n","import { AbstractDiviner } from '@xyo-network/diviner-abstract'\nimport { DivinerInstance, DivinerModuleEventData } from '@xyo-network/diviner-model'\nimport { creatableModule } from '@xyo-network/module-model'\nimport { Payload, Schema } from '@xyo-network/payload-model'\n\nimport { HashLeaseEstimateDivinerConfigSchema } from './Config.ts'\nimport { HashLeaseEstimateDivinerParams } from './Params.ts'\nimport { HashLeaseEstimate, HashLeaseEstimateSchema } from './Payload/index.ts'\n\n@creatableModule()\nexport class HashLeaseEstimateDiviner<\n TParams extends HashLeaseEstimateDivinerParams = HashLeaseEstimateDivinerParams,\n TIn extends Payload = Payload,\n TOut extends HashLeaseEstimate | Payload = HashLeaseEstimate | Payload,\n TEventData extends DivinerModuleEventData<DivinerInstance<TParams, TIn, TOut>, TIn, TOut> = DivinerModuleEventData<\n DivinerInstance<TParams, TIn, TOut>,\n TIn,\n TOut\n >,\n> extends AbstractDiviner<TParams, TIn, TOut, TEventData> {\n static override readonly configSchemas: Schema[] = [...super.configSchemas, HashLeaseEstimateDivinerConfigSchema]\n static override readonly defaultConfigSchema: Schema = HashLeaseEstimateDivinerConfigSchema\n static override targetSchema = HashLeaseEstimateSchema\n\n protected override async divineHandler(_payloads: TIn[] = []): Promise<TOut[]> {\n return await Promise.resolve([])\n }\n}\n","import type { Payload } from '@xyo-network/payload-model'\n\nexport const HashLeaseSchema = 'network.xyo.hash.lease' as const\nexport type HashLeaseSchema = typeof HashLeaseSchema\n\nexport type HashLease = Payload<\n {\n /**\n * The desired duration of the lease\n */\n duration: number\n },\n HashLeaseSchema\n>\n","import type { Payload } from '@xyo-network/payload-model'\nimport { isPayloadOfSchemaType, isPayloadOfSchemaTypeWithSources } from '@xyo-network/payload-model'\n\nexport const HashLeaseEstimateSchema = 'network.xyo.hash.lease.estimate' as const\nexport type HashLeaseEstimateSchema = typeof HashLeaseEstimateSchema\n\nexport interface HashLeaseEstimateFields {\n /**\n * The currency of the price\n */\n currency: string\n /**\n * When the lease ends\n */\n exp: number\n /**\n * When the lease begins\n */\n nbf: number\n /**\n * The estimated price of the lease\n */\n price: number\n}\n\nexport type HashLeaseEstimate = Payload<HashLeaseEstimateFields, HashLeaseEstimateSchema>\n\n/**\n * Identity function for HashLeaseEstimate payload\n */\nexport const isHashLeaseEstimate = isPayloadOfSchemaType<HashLeaseEstimate>(HashLeaseEstimateSchema)\n\n/**\n * Identity function for HashLeaseEstimate payload with sources\n */\nexport const isHashLeaseEstimateWithSources = isPayloadOfSchemaTypeWithSources<HashLeaseEstimate>(HashLeaseEstimateSchema)\n"],"mappings":";;;;AAEO,IAAMA,uCAAuC;;;ACFpD,SAASC,uBAAuB;AAEhC,SAASC,uBAAuB;;;ACAzB,IAAMC,kBAAkB;;;ACD/B,SAASC,uBAAuBC,wCAAwC;AAEjE,IAAMC,0BAA0B;AA2BhC,IAAMC,sBAAsBH,sBAAyCE,uBAAAA;AAKrE,IAAME,iCAAiCH,iCAAoDC,uBAAAA;;;;;;;;;;AFzB3F,IAAMG,2BAAN,cASGC,gBAAAA;SAAAA;;;EACR,OAAyBC,gBAA0B;OAAI,MAAMA;IAAeC;;EAC5E,OAAyBC,sBAA8BD;EACvD,OAAgBE,eAAeC;EAE/B,MAAyBC,cAAcC,YAAmB,CAAA,GAAqB;AAC7E,WAAO,MAAMC,QAAQC,QAAQ,CAAA,CAAE;EACjC;AACF;;;;","names":["HashLeaseEstimateDivinerConfigSchema","AbstractDiviner","creatableModule","HashLeaseSchema","isPayloadOfSchemaType","isPayloadOfSchemaTypeWithSources","HashLeaseEstimateSchema","isHashLeaseEstimate","isHashLeaseEstimateWithSources","HashLeaseEstimateDiviner","AbstractDiviner","configSchemas","HashLeaseEstimateDivinerConfigSchema","defaultConfigSchema","targetSchema","HashLeaseEstimateSchema","divineHandler","_payloads","Promise","resolve"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xyo-network/diviner-hash-lease",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.6.0-rc.10",
|
|
4
4
|
"description": "Primary SDK for using XYO Protocol 2.0",
|
|
5
5
|
"homepage": "https://xyo.network",
|
|
6
6
|
"bugs": {
|
|
@@ -29,17 +29,18 @@
|
|
|
29
29
|
"module": "dist/neutral/index.mjs",
|
|
30
30
|
"types": "dist/neutral/index.d.ts",
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@xyo-network/diviner-abstract": "^3.
|
|
33
|
-
"@xyo-network/diviner-model": "^3.
|
|
34
|
-
"@xyo-network/module-model": "^3.
|
|
35
|
-
"@xyo-network/payload-model": "^3.
|
|
32
|
+
"@xyo-network/diviner-abstract": "^3.6.0-rc.10",
|
|
33
|
+
"@xyo-network/diviner-model": "^3.6.0-rc.10",
|
|
34
|
+
"@xyo-network/module-model": "^3.6.0-rc.10",
|
|
35
|
+
"@xyo-network/payload-model": "^3.6.0-rc.10"
|
|
36
36
|
},
|
|
37
37
|
"devDependencies": {
|
|
38
|
-
"@xylabs/ts-scripts-yarn3": "^4.2.
|
|
39
|
-
"@xylabs/tsconfig": "^4.2.
|
|
38
|
+
"@xylabs/ts-scripts-yarn3": "^4.2.6",
|
|
39
|
+
"@xylabs/tsconfig": "^4.2.6",
|
|
40
40
|
"typescript": "^5.7.2"
|
|
41
41
|
},
|
|
42
42
|
"publishConfig": {
|
|
43
43
|
"access": "public"
|
|
44
|
-
}
|
|
44
|
+
},
|
|
45
|
+
"stableVersion": "3.5.2"
|
|
45
46
|
}
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import type { Payload } from '@xyo-network/payload-model'
|
|
2
|
-
import {
|
|
3
|
-
isPayloadOfSchemaType, isPayloadOfSchemaTypeWithMeta, isPayloadOfSchemaTypeWithSources,
|
|
4
|
-
} from '@xyo-network/payload-model'
|
|
2
|
+
import { isPayloadOfSchemaType, isPayloadOfSchemaTypeWithSources } from '@xyo-network/payload-model'
|
|
5
3
|
|
|
6
4
|
export const HashLeaseEstimateSchema = 'network.xyo.hash.lease.estimate' as const
|
|
7
5
|
export type HashLeaseEstimateSchema = typeof HashLeaseEstimateSchema
|
|
@@ -32,11 +30,6 @@ export type HashLeaseEstimate = Payload<HashLeaseEstimateFields, HashLeaseEstima
|
|
|
32
30
|
*/
|
|
33
31
|
export const isHashLeaseEstimate = isPayloadOfSchemaType<HashLeaseEstimate>(HashLeaseEstimateSchema)
|
|
34
32
|
|
|
35
|
-
/**
|
|
36
|
-
* Identity function for HashLeaseEstimate payload with meta
|
|
37
|
-
*/
|
|
38
|
-
export const isHashLeaseEstimateWithMeta = isPayloadOfSchemaTypeWithMeta<HashLeaseEstimate>(HashLeaseEstimateSchema)
|
|
39
|
-
|
|
40
33
|
/**
|
|
41
34
|
* Identity function for HashLeaseEstimate payload with sources
|
|
42
35
|
*/
|