@xyo-network/boundwitness-model 5.2.7 → 5.2.8

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.
@@ -12,6 +12,6 @@ export declare const SignedSignaturesMetaZod: z.ZodObject<{
12
12
  export type SignaturesMeta = z.infer<typeof SignaturesMetaZod>;
13
13
  export type UnsignedSignaturesMeta = z.infer<typeof UnsignedSignaturesMetaZod>;
14
14
  export type SignedSignaturesMeta = z.infer<typeof SignedSignaturesMetaZod>;
15
- export type Unsigned<T extends BoundWitness = BoundWitness> = T & UnsignedSignaturesMeta;
16
- export type Signed<T extends BoundWitness = BoundWitness> = T & SignedSignaturesMeta;
15
+ export type Unsigned<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & UnsignedSignaturesMeta;
16
+ export type Signed<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & SignedSignaturesMeta;
17
17
  //# sourceMappingURL=Signatures.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Signatures.d.ts","sourceRoot":"","sources":["../../../src/BoundWitness/Signatures.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAA;AAEnB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAErD,eAAO,MAAM,iBAAiB;;mBAAkE,CAAA;AAChG,eAAO,MAAM,yBAAyB;;mBAA+C,CAAA;AACrF,eAAO,MAAM,uBAAuB;;mBAA6C,CAAA;AAEjF,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAA;AAC9D,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAA;AAC9E,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAA;AAE1E,MAAM,MAAM,QAAQ,CAAC,CAAC,SAAS,YAAY,GAAG,YAAY,IAAI,CAAC,GAAG,sBAAsB,CAAA;AACxF,MAAM,MAAM,MAAM,CAAC,CAAC,SAAS,YAAY,GAAG,YAAY,IAAI,CAAC,GAAG,oBAAoB,CAAA"}
1
+ {"version":3,"file":"Signatures.d.ts","sourceRoot":"","sources":["../../../src/BoundWitness/Signatures.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAA;AAEnB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAErD,eAAO,MAAM,iBAAiB;;mBAAkE,CAAA;AAChG,eAAO,MAAM,yBAAyB;;mBAA+C,CAAA;AACrF,eAAO,MAAM,uBAAuB;;mBAA6C,CAAA;AAEjF,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAA;AAC9D,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAA;AAC9E,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAA;AAE1E,MAAM,MAAM,QAAQ,CAAC,CAAC,SAAS,YAAY,GAAG,YAAY,IAAI,IAAI,CAAC,CAAC,EAAE,aAAa,CAAC,GAAG,sBAAsB,CAAA;AAC7G,MAAM,MAAM,MAAM,CAAC,CAAC,SAAS,YAAY,GAAG,YAAY,IAAI,IAAI,CAAC,CAAC,EAAE,aAAa,CAAC,GAAG,oBAAoB,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/BoundWitness/BoundWitness.ts","../../src/BoundWitness/BoundWitnessSchema.ts","../../src/BoundWitness/Signatures.ts","../../src/BoundWitness/BoundWitnessJsonSchema.ts","../../src/BoundWitness/SignedBoundWitness.ts","../../src/BoundWitness/UnsignedBoundWitness.ts","../../src/QueryBoundWitness.ts"],"sourcesContent":["import { AddressZod, HashZod } from '@xylabs/sdk-js'\nimport {\n zodAsFactory, zodIsFactory, zodToFactory,\n} from '@xylabs/zod'\nimport { PayloadZod, SchemaZod } from '@xyo-network/payload-model'\nimport z from 'zod'\n\nimport { BoundWitnessSchema } from './BoundWitnessSchema.ts'\nimport { SignaturesMetaZod } from './Signatures.ts'\n\nexport const BoundWitnessRequiredFieldsZod = z.object({\n addresses: z.array(AddressZod),\n payload_hashes: z.array(HashZod),\n payload_schemas: z.array(SchemaZod),\n previous_hashes: z.array(HashZod.nullable()),\n})\n\nexport type BoundWitnessRequiredFields = z.infer<typeof BoundWitnessRequiredFieldsZod>\n\nexport const BoundWitnessMetaZod = z.object({\n $destination: AddressZod.optional(),\n $sourceQuery: HashZod.optional(),\n}).extend(SignaturesMetaZod.shape)\n\nexport type BoundWitnessMeta = z.infer<typeof BoundWitnessMetaZod>\n\nexport const BoundWitnessZod = PayloadZod\n .safeExtend({ schema: z.literal(BoundWitnessSchema) })\n .safeExtend(BoundWitnessRequiredFieldsZod.shape)\n .safeExtend(BoundWitnessMetaZod.shape)\n // .refine(data => data.$signatures.length === data.addresses.length, { message: '$signatures length must equal addresses length' })\n\nexport type BoundWitness = z.infer<typeof BoundWitnessZod>\n\nexport const isBoundWitness = zodIsFactory(BoundWitnessZod)\nexport const asBoundWitness = zodAsFactory(BoundWitnessZod, 'asBoundWitness')\nexport const toBoundWitness = zodToFactory(BoundWitnessZod, 'toBoundWitness')\n\nexport const AnyBoundWitnessZod = BoundWitnessZod.loose()\nexport type AnyBoundWitness = z.infer<typeof AnyBoundWitnessZod>\n","export const BoundWitnessSchema = 'network.xyo.boundwitness' as const\nexport type BoundWitnessSchema = typeof BoundWitnessSchema\n","import { HexZod } from '@xylabs/sdk-js'\nimport z from 'zod'\n\nimport type { BoundWitness } from './BoundWitness.ts'\n\nexport const SignaturesMetaZod = z.object({ $signatures: z.array(z.union([HexZod, z.null()])) })\nexport const UnsignedSignaturesMetaZod = z.object({ $signatures: z.array(z.null()) })\nexport const SignedSignaturesMetaZod = z.object({ $signatures: z.array(HexZod) })\n\nexport type SignaturesMeta = z.infer<typeof SignaturesMetaZod>\nexport type UnsignedSignaturesMeta = z.infer<typeof UnsignedSignaturesMetaZod>\nexport type SignedSignaturesMeta = z.infer<typeof SignedSignaturesMetaZod>\n\nexport type Unsigned<T extends BoundWitness = BoundWitness> = T & UnsignedSignaturesMeta\nexport type Signed<T extends BoundWitness = BoundWitness> = T & SignedSignaturesMeta\n","// Should type as JSONSchemaType<BoundWitness> once ajv/eslint issue is fixed\n// https://github.com/microsoft/TypeScript/issues/44851\n\nexport const BoundWitnessJsonSchema = () => {\n return {\n $id: 'https://schemas.xyo.network/2.0/boundwitness',\n additionalProperties: false,\n properties: {\n addresses: { items: { type: 'string' }, type: 'array' },\n payload_hashes: { items: { type: 'string' }, type: 'array' },\n payload_schemas: { items: { type: 'string' }, type: 'array' },\n previous_hashes: { items: { nullable: true, type: 'string' }, type: 'array' },\n schema: { type: 'string' },\n },\n required: ['addresses', 'payload_hashes', 'payload_schemas', 'previous_hashes', 'schema'],\n type: 'object',\n }\n}\n","import type z from 'zod'\n\nimport { BoundWitnessZod } from './BoundWitness.ts'\nimport { SignedSignaturesMetaZod } from './Signatures.ts'\n\nexport const SignedBoundWitnessZod = BoundWitnessZod.extend(SignedSignaturesMetaZod.shape)\nexport type SignedBoundWitness = z.infer<typeof SignedBoundWitnessZod>\n\nexport const AnySignedBoundWitnessZod = SignedBoundWitnessZod.loose()\nexport type AnySignedBoundWitness = z.infer<typeof AnySignedBoundWitnessZod>\n","import type z from 'zod'\n\nimport { BoundWitnessZod } from './BoundWitness.ts'\nimport { UnsignedSignaturesMetaZod } from './Signatures.ts'\n\nexport const UnsignedBoundWitnessZod = BoundWitnessZod.extend(UnsignedSignaturesMetaZod.shape)\nexport type UnsignedBoundWitness = z.infer<typeof UnsignedBoundWitnessZod>\n\nexport const AnyUnsignedBoundWitnessZod = UnsignedBoundWitnessZod.loose()\nexport type AnyUnsignedBoundWitness = z.infer<typeof AnyUnsignedBoundWitnessZod>\n","import type { Hash } from '@xylabs/sdk-js'\nimport type { WithStorageMeta } from '@xyo-network/payload-model'\nimport { isStorageMeta } from '@xyo-network/payload-model'\n\nimport { type BoundWitness, isBoundWitness } from './BoundWitness/index.ts'\n\nexport type QueryBoundWitnessFields = {\n error_hashes?: Hash[]\n query: Hash\n}\n\nexport type UnsignedQueryBoundWitness = BoundWitness & QueryBoundWitnessFields\n\nexport type QueryBoundWitness = UnsignedQueryBoundWitness\n\nexport const isQueryBoundWitness = (x?: unknown): x is QueryBoundWitness => isBoundWitness(x) && (x as QueryBoundWitness)?.query !== undefined\nexport const isQueryBoundWitnessWithStorageMeta = (x?: unknown): x is WithStorageMeta<QueryBoundWitness> => isQueryBoundWitness(x) && isStorageMeta(x)\n"],"mappings":";AAAA,SAAS,YAAY,eAAe;AACpC;AAAA,EACE;AAAA,EAAc;AAAA,EAAc;AAAA,OACvB;AACP,SAAS,YAAY,iBAAiB;AACtC,OAAOA,QAAO;;;ACLP,IAAM,qBAAqB;;;ACAlC,SAAS,cAAc;AACvB,OAAO,OAAO;AAIP,IAAM,oBAAoB,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,EAAE,MAAM,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC;AACxF,IAAM,4BAA4B,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,CAAC;AAC7E,IAAM,0BAA0B,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,MAAM,EAAE,CAAC;;;AFGzE,IAAM,gCAAgCC,GAAE,OAAO;AAAA,EACpD,WAAWA,GAAE,MAAM,UAAU;AAAA,EAC7B,gBAAgBA,GAAE,MAAM,OAAO;AAAA,EAC/B,iBAAiBA,GAAE,MAAM,SAAS;AAAA,EAClC,iBAAiBA,GAAE,MAAM,QAAQ,SAAS,CAAC;AAC7C,CAAC;AAIM,IAAM,sBAAsBA,GAAE,OAAO;AAAA,EAC1C,cAAc,WAAW,SAAS;AAAA,EAClC,cAAc,QAAQ,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ources":["../../src/BoundWitness/BoundWitness.ts","../../src/BoundWitness/BoundWitnessSchema.ts","../../src/BoundWitness/Signatures.ts","../../src/BoundWitness/BoundWitnessJsonSchema.ts","../../src/BoundWitness/SignedBoundWitness.ts","../../src/BoundWitness/UnsignedBoundWitness.ts","../../src/QueryBoundWitness.ts"],"sourcesContent":["import { AddressZod, HashZod } from '@xylabs/sdk-js'\nimport {\n zodAsFactory, zodIsFactory, zodToFactory,\n} from '@xylabs/zod'\nimport { PayloadZod, SchemaZod } from '@xyo-network/payload-model'\nimport z from 'zod'\n\nimport { BoundWitnessSchema } from './BoundWitnessSchema.ts'\nimport { SignaturesMetaZod } from './Signatures.ts'\n\nexport const BoundWitnessRequiredFieldsZod = z.object({\n addresses: z.array(AddressZod),\n payload_hashes: z.array(HashZod),\n payload_schemas: z.array(SchemaZod),\n previous_hashes: z.array(HashZod.nullable()),\n})\n\nexport type BoundWitnessRequiredFields = z.infer<typeof BoundWitnessRequiredFieldsZod>\n\nexport const BoundWitnessMetaZod = z.object({\n $destination: AddressZod.optional(),\n $sourceQuery: HashZod.optional(),\n}).extend(SignaturesMetaZod.shape)\n\nexport type BoundWitnessMeta = z.infer<typeof BoundWitnessMetaZod>\n\nexport const BoundWitnessZod = PayloadZod\n .safeExtend({ schema: z.literal(BoundWitnessSchema) })\n .safeExtend(BoundWitnessRequiredFieldsZod.shape)\n .safeExtend(BoundWitnessMetaZod.shape)\n // .refine(data => data.$signatures.length === data.addresses.length, { message: '$signatures length must equal addresses length' })\n\nexport type BoundWitness = z.infer<typeof BoundWitnessZod>\n\nexport const isBoundWitness = zodIsFactory(BoundWitnessZod)\nexport const asBoundWitness = zodAsFactory(BoundWitnessZod, 'asBoundWitness')\nexport const toBoundWitness = zodToFactory(BoundWitnessZod, 'toBoundWitness')\n\nexport const AnyBoundWitnessZod = BoundWitnessZod.loose()\nexport type AnyBoundWitness = z.infer<typeof AnyBoundWitnessZod>\n","export const BoundWitnessSchema = 'network.xyo.boundwitness' as const\nexport type BoundWitnessSchema = typeof BoundWitnessSchema\n","import { HexZod } from '@xylabs/sdk-js'\nimport z from 'zod'\n\nimport type { BoundWitness } from './BoundWitness.ts'\n\nexport const SignaturesMetaZod = z.object({ $signatures: z.array(z.union([HexZod, z.null()])) })\nexport const UnsignedSignaturesMetaZod = z.object({ $signatures: z.array(z.null()) })\nexport const SignedSignaturesMetaZod = z.object({ $signatures: z.array(HexZod) })\n\nexport type SignaturesMeta = z.infer<typeof SignaturesMetaZod>\nexport type UnsignedSignaturesMeta = z.infer<typeof UnsignedSignaturesMetaZod>\nexport type SignedSignaturesMeta = z.infer<typeof SignedSignaturesMetaZod>\n\nexport type Unsigned<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & UnsignedSignaturesMeta\nexport type Signed<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & SignedSignaturesMeta\n","// Should type as JSONSchemaType<BoundWitness> once ajv/eslint issue is fixed\n// https://github.com/microsoft/TypeScript/issues/44851\n\nexport const BoundWitnessJsonSchema = () => {\n return {\n $id: 'https://schemas.xyo.network/2.0/boundwitness',\n additionalProperties: false,\n properties: {\n addresses: { items: { type: 'string' }, type: 'array' },\n payload_hashes: { items: { type: 'string' }, type: 'array' },\n payload_schemas: { items: { type: 'string' }, type: 'array' },\n previous_hashes: { items: { nullable: true, type: 'string' }, type: 'array' },\n schema: { type: 'string' },\n },\n required: ['addresses', 'payload_hashes', 'payload_schemas', 'previous_hashes', 'schema'],\n type: 'object',\n }\n}\n","import type z from 'zod'\n\nimport { BoundWitnessZod } from './BoundWitness.ts'\nimport { SignedSignaturesMetaZod } from './Signatures.ts'\n\nexport const SignedBoundWitnessZod = BoundWitnessZod.extend(SignedSignaturesMetaZod.shape)\nexport type SignedBoundWitness = z.infer<typeof SignedBoundWitnessZod>\n\nexport const AnySignedBoundWitnessZod = SignedBoundWitnessZod.loose()\nexport type AnySignedBoundWitness = z.infer<typeof AnySignedBoundWitnessZod>\n","import type z from 'zod'\n\nimport { BoundWitnessZod } from './BoundWitness.ts'\nimport { UnsignedSignaturesMetaZod } from './Signatures.ts'\n\nexport const UnsignedBoundWitnessZod = BoundWitnessZod.extend(UnsignedSignaturesMetaZod.shape)\nexport type UnsignedBoundWitness = z.infer<typeof UnsignedBoundWitnessZod>\n\nexport const AnyUnsignedBoundWitnessZod = UnsignedBoundWitnessZod.loose()\nexport type AnyUnsignedBoundWitness = z.infer<typeof AnyUnsignedBoundWitnessZod>\n","import type { Hash } from '@xylabs/sdk-js'\nimport type { WithStorageMeta } from '@xyo-network/payload-model'\nimport { isStorageMeta } from '@xyo-network/payload-model'\n\nimport { type BoundWitness, isBoundWitness } from './BoundWitness/index.ts'\n\nexport type QueryBoundWitnessFields = {\n error_hashes?: Hash[]\n query: Hash\n}\n\nexport type UnsignedQueryBoundWitness = BoundWitness & QueryBoundWitnessFields\n\nexport type QueryBoundWitness = UnsignedQueryBoundWitness\n\nexport const isQueryBoundWitness = (x?: unknown): x is QueryBoundWitness => isBoundWitness(x) && (x as QueryBoundWitness)?.query !== undefined\nexport const isQueryBoundWitnessWithStorageMeta = (x?: unknown): x is WithStorageMeta<QueryBoundWitness> => isQueryBoundWitness(x) && isStorageMeta(x)\n"],"mappings":";AAAA,SAAS,YAAY,eAAe;AACpC;AAAA,EACE;AAAA,EAAc;AAAA,EAAc;AAAA,OACvB;AACP,SAAS,YAAY,iBAAiB;AACtC,OAAOA,QAAO;;;ACLP,IAAM,qBAAqB;;;ACAlC,SAAS,cAAc;AACvB,OAAO,OAAO;AAIP,IAAM,oBAAoB,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,EAAE,MAAM,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC;AACxF,IAAM,4BAA4B,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,CAAC;AAC7E,IAAM,0BAA0B,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,MAAM,EAAE,CAAC;;;AFGz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lF,IAAM,2BAA2B,sBAAsB,MAAM;;;ACH7D,IAAM,0BAA0B,gBAAgB,OAAO,0BAA0B,KAAK;AAGtF,IAAM,6BAA6B,wBAAwB,MAAM;;;ACNxE,SAAS,qBAAqB;AAavB,IAAM,sBAAsB,CAAC,MAAwC,eAAe,CAAC,KAAM,GAAyB,UAAU;AAC9H,IAAM,qCAAqC,CAAC,MAAyD,oBAAoB,CAAC,KAAK,cAAc,CAAC;","names":["z","z"]}
@@ -12,6 +12,6 @@ export declare const SignedSignaturesMetaZod: z.ZodObject<{
12
12
  export type SignaturesMeta = z.infer<typeof SignaturesMetaZod>;
13
13
  export type UnsignedSignaturesMeta = z.infer<typeof UnsignedSignaturesMetaZod>;
14
14
  export type SignedSignaturesMeta = z.infer<typeof SignedSignaturesMetaZod>;
15
- export type Unsigned<T extends BoundWitness = BoundWitness> = T & UnsignedSignaturesMeta;
16
- export type Signed<T extends BoundWitness = BoundWitness> = T & SignedSignaturesMeta;
15
+ export type Unsigned<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & UnsignedSignaturesMeta;
16
+ export type Signed<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & SignedSignaturesMeta;
17
17
  //# sourceMappingURL=Signatures.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Signatures.d.ts","sourceRoot":"","sources":["../../../src/BoundWitness/Signatures.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAA;AAEnB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAErD,eAAO,MAAM,iBAAiB;;mBAAkE,CAAA;AAChG,eAAO,MAAM,yBAAyB;;mBAA+C,CAAA;AACrF,eAAO,MAAM,uBAAuB;;mBAA6C,CAAA;AAEjF,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAA;AAC9D,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAA;AAC9E,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAA;AAE1E,MAAM,MAAM,QAAQ,CAAC,CAAC,SAAS,YAAY,GAAG,YAAY,IAAI,CAAC,GAAG,sBAAsB,CAAA;AACxF,MAAM,MAAM,MAAM,CAAC,CAAC,SAAS,YAAY,GAAG,YAAY,IAAI,CAAC,GAAG,oBAAoB,CAAA"}
1
+ {"version":3,"file":"Signatures.d.ts","sourceRoot":"","sources":["../../../src/BoundWitness/Signatures.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAA;AAEnB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAErD,eAAO,MAAM,iBAAiB;;mBAAkE,CAAA;AAChG,eAAO,MAAM,yBAAyB;;mBAA+C,CAAA;AACrF,eAAO,MAAM,uBAAuB;;mBAA6C,CAAA;AAEjF,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAA;AAC9D,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAA;AAC9E,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAA;AAE1E,MAAM,MAAM,QAAQ,CAAC,CAAC,SAAS,YAAY,GAAG,YAAY,IAAI,IAAI,CAAC,CAAC,EAAE,aAAa,CAAC,GAAG,sBAAsB,CAAA;AAC7G,MAAM,MAAM,MAAM,CAAC,CAAC,SAAS,YAAY,GAAG,YAAY,IAAI,IAAI,CAAC,CAAC,EAAE,aAAa,CAAC,GAAG,oBAAoB,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/BoundWitness/BoundWitness.ts","../../src/BoundWitness/BoundWitnessSchema.ts","../../src/BoundWitness/Signatures.ts","../../src/BoundWitness/BoundWitnessJsonSchema.ts","../../src/BoundWitness/SignedBoundWitness.ts","../../src/BoundWitness/UnsignedBoundWitness.ts","../../src/QueryBoundWitness.ts"],"sourcesContent":["import { AddressZod, HashZod } from '@xylabs/sdk-js'\nimport {\n zodAsFactory, zodIsFactory, zodToFactory,\n} from '@xylabs/zod'\nimport { PayloadZod, SchemaZod } from '@xyo-network/payload-model'\nimport z from 'zod'\n\nimport { BoundWitnessSchema } from './BoundWitnessSchema.ts'\nimport { SignaturesMetaZod } from './Signatures.ts'\n\nexport const BoundWitnessRequiredFieldsZod = z.object({\n addresses: z.array(AddressZod),\n payload_hashes: z.array(HashZod),\n payload_schemas: z.array(SchemaZod),\n previous_hashes: z.array(HashZod.nullable()),\n})\n\nexport type BoundWitnessRequiredFields = z.infer<typeof BoundWitnessRequiredFieldsZod>\n\nexport const BoundWitnessMetaZod = z.object({\n $destination: AddressZod.optional(),\n $sourceQuery: HashZod.optional(),\n}).extend(SignaturesMetaZod.shape)\n\nexport type BoundWitnessMeta = z.infer<typeof BoundWitnessMetaZod>\n\nexport const BoundWitnessZod = PayloadZod\n .safeExtend({ schema: z.literal(BoundWitnessSchema) })\n .safeExtend(BoundWitnessRequiredFieldsZod.shape)\n .safeExtend(BoundWitnessMetaZod.shape)\n // .refine(data => data.$signatures.length === data.addresses.length, { message: '$signatures length must equal addresses length' })\n\nexport type BoundWitness = z.infer<typeof BoundWitnessZod>\n\nexport const isBoundWitness = zodIsFactory(BoundWitnessZod)\nexport const asBoundWitness = zodAsFactory(BoundWitnessZod, 'asBoundWitness')\nexport const toBoundWitness = zodToFactory(BoundWitnessZod, 'toBoundWitness')\n\nexport const AnyBoundWitnessZod = BoundWitnessZod.loose()\nexport type AnyBoundWitness = z.infer<typeof AnyBoundWitnessZod>\n","export const BoundWitnessSchema = 'network.xyo.boundwitness' as const\nexport type BoundWitnessSchema = typeof BoundWitnessSchema\n","import { HexZod } from '@xylabs/sdk-js'\nimport z from 'zod'\n\nimport type { BoundWitness } from './BoundWitness.ts'\n\nexport const SignaturesMetaZod = z.object({ $signatures: z.array(z.union([HexZod, z.null()])) })\nexport const UnsignedSignaturesMetaZod = z.object({ $signatures: z.array(z.null()) })\nexport const SignedSignaturesMetaZod = z.object({ $signatures: z.array(HexZod) })\n\nexport type SignaturesMeta = z.infer<typeof SignaturesMetaZod>\nexport type UnsignedSignaturesMeta = z.infer<typeof UnsignedSignaturesMetaZod>\nexport type SignedSignaturesMeta = z.infer<typeof SignedSignaturesMetaZod>\n\nexport type Unsigned<T extends BoundWitness = BoundWitness> = T & UnsignedSignaturesMeta\nexport type Signed<T extends BoundWitness = BoundWitness> = T & SignedSignaturesMeta\n","// Should type as JSONSchemaType<BoundWitness> once ajv/eslint issue is fixed\n// https://github.com/microsoft/TypeScript/issues/44851\n\nexport const BoundWitnessJsonSchema = () => {\n return {\n $id: 'https://schemas.xyo.network/2.0/boundwitness',\n additionalProperties: false,\n properties: {\n addresses: { items: { type: 'string' }, type: 'array' },\n payload_hashes: { items: { type: 'string' }, type: 'array' },\n payload_schemas: { items: { type: 'string' }, type: 'array' },\n previous_hashes: { items: { nullable: true, type: 'string' }, type: 'array' },\n schema: { type: 'string' },\n },\n required: ['addresses', 'payload_hashes', 'payload_schemas', 'previous_hashes', 'schema'],\n type: 'object',\n }\n}\n","import type z from 'zod'\n\nimport { BoundWitnessZod } from './BoundWitness.ts'\nimport { SignedSignaturesMetaZod } from './Signatures.ts'\n\nexport const SignedBoundWitnessZod = BoundWitnessZod.extend(SignedSignaturesMetaZod.shape)\nexport type SignedBoundWitness = z.infer<typeof SignedBoundWitnessZod>\n\nexport const AnySignedBoundWitnessZod = SignedBoundWitnessZod.loose()\nexport type AnySignedBoundWitness = z.infer<typeof AnySignedBoundWitnessZod>\n","import type z from 'zod'\n\nimport { BoundWitnessZod } from './BoundWitness.ts'\nimport { UnsignedSignaturesMetaZod } from './Signatures.ts'\n\nexport const UnsignedBoundWitnessZod = BoundWitnessZod.extend(UnsignedSignaturesMetaZod.shape)\nexport type UnsignedBoundWitness = z.infer<typeof UnsignedBoundWitnessZod>\n\nexport const AnyUnsignedBoundWitnessZod = UnsignedBoundWitnessZod.loose()\nexport type AnyUnsignedBoundWitness = z.infer<typeof AnyUnsignedBoundWitnessZod>\n","import type { Hash } from '@xylabs/sdk-js'\nimport type { WithStorageMeta } from '@xyo-network/payload-model'\nimport { isStorageMeta } from '@xyo-network/payload-model'\n\nimport { type BoundWitness, isBoundWitness } from './BoundWitness/index.ts'\n\nexport type QueryBoundWitnessFields = {\n error_hashes?: Hash[]\n query: Hash\n}\n\nexport type UnsignedQueryBoundWitness = BoundWitness & QueryBoundWitnessFields\n\nexport type QueryBoundWitness = UnsignedQueryBoundWitness\n\nexport const isQueryBoundWitness = (x?: unknown): x is QueryBoundWitness => isBoundWitness(x) && (x as QueryBoundWitness)?.query !== undefined\nexport const isQueryBoundWitnessWithStorageMeta = (x?: unknown): x is WithStorageMeta<QueryBoundWitness> => isQueryBoundWitness(x) && isStorageMeta(x)\n"],"mappings":";AAAA,SAAS,YAAY,eAAe;AACpC;AAAA,EACE;AAAA,EAAc;AAAA,EAAc;AAAA,OACvB;AACP,SAAS,YAAY,iBAAiB;AACtC,OAAOA,QAAO;;;ACLP,IAAM,qBAAqB;;;ACAlC,SAAS,cAAc;AACvB,OAAO,OAAO;AAIP,IAAM,oBAAoB,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,EAAE,MAAM,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC;AACxF,IAAM,4BAA4B,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,CAAC;AAC7E,IAAM,0BAA0B,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,MAAM,EAAE,CAAC;;;AFGzE,IAAM,gCAAgCC,GAAE,OAAO;AAAA,EACpD,WAAWA,GAAE,MAAM,UAAU;AAAA,EAC7B,gBAAgBA,GAAE,MAAM,OAAO;AAAA,EAC/B,iBAAiBA,G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AAS,qBAAqB;AAavB,IAAM,sBAAsB,CAAC,MAAwC,eAAe,CAAC,KAAM,GAAyB,UAAU;AAC9H,IAAM,qCAAqC,CAAC,MAAyD,oBAAoB,CAAC,KAAK,cAAc,CAAC;","names":["z","z"]}
1
+ {"version":3,"sources":["../../src/BoundWitness/BoundWitness.ts","../../src/BoundWitness/BoundWitnessSchema.ts","../../src/BoundWitness/Signatures.ts","../../src/BoundWitness/BoundWitnessJsonSchema.ts","../../src/BoundWitness/SignedBoundWitness.ts","../../src/BoundWitness/UnsignedBoundWitness.ts","../../src/QueryBoundWitness.ts"],"sourcesContent":["import { AddressZod, HashZod } from '@xylabs/sdk-js'\nimport {\n zodAsFactory, zodIsFactory, zodToFactory,\n} from '@xylabs/zod'\nimport { PayloadZod, SchemaZod } from '@xyo-network/payload-model'\nimport z from 'zod'\n\nimport { BoundWitnessSchema } from './BoundWitnessSchema.ts'\nimport { SignaturesMetaZod } from './Signatures.ts'\n\nexport const BoundWitnessRequiredFieldsZod = z.object({\n addresses: z.array(AddressZod),\n payload_hashes: z.array(HashZod),\n payload_schemas: z.array(SchemaZod),\n previous_hashes: z.array(HashZod.nullable()),\n})\n\nexport type BoundWitnessRequiredFields = z.infer<typeof BoundWitnessRequiredFieldsZod>\n\nexport const BoundWitnessMetaZod = z.object({\n $destination: AddressZod.optional(),\n $sourceQuery: HashZod.optional(),\n}).extend(SignaturesMetaZod.shape)\n\nexport type BoundWitnessMeta = z.infer<typeof BoundWitnessMetaZod>\n\nexport const BoundWitnessZod = PayloadZod\n .safeExtend({ schema: z.literal(BoundWitnessSchema) })\n .safeExtend(BoundWitnessRequiredFieldsZod.shape)\n .safeExtend(BoundWitnessMetaZod.shape)\n // .refine(data => data.$signatures.length === data.addresses.length, { message: '$signatures length must equal addresses length' })\n\nexport type BoundWitness = z.infer<typeof BoundWitnessZod>\n\nexport const isBoundWitness = zodIsFactory(BoundWitnessZod)\nexport const asBoundWitness = zodAsFactory(BoundWitnessZod, 'asBoundWitness')\nexport const toBoundWitness = zodToFactory(BoundWitnessZod, 'toBoundWitness')\n\nexport const AnyBoundWitnessZod = BoundWitnessZod.loose()\nexport type AnyBoundWitness = z.infer<typeof AnyBoundWitnessZod>\n","export const BoundWitnessSchema = 'network.xyo.boundwitness' as const\nexport type BoundWitnessSchema = typeof BoundWitnessSchema\n","import { HexZod } from '@xylabs/sdk-js'\nimport z from 'zod'\n\nimport type { BoundWitness } from './BoundWitness.ts'\n\nexport const SignaturesMetaZod = z.object({ $signatures: z.array(z.union([HexZod, z.null()])) })\nexport const UnsignedSignaturesMetaZod = z.object({ $signatures: z.array(z.null()) })\nexport const SignedSignaturesMetaZod = z.object({ $signatures: z.array(HexZod) })\n\nexport type SignaturesMeta = z.infer<typeof SignaturesMetaZod>\nexport type UnsignedSignaturesMeta = z.infer<typeof UnsignedSignaturesMetaZod>\nexport type SignedSignaturesMeta = z.infer<typeof SignedSignaturesMetaZod>\n\nexport type Unsigned<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & UnsignedSignaturesMeta\nexport type Signed<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & SignedSignaturesMeta\n","// Should type as JSONSchemaType<BoundWitness> once ajv/eslint issue is fixed\n// https://github.com/microsoft/TypeScript/issues/44851\n\nexport const BoundWitnessJsonSchema = () => {\n return {\n $id: 'https://schemas.xyo.network/2.0/boundwitness',\n additionalProperties: false,\n properties: {\n addresses: { items: { type: 'string' }, type: 'array' },\n payload_hashes: { items: { type: 'string' }, type: 'array' },\n payload_schemas: { items: { type: 'string' }, type: 'array' },\n previous_hashes: { items: { nullable: true, type: 'string' }, type: 'array' },\n schema: { type: 'string' },\n },\n required: ['addresses', 'payload_hashes', 'payload_schemas', 'previous_hashes', 'schema'],\n type: 'object',\n }\n}\n","import type z from 'zod'\n\nimport { BoundWitnessZod } from './BoundWitness.ts'\nimport { SignedSignaturesMetaZod } from './Signatures.ts'\n\nexport const SignedBoundWitnessZod = BoundWitnessZod.extend(SignedSignaturesMetaZod.shape)\nexport type SignedBoundWitness = z.infer<typeof SignedBoundWitnessZod>\n\nexport const AnySignedBoundWitnessZod = SignedBoundWitnessZod.loose()\nexport type AnySignedBoundWitness = z.infer<typeof AnySignedBoundWitnessZod>\n","import type z from 'zod'\n\nimport { BoundWitnessZod } from './BoundWitness.ts'\nimport { UnsignedSignaturesMetaZod } from './Signatures.ts'\n\nexport const UnsignedBoundWitnessZod = BoundWitnessZod.extend(UnsignedSignaturesMetaZod.shape)\nexport type UnsignedBoundWitness = z.infer<typeof UnsignedBoundWitnessZod>\n\nexport const AnyUnsignedBoundWitnessZod = UnsignedBoundWitnessZod.loose()\nexport type AnyUnsignedBoundWitness = z.infer<typeof AnyUnsignedBoundWitnessZod>\n","import type { Hash } from '@xylabs/sdk-js'\nimport type { WithStorageMeta } from '@xyo-network/payload-model'\nimport { isStorageMeta } from '@xyo-network/payload-model'\n\nimport { type BoundWitness, isBoundWitness } from './BoundWitness/index.ts'\n\nexport type QueryBoundWitnessFields = {\n error_hashes?: Hash[]\n query: Hash\n}\n\nexport type UnsignedQueryBoundWitness = BoundWitness & QueryBoundWitnessFields\n\nexport type QueryBoundWitness = UnsignedQueryBoundWitness\n\nexport const isQueryBoundWitness = (x?: unknown): x is QueryBoundWitness => isBoundWitness(x) && (x as QueryBoundWitness)?.query !== undefined\nexport const isQueryBoundWitnessWithStorageMeta = (x?: unknown): x is WithStorageMeta<QueryBoundWitness> => isQueryBoundWitness(x) && isStorageMeta(x)\n"],"mappings":";AAAA,SAAS,YAAY,eAAe;AACpC;AAAA,EACE;AAAA,EAAc;AAAA,EAAc;AAAA,OACvB;AACP,SAAS,YAAY,iBAAiB;AACtC,OAAOA,QAAO;;;ACLP,IAAM,qBAAqB;;;ACAlC,SAAS,cAAc;AACvB,OAAO,OAAO;AAIP,IAAM,oBAAoB,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,EAAE,MAAM,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC,CAAC,EAAE,CA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AM,SAAS;AAAA,IAC3B;AAAA,IACA,UAAU,CAAC,aAAa,kBAAkB,mBAAmB,mBAAmB,QAAQ;AAAA,IACxF,MAAM;AAAA,EACR;AACF;;;ACZO,IAAM,wBAAwB,gBAAgB,OAAO,wBAAwB,KAAK;AAGlF,IAAM,2BAA2B,sBAAsB,MAAM;;;ACH7D,IAAM,0BAA0B,gBAAgB,OAAO,0BAA0B,KAAK;AAGtF,IAAM,6BAA6B,wBAAwB,MAAM;;;ACNxE,SAAS,qBAAqB;AAavB,IAAM,sBAAsB,CAAC,MAAwC,eAAe,CAAC,KAAM,GAAyB,UAAU;AAC9H,IAAM,qCAAqC,CAAC,MAAyD,oBAAoB,CAAC,KAAK,cAAc,CAAC;","names":["z","z"]}
@@ -12,6 +12,6 @@ export declare const SignedSignaturesMetaZod: z.ZodObject<{
12
12
  export type SignaturesMeta = z.infer<typeof SignaturesMetaZod>;
13
13
  export type UnsignedSignaturesMeta = z.infer<typeof UnsignedSignaturesMetaZod>;
14
14
  export type SignedSignaturesMeta = z.infer<typeof SignedSignaturesMetaZod>;
15
- export type Unsigned<T extends BoundWitness = BoundWitness> = T & UnsignedSignaturesMeta;
16
- export type Signed<T extends BoundWitness = BoundWitness> = T & SignedSignaturesMeta;
15
+ export type Unsigned<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & UnsignedSignaturesMeta;
16
+ export type Signed<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & SignedSignaturesMeta;
17
17
  //# sourceMappingURL=Signatures.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Signatures.d.ts","sourceRoot":"","sources":["../../../src/BoundWitness/Signatures.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAA;AAEnB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAErD,eAAO,MAAM,iBAAiB;;mBAAkE,CAAA;AAChG,eAAO,MAAM,yBAAyB;;mBAA+C,CAAA;AACrF,eAAO,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,EAAE,aAAa,CAAC,GAAG,oBAAoB,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/BoundWitness/BoundWitness.ts","../../src/BoundWitness/BoundWitnessSchema.ts","../../src/BoundWitness/Signatures.ts","../../src/BoundWitness/BoundWitnessJsonSchema.ts","../../src/BoundWitness/SignedBoundWitness.ts","../../src/BoundWitness/UnsignedBoundWitness.ts","../../src/QueryBoundWitness.ts"],"sourcesContent":["import { AddressZod, HashZod } from '@xylabs/sdk-js'\nimport {\n zodAsFactory, zodIsFactory, zodToFactory,\n} from '@xylabs/zod'\nimport { PayloadZod, SchemaZod } from '@xyo-network/payload-model'\nimport z from 'zod'\n\nimport { BoundWitnessSchema } from './BoundWitnessSchema.ts'\nimport { SignaturesMetaZod } from './Signatures.ts'\n\nexport const BoundWitnessRequiredFieldsZod = z.object({\n addresses: z.array(AddressZod),\n payload_hashes: z.array(HashZod),\n payload_schemas: z.array(SchemaZod),\n previous_hashes: z.array(HashZod.nullable()),\n})\n\nexport type BoundWitnessRequiredFields = z.infer<typeof BoundWitnessRequiredFieldsZod>\n\nexport const BoundWitnessMetaZod = z.object({\n $destination: AddressZod.optional(),\n $sourceQuery: HashZod.optional(),\n}).extend(SignaturesMetaZod.shape)\n\nexport type BoundWitnessMeta = z.infer<typeof BoundWitnessMetaZod>\n\nexport const BoundWitnessZod = PayloadZod\n .safeExtend({ schema: z.literal(BoundWitnessSchema) })\n .safeExtend(BoundWitnessRequiredFieldsZod.shape)\n .safeExtend(BoundWitnessMetaZod.shape)\n // .refine(data => data.$signatures.length === data.addresses.length, { message: '$signatures length must equal addresses length' })\n\nexport type BoundWitness = z.infer<typeof BoundWitnessZod>\n\nexport const isBoundWitness = zodIsFactory(BoundWitnessZod)\nexport const asBoundWitness = zodAsFactory(BoundWitnessZod, 'asBoundWitness')\nexport const toBoundWitness = zodToFactory(BoundWitnessZod, 'toBoundWitness')\n\nexport const AnyBoundWitnessZod = BoundWitnessZod.loose()\nexport type AnyBoundWitness = z.infer<typeof AnyBoundWitnessZod>\n","export const BoundWitnessSchema = 'network.xyo.boundwitness' as const\nexport type BoundWitnessSchema = typeof BoundWitnessSchema\n","import { HexZod } from '@xylabs/sdk-js'\nimport z from 'zod'\n\nimport type { BoundWitness } from './BoundWitness.ts'\n\nexport const SignaturesMetaZod = z.object({ $signatures: z.array(z.union([HexZod, z.null()])) })\nexport const UnsignedSignaturesMetaZod = z.object({ $signatures: z.array(z.null()) })\nexport const SignedSignaturesMetaZod = z.object({ $signatures: z.array(HexZod) })\n\nexport type SignaturesMeta = z.infer<typeof SignaturesMetaZod>\nexport type UnsignedSignaturesMeta = z.infer<typeof UnsignedSignaturesMetaZod>\nexport type SignedSignaturesMeta = z.infer<typeof SignedSignaturesMetaZod>\n\nexport type Unsigned<T extends BoundWitness = BoundWitness> = T & UnsignedSignaturesMeta\nexport type Signed<T extends BoundWitness = BoundWitness> = T & SignedSignaturesMeta\n","// Should type as JSONSchemaType<BoundWitness> once ajv/eslint issue is fixed\n// https://github.com/microsoft/TypeScript/issues/44851\n\nexport const BoundWitnessJsonSchema = () => {\n return {\n $id: 'https://schemas.xyo.network/2.0/boundwitness',\n additionalProperties: false,\n properties: {\n addresses: { items: { type: 'string' }, type: 'array' },\n payload_hashes: { items: { type: 'string' }, type: 'array' },\n payload_schemas: { items: { type: 'string' }, type: 'array' },\n previous_hashes: { items: { nullable: true, type: 'string' }, type: 'array' },\n schema: { type: 'string' },\n },\n required: ['addresses', 'payload_hashes', 'payload_schemas', 'previous_hashes', 'schema'],\n type: 'object',\n }\n}\n","import type z from 'zod'\n\nimport { BoundWitnessZod } from './BoundWitness.ts'\nimport { SignedSignaturesMetaZod } from './Signatures.ts'\n\nexport const SignedBoundWitnessZod = BoundWitnessZod.extend(SignedSignaturesMetaZod.shape)\nexport type SignedBoundWitness = z.infer<typeof SignedBoundWitnessZod>\n\nexport const AnySignedBoundWitnessZod = SignedBoundWitnessZod.loose()\nexport type AnySignedBoundWitness = z.infer<typeof AnySignedBoundWitnessZod>\n","import type z from 'zod'\n\nimport { BoundWitnessZod } from './BoundWitness.ts'\nimport { UnsignedSignaturesMetaZod } from './Signatures.ts'\n\nexport const UnsignedBoundWitnessZod = BoundWitnessZod.extend(UnsignedSignaturesMetaZod.shape)\nexport type UnsignedBoundWitness = z.infer<typeof UnsignedBoundWitnessZod>\n\nexport const AnyUnsignedBoundWitnessZod = UnsignedBoundWitnessZod.loose()\nexport type AnyUnsignedBoundWitness = z.infer<typeof AnyUnsignedBoundWitnessZod>\n","import type { Hash } from '@xylabs/sdk-js'\nimport type { WithStorageMeta } from '@xyo-network/payload-model'\nimport { isStorageMeta } from '@xyo-network/payload-model'\n\nimport { type BoundWitness, isBoundWitness } from './BoundWitness/index.ts'\n\nexport type QueryBoundWitnessFields = {\n error_hashes?: Hash[]\n query: Hash\n}\n\nexport type UnsignedQueryBoundWitness = BoundWitness & QueryBoundWitnessFields\n\nexport type QueryBoundWitness = UnsignedQueryBoundWitness\n\nexport const isQueryBoundWitness = (x?: unknown): x is QueryBoundWitness => isBoundWitness(x) && (x as QueryBoundWitness)?.query !== undefined\nexport const isQueryBoundWitnessWithStorageMeta = (x?: unknown): x is WithStorageMeta<QueryBoundWitness> => isQueryBoundWitness(x) && isStorageMeta(x)\n"],"mappings":";AAAA,SAAS,YAAY,eAAe;AACpC;AAAA,EACE;AAAA,EAAc;AAAA,EAAc;AAAA,OACvB;AACP,SAAS,YAAY,iBAAiB;AACtC,OAAOA,QAAO;;;ACLP,IAAM,qBAAqB;;;ACAlC,SAAS,cAAc;AACvB,OAAO,OAAO;AAIP,IAAM,oBAAoB,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,EAAE,MAAM,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC;AACxF,IAAM,4BAA4B,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,CAAC;AAC7E,IAAM,0BAA0B,EAAE,OAAO,EAAE,aA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wBAAwB,gBAAgB,OAAO,wBAAwB,KAAK;AAGlF,IAAM,2BAA2B,sBAAsB,MAAM;;;ACH7D,IAAM,0BAA0B,gBAAgB,OAAO,0BAA0B,KAAK;AAGtF,IAAM,6BAA6B,wBAAwB,MAAM;;;ACNxE,SAAS,qBAAqB;AAavB,IAAM,sBAAsB,CAAC,MAAwC,eAAe,CAAC,KAAM,GAAyB,UAAU;AAC9H,IAAM,qCAAqC,CAAC,MAAyD,oBAAoB,CAAC,KAAK,cAAc,CAAC;","names":["z","z"]}
1
+ {"version":3,"sources":["../../src/BoundWitness/BoundWitness.ts","../../src/BoundWitness/BoundWitnessSchema.ts","../../src/BoundWitness/Signatures.ts","../../src/BoundWitness/BoundWitnessJsonSchema.ts","../../src/BoundWitness/SignedBoundWitness.ts","../../src/BoundWitness/UnsignedBoundWitness.ts","../../src/QueryBoundWitness.ts"],"sourcesContent":["import { AddressZod, HashZod } from '@xylabs/sdk-js'\nimport {\n zodAsFactory, zodIsFactory, zodToFactory,\n} from '@xylabs/zod'\nimport { PayloadZod, SchemaZod } from '@xyo-network/payload-model'\nimport z from 'zod'\n\nimport { BoundWitnessSchema } from './BoundWitnessSchema.ts'\nimport { SignaturesMetaZod } from './Signatures.ts'\n\nexport const BoundWitnessRequiredFieldsZod = z.object({\n addresses: z.array(AddressZod),\n payload_hashes: z.array(HashZod),\n payload_schemas: z.array(SchemaZod),\n previous_hashes: z.array(HashZod.nullable()),\n})\n\nexport type BoundWitnessRequiredFields = z.infer<typeof BoundWitnessRequiredFieldsZod>\n\nexport const BoundWitnessMetaZod = z.object({\n $destination: AddressZod.optional(),\n $sourceQuery: HashZod.optional(),\n}).extend(SignaturesMetaZod.shape)\n\nexport type BoundWitnessMeta = z.infer<typeof BoundWitnessMetaZod>\n\nexport const BoundWitnessZod = PayloadZod\n .safeExtend({ schema: z.literal(BoundWitnessSchema) })\n .safeExtend(BoundWitnessRequiredFieldsZod.shape)\n .safeExtend(BoundWitnessMetaZod.shape)\n // .refine(data => data.$signatures.length === data.addresses.length, { message: '$signatures length must equal addresses length' })\n\nexport type BoundWitness = z.infer<typeof BoundWitnessZod>\n\nexport const isBoundWitness = zodIsFactory(BoundWitnessZod)\nexport const asBoundWitness = zodAsFactory(BoundWitnessZod, 'asBoundWitness')\nexport const toBoundWitness = zodToFactory(BoundWitnessZod, 'toBoundWitness')\n\nexport const AnyBoundWitnessZod = BoundWitnessZod.loose()\nexport type AnyBoundWitness = z.infer<typeof AnyBoundWitnessZod>\n","export const BoundWitnessSchema = 'network.xyo.boundwitness' as const\nexport type BoundWitnessSchema = typeof BoundWitnessSchema\n","import { HexZod } from '@xylabs/sdk-js'\nimport z from 'zod'\n\nimport type { BoundWitness } from './BoundWitness.ts'\n\nexport const SignaturesMetaZod = z.object({ $signatures: z.array(z.union([HexZod, z.null()])) })\nexport const UnsignedSignaturesMetaZod = z.object({ $signatures: z.array(z.null()) })\nexport const SignedSignaturesMetaZod = z.object({ $signatures: z.array(HexZod) })\n\nexport type SignaturesMeta = z.infer<typeof SignaturesMetaZod>\nexport type UnsignedSignaturesMeta = z.infer<typeof UnsignedSignaturesMetaZod>\nexport type SignedSignaturesMeta = z.infer<typeof SignedSignaturesMetaZod>\n\nexport type Unsigned<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & UnsignedSignaturesMeta\nexport type Signed<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & SignedSignaturesMeta\n","// Should type as JSONSchemaType<BoundWitness> once ajv/eslint issue is fixed\n// https://github.com/microsoft/TypeScript/issues/44851\n\nexport const BoundWitnessJsonSchema = () => {\n return {\n $id: 'https://schemas.xyo.network/2.0/boundwitness',\n additionalProperties: false,\n properties: {\n addresses: { items: { type: 'string' }, type: 'array' },\n payload_hashes: { items: { type: 'string' }, type: 'array' },\n payload_schemas: { items: { type: 'string' }, type: 'array' },\n previous_hashes: { items: { nullable: true, type: 'string' }, type: 'array' },\n schema: { type: 'string' },\n },\n required: ['addresses', 'payload_hashes', 'payload_schemas', 'previous_hashes', 'schema'],\n type: 'object',\n }\n}\n","import type z from 'zod'\n\nimport { BoundWitnessZod } from './BoundWitness.ts'\nimport { SignedSignaturesMetaZod } from './Signatures.ts'\n\nexport const SignedBoundWitnessZod = BoundWitnessZod.extend(SignedSignaturesMetaZod.shape)\nexport type SignedBoundWitness = z.infer<typeof SignedBoundWitnessZod>\n\nexport const AnySignedBoundWitnessZod = SignedBoundWitnessZod.loose()\nexport type AnySignedBoundWitness = z.infer<typeof AnySignedBoundWitnessZod>\n","import type z from 'zod'\n\nimport { BoundWitnessZod } from './BoundWitness.ts'\nimport { UnsignedSignaturesMetaZod } from './Signatures.ts'\n\nexport const UnsignedBoundWitnessZod = BoundWitnessZod.extend(UnsignedSignaturesMetaZod.shape)\nexport type UnsignedBoundWitness = z.infer<typeof UnsignedBoundWitnessZod>\n\nexport const AnyUnsignedBoundWitnessZod = UnsignedBoundWitnessZod.loose()\nexport type AnyUnsignedBoundWitness = z.infer<typeof AnyUnsignedBoundWitnessZod>\n","import type { Hash } from '@xylabs/sdk-js'\nimport type { WithStorageMeta } from '@xyo-network/payload-model'\nimport { isStorageMeta } from '@xyo-network/payload-model'\n\nimport { type BoundWitness, isBoundWitness } from './BoundWitness/index.ts'\n\nexport type QueryBoundWitnessFields = {\n error_hashes?: Hash[]\n query: Hash\n}\n\nexport type UnsignedQueryBoundWitness = BoundWitness & QueryBoundWitnessFields\n\nexport type QueryBoundWitness = UnsignedQueryBoundWitness\n\nexport const isQueryBoundWitness = (x?: unknown): x is QueryBoundWitness => isBoundWitness(x) && (x as QueryBoundWitness)?.query !== undefined\nexport const isQueryBoundWitnessWithStorageMeta = (x?: unknown): x is WithStorageMeta<QueryBoundWitness> => isQueryBoundWitness(x) && isStorageMeta(x)\n"],"mappings":";AAAA,SAAS,YAAY,eAAe;AACpC;AAAA,EACE;AAAA,EAAc;AAAA,EAAc;AAAA,OACvB;AACP,SAAS,YAAY,iBAAiB;AACtC,OAAOA,QAAO;;;ACLP,I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3D,iBAAiB,EAAE,OAAO,EAAE,MAAM,SAAS,GAAG,MAAM,QAAQ;AAAA,MAC5D,iBAAiB,EAAE,OAAO,EAAE,UAAU,MAAM,MAAM,SAAS,GAAG,MAAM,QAAQ;AAAA,MAC5E,QAAQ,EAAE,MAAM,SAAS;AAAA,IAC3B;AAAA,IACA,UAAU,CAAC,aAAa,kBAAkB,mBAAmB,mBAAmB,QAAQ;AAAA,IACxF,MAAM;AAAA,EACR;AACF;;;ACZO,IAAM,wBAAwB,gBAAgB,OAAO,wBAAwB,KAAK;AAGlF,IAAM,2BAA2B,sBAAsB,MAAM;;;ACH7D,IAAM,0BAA0B,gBAAgB,OAAO,0BAA0B,KAAK;AAGtF,IAAM,6BAA6B,wBAAwB,MAAM;;;ACNxE,SAAS,qBAAqB;AAavB,IAAM,sBAAsB,CAAC,MAAwC,eAAe,CAAC,KAAM,GAAyB,UAAU;AAC9H,IAAM,qCAAqC,CAAC,MAAyD,oBAAoB,CAAC,KAAK,cAAc,CAAC;","names":["z","z"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xyo-network/boundwitness-model",
3
- "version": "5.2.7",
3
+ "version": "5.2.8",
4
4
  "description": "Primary SDK for using XYO Protocol 2.0",
5
5
  "homepage": "https://xyo.network",
6
6
  "bugs": {
@@ -38,7 +38,7 @@
38
38
  "dependencies": {
39
39
  "@xylabs/sdk-js": "~5.0.42",
40
40
  "@xylabs/zod": "~5.0.42",
41
- "@xyo-network/payload-model": "~5.2.7",
41
+ "@xyo-network/payload-model": "~5.2.8",
42
42
  "zod": "~4.1.12"
43
43
  },
44
44
  "devDependencies": {
@@ -11,5 +11,5 @@ export type SignaturesMeta = z.infer<typeof SignaturesMetaZod>
11
11
  export type UnsignedSignaturesMeta = z.infer<typeof UnsignedSignaturesMetaZod>
12
12
  export type SignedSignaturesMeta = z.infer<typeof SignedSignaturesMetaZod>
13
13
 
14
- export type Unsigned<T extends BoundWitness = BoundWitness> = T & UnsignedSignaturesMeta
15
- export type Signed<T extends BoundWitness = BoundWitness> = T & SignedSignaturesMeta
14
+ export type Unsigned<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & UnsignedSignaturesMeta
15
+ export type Signed<T extends BoundWitness = BoundWitness> = Omit<T, '$signatures'> & SignedSignaturesMeta