@tinycloud/sdk-core 3.0.0-beta.7 → 3.0.0-beta.9

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.
@@ -3494,108 +3494,10 @@ declare function validateOwnerSharePolicyRegistration(value: unknown, expected:
3494
3494
  /** Validate the exact UTF-8 response bytes emitted by the registration route. */
3495
3495
  declare function validateOwnerSharePolicyRegistrationBytes(bytesValue: Uint8Array, expected: RegisterOwnerSharePolicyParams): OwnerSharePolicyRegistrationReceipt;
3496
3496
 
3497
- /** Matches V2_DELIVERY_DOMAIN in tinycloud-node-server/src/share_v2.rs. */
3498
- declare const SHARE_DELIVERY_AUTHORIZATION_DOMAIN = "xyz.tinycloud.share/delivery-authorization/v2\0";
3499
- /** Exact camelCase mirror of the Rust `V2DeliveryRequest` wire struct. */
3500
- interface ShareDeliveryAuthorizationRequest {
3501
- readonly envelopeCid: string;
3502
- readonly shareCid: string;
3503
- readonly shareId: string;
3504
- readonly registrationCid: string;
3505
- readonly policyCid: string;
3506
- readonly delegationCid: string;
3507
- readonly enforcementDelegationCid: string;
3508
- readonly recipientEmail: string;
3509
- readonly shareUrl: string;
3510
- readonly documentName: string;
3511
- readonly jti: string;
3512
- readonly idempotencyKey: string;
3513
- readonly expiresAt: string;
3514
- readonly requestBodyDigest: string;
3515
- }
3516
- /** Exact mirror of the `authorization` object the Node route signs and returns. */
3517
- interface ShareDeliveryAuthorization {
3518
- readonly type: "TinyCloudShareDeliveryAuthorization";
3519
- readonly version: 2;
3520
- readonly jti: string;
3521
- readonly shareCid: string;
3522
- readonly shareId: string;
3523
- readonly registrationCid: string;
3524
- readonly delegationCid: string;
3525
- readonly enforcementDelegationCid: string;
3526
- readonly envelopeCid: string;
3527
- readonly policyCid: string;
3528
- readonly nodeAudience: string;
3529
- readonly targetOrigin: string;
3530
- /**
3531
- * The OpenCredentials witness this delivery is scoped to, sourced from
3532
- * Node's own trusted credentials origin. Deliberately distinct from
3533
- * `nodeAudience` (the node's own DID) and `returnOrigin` (Share's page
3534
- * origin) — conflating any of these three would let a party impersonate
3535
- * another's audience.
3536
- */
3537
- readonly openCredentialsAudience: string;
3538
- readonly holder: string;
3539
- readonly recipientMatcher: unknown;
3540
- readonly deliveryEmail: string;
3541
- readonly shareUrl: string;
3542
- readonly returnOrigin: string;
3543
- readonly documentName: string;
3544
- readonly senderDid: string;
3545
- readonly senderTrust: string;
3546
- readonly contentSource: unknown;
3547
- readonly contentSourceDigest: string;
3548
- readonly shareExpiresAt: string;
3549
- readonly issuedAt: string;
3550
- readonly reportAbuseToken: string;
3551
- readonly actions: readonly string[];
3552
- readonly resource: string;
3553
- readonly authorityMaterialHandle: string;
3554
- readonly authorityMaterialDigest: string;
3555
- readonly requestBodyDigest: string;
3556
- readonly idempotencyKey: string;
3557
- readonly expiresAt: string;
3558
- readonly dataAuthority: false;
3559
- }
3560
- interface ShareDeliveryAuthorizationReceipt {
3561
- readonly authorization: ShareDeliveryAuthorization;
3562
- readonly proof: {
3563
- readonly alg: "EdDSA";
3564
- readonly kid: string;
3565
- readonly signature: string;
3566
- };
3567
- }
3568
- interface ValidateShareDeliveryAuthorizationExpected {
3569
- readonly request: ShareDeliveryAuthorizationRequest;
3570
- /** The enrolled receipt key from the node trust bundle. */
3571
- readonly nodeProof: {
3572
- readonly kid: string;
3573
- readonly publicKey: Uint8Array;
3574
- };
3575
- /**
3576
- * The OpenCredentials witness origin the caller trusts, from the same
3577
- * trust bundle as `nodeProof`. Validated independently of the
3578
- * authorization's own `nodeAudience`/`returnOrigin` fields so a Node that
3579
- * mislabels or omits its credentials origin fails closed here rather than
3580
- * silently inheriting one of those unrelated identities.
3581
- */
3582
- readonly credentialsAudience: string;
3583
- }
3584
- /**
3585
- * Validate the exact UTF-8 response bytes emitted by
3586
- * `POST /share/v2/deliveries/authorize`, bind them to the submitted
3587
- * request, and verify the Node's detached EdDSA proof.
3588
- */
3589
- declare function validateShareDeliveryAuthorizationBytes(bytesValue: Uint8Array, expected: ValidateShareDeliveryAuthorizationExpected): ShareDeliveryAuthorizationReceipt;
3590
- /** Build the trusted-signer descriptor `did:key:...#z...` expects from a raw node signing key. */
3591
- declare function shareDeliveryTrustedKid(publicKey: Uint8Array): string;
3592
-
3593
3497
  declare const CREDENTIAL_INVITATION_REQUEST_DOMAIN = "xyz.tinycloud.credentials/invitation-request/v1\0";
3594
3498
  declare const DELIVERY_ADMISSION_DOMAIN = "xyz.tinycloud.policy/delivery-admission/v0\0";
3595
3499
  interface ShareDeliveryAuthorizationV3Request {
3596
3500
  readonly envelope: Record<string, unknown>;
3597
- readonly sealedEnvelope: string;
3598
- readonly envelopeKey: string;
3599
3501
  readonly shareCid: string;
3600
3502
  readonly recipientEmail: string;
3601
3503
  readonly shareUrl: string;
@@ -3612,6 +3514,8 @@ interface CredentialInvitationRequest {
3612
3514
  readonly credentialType: string;
3613
3515
  readonly returnLink: string;
3614
3516
  readonly envelopeRef: string;
3517
+ readonly label: string;
3518
+ readonly shareExpiresAt: string;
3615
3519
  readonly audience: string;
3616
3520
  readonly issuedAt: string;
3617
3521
  readonly expiresAt: string;
@@ -3627,6 +3531,8 @@ interface DeliveryAdmission {
3627
3531
  readonly credentialType: string;
3628
3532
  readonly returnLink: string;
3629
3533
  readonly envelopeRef: string;
3534
+ readonly label: string;
3535
+ readonly shareExpiresAt: string;
3630
3536
  readonly senderKeyDid: string;
3631
3537
  readonly audience: string;
3632
3538
  readonly issuedAt: string;
@@ -3650,7 +3556,7 @@ interface ShareDeliveryAuthorizationV3Receipt {
3650
3556
  declare function validateShareDeliveryAuthorizationV3Bytes(bytes: Uint8Array, expected: {
3651
3557
  readonly request: ShareDeliveryAuthorizationV3Request;
3652
3558
  readonly senderKeyDid: string;
3653
- readonly credentialsAudience: string;
3559
+ readonly deliveryAudience: string;
3654
3560
  }): Omit<ShareDeliveryAuthorizationV3Receipt, "proof">;
3655
3561
 
3656
3562
  /**
@@ -4635,4 +4541,4 @@ declare const ShareNativeResponseSchema: z.ZodDiscriminatedUnion<"action", [z.Zo
4635
4541
  }>]>;
4636
4542
  type ShareNativeResponse = z.infer<typeof ShareNativeResponseSchema>;
4637
4543
 
4638
- export { type OwnerSharePolicyRegistration as $, type AccountDelegationPage as A, type DelegationStatus as B, CREDENTIAL_INVITATION_REQUEST_DOMAIN as C, DelegationManager as D, type DeliveryAdmission as E, type EncodedShareData as F, type GenerateShareParams as G, type ISharingService as H, type ICapabilityKeyRegistry as I, type IngestOptions as J, type JWK as K, type KeyInfo as L, type KeyProvider as M, type KeyType as N, MAX_CONTENT_BYTES as O, MAX_SEALED_SHARE_CONTENT_BYTES as P, MAX_SHARE_ARTIFACT_BYTES as Q, type Result as R, MAX_SHARE_CONTENT_BYTES as S, MemorySenderShareKeyStorage as T, MemorySenderShareRecordStorage as U, MemoryShareCache as V, type OwnerDelegationPermission as W, type OwnerDelegationReceipt as X, type OwnerShareAction as Y, type OwnerShareDecryption as Z, type OwnerShareMatcher as _, type DelegationError as a, type ShareReadInvocationV1 as a$, type OwnerSharePolicyRegistrationReceipt as a0, type OwnerSharePolicyV2 as a1, type PortableDelegationImportReceipt as a2, type ReceiveOptions as a3, type RegisterOwnerSharePolicyParams as a4, SHARE_DELIVERY_AUTHORIZATION_DOMAIN as a5, type SenderShareKeyStorage as a6, type SenderShareRecord as a7, type SenderShareRecordStorage as a8, type SenderShareRevocationScope as a9, type ShareDeliveryAuthorizationRequest as aA, type ShareDeliveryAuthorizationV3Receipt as aB, type ShareDeliveryAuthorizationV3Request as aC, type ShareDetachedProof as aD, ShareEnvelopeError as aE, type ShareEnvelopeV2 as aF, type ShareExpiryBounds as aG, type ShareKvContentSource as aH, type ShareLink as aI, type ShareLinkData as aJ, type ShareLinkLocation as aK, type ShareListEntry as aL, type ShareListResult as aM, type ShareNativeAction as aN, type ShareNativeInvokeEnvelopeV1 as aO, type ShareNativeInvokeErrorResult as aP, type ShareNativeInvokeInput as aQ, type ShareNativeInvokeResult as aR, type ShareNativeInvokeSuccessResult as aS, type ShareNativeResponse as aT, ShareNativeResponseSchema as aU, type SharePolicy as aV, type SharePolicyBinding as aW, type SharePolicySession as aX, type SharePolicySessionV1 as aY, type SharePolicySessionWireV1 as aZ, type PortableDelegation as a_, SenderShareStore as aa, type ShareAccess as ab, ShareAccessError as ac, type ShareAccessV2 as ad, type ShareAction as ae, ShareActionSchema as af, type ShareAddressedDelegationEnvelopeV2 as ag, ShareAddressedDelegationEnvelopeV2Schema as ah, type ShareAddressedDelegationRequestV2 as ai, ShareAddressedDelegationRequestV2Schema as aj, type ShareAddressedDelegationResponseV2 as ak, ShareAddressedDelegationResponseV2Schema as al, type ShareAddressedRecipientMatcher as am, type ShareArtifactInput as an, type ShareArtifactResult as ao, type ShareArtifactV2 as ap, type ShareCache as aq, type ShareCacheEntry as ar, type ShareCacheKey as as, type ShareCacheMetadata as at, type ShareCapabilityLike as au, ShareConflict as av, type ShareContentMetadata as aw, type ShareContentSource as ax, type ShareDeliveryAuthorization as ay, type ShareDeliveryAuthorizationReceipt as az, type AccountDelegationQueryOptions as b, type ShareReadResult as b0, ShareRecipientClient as b1, type ShareRecipientClientOptions as b2, ShareRecipientClientOptionsSchema as b3, type ShareRecipientPolicy as b4, ShareRecipientPolicySchema as b5, type ShareRecipientResult as b6, type ShareRecipientTarget as b7, ShareRecipientTargetSchema as b8, type ShareResource as b9, encryptShareBytes as bA, encryptShareBytesAsync as bB, importPortableDelegation as bC, intersectShareCapabilities as bD, isV2ShareLink as bE, normalizeShareActions as bF, normalizeShareRecipientTarget as bG, normalizeShareResource as bH, parsePortableDelegation as bI, parseShareArtifact as bJ, parseShareUrl as bK, restoreDelegatedShareKey as bL, serializePortableDelegation as bM, shareCapabilityAllows as bN, shareDeliveryTrustedKid as bO, signShareEnvelope as bP, validateOwnerSharePolicyRegistration as bQ, validateOwnerSharePolicyRegistrationBytes as bR, validateShareDeliveryAuthorizationBytes as bS, validateShareDeliveryAuthorizationV3Bytes as bT, verifyShareCid as bU, verifyShareEnvelope as bV, CapabilityKeyRegistry as bW, type CapabilityKeyRegistryErrorCode as bX, CapabilityKeyRegistryErrorCodes as bY, type StoredDelegationChain as bZ, createCapabilityKeyRegistry as b_, ShareResourceSchema as ba, type ShareSaveOptions as bb, type ShareSchema as bc, type ShareSqlContentSource as bd, type ShareWireAction as be, SharingService as bf, type SharingServiceConfig as bg, type SignedDelegation as bh, type SpaceInfo as bi, type SpaceOwnership as bj, type ValidateShareDeliveryAuthorizationExpected as bk, type VerifyShareEnvelopeOptions as bl, canonicalOwnerSharePolicy as bm, computeOwnerShareRegistrationCid as bn, computeShareCid as bo, createDelegatedShareKey as bp, createPolicyEnforcementDelegation as bq, createShareArtifact as br, createShareArtifactAsync as bs, createSharePolicy as bt, createSharingService as bu, decryptShareBytesAsync as bv, delegatePortablePolicySession as bw, encodeInlineShareUrl as bx, encodeShareArtifact as by, encodeShareUrl as bz, type AccountDelegationRecord as c, type AccountDelegationResource as d, type CapabilityEntry as e, type CreateDelegationParams as f, type CreateDelegationWasmParams as g, type CreateDelegationWasmResult as h, type CreateOwnerDelegationParams as i, type CredentialInvitationRequest as j, DELIVERY_ADMISSION_DOMAIN as k, type DelegateReceivedShareParams as l, type DelegatedResource as m, type DelegatedShareAccess as n, type DelegatedShareKey as o, type Delegation as p, type DelegationApiResponse as q, type DelegationChain as r, type DelegationChainV2 as s, type DelegationDirection as t, type DelegationErrorCode as u, DelegationErrorCodes as v, type DelegationFilters as w, type DelegationManagerConfig as x, type DelegationRecord as y, type DelegationRevocationReceipt as z };
4544
+ export { type OwnerSharePolicyRegistration as $, type AccountDelegationPage as A, type DelegationStatus as B, CREDENTIAL_INVITATION_REQUEST_DOMAIN as C, DelegationManager as D, type DeliveryAdmission as E, type EncodedShareData as F, type GenerateShareParams as G, type ISharingService as H, type ICapabilityKeyRegistry as I, type IngestOptions as J, type JWK as K, type KeyInfo as L, type KeyProvider as M, type KeyType as N, MAX_CONTENT_BYTES as O, MAX_SEALED_SHARE_CONTENT_BYTES as P, MAX_SHARE_ARTIFACT_BYTES as Q, type Result as R, MAX_SHARE_CONTENT_BYTES as S, MemorySenderShareKeyStorage as T, MemorySenderShareRecordStorage as U, MemoryShareCache as V, type OwnerDelegationPermission as W, type OwnerDelegationReceipt as X, type OwnerShareAction as Y, type OwnerShareDecryption as Z, type OwnerShareMatcher as _, type DelegationError as a, ShareRecipientClientOptionsSchema as a$, type OwnerSharePolicyRegistrationReceipt as a0, type OwnerSharePolicyV2 as a1, type PortableDelegationImportReceipt as a2, type ReceiveOptions as a3, type RegisterOwnerSharePolicyParams as a4, type SenderShareKeyStorage as a5, type SenderShareRecord as a6, type SenderShareRecordStorage as a7, type SenderShareRevocationScope as a8, SenderShareStore as a9, ShareEnvelopeError as aA, type ShareEnvelopeV2 as aB, type ShareExpiryBounds as aC, type ShareKvContentSource as aD, type ShareLink as aE, type ShareLinkData as aF, type ShareLinkLocation as aG, type ShareListEntry as aH, type ShareListResult as aI, type ShareNativeAction as aJ, type ShareNativeInvokeEnvelopeV1 as aK, type ShareNativeInvokeErrorResult as aL, type ShareNativeInvokeInput as aM, type ShareNativeInvokeResult as aN, type ShareNativeInvokeSuccessResult as aO, type ShareNativeResponse as aP, ShareNativeResponseSchema as aQ, type SharePolicy as aR, type SharePolicyBinding as aS, type SharePolicySession as aT, type SharePolicySessionV1 as aU, type SharePolicySessionWireV1 as aV, type PortableDelegation as aW, type ShareReadInvocationV1 as aX, type ShareReadResult as aY, ShareRecipientClient as aZ, type ShareRecipientClientOptions as a_, type ShareAccess as aa, ShareAccessError as ab, type ShareAccessV2 as ac, type ShareAction as ad, ShareActionSchema as ae, type ShareAddressedDelegationEnvelopeV2 as af, ShareAddressedDelegationEnvelopeV2Schema as ag, type ShareAddressedDelegationRequestV2 as ah, ShareAddressedDelegationRequestV2Schema as ai, type ShareAddressedDelegationResponseV2 as aj, ShareAddressedDelegationResponseV2Schema as ak, type ShareAddressedRecipientMatcher as al, type ShareArtifactInput as am, type ShareArtifactResult as an, type ShareArtifactV2 as ao, type ShareCache as ap, type ShareCacheEntry as aq, type ShareCacheKey as ar, type ShareCacheMetadata as as, type ShareCapabilityLike as at, ShareConflict as au, type ShareContentMetadata as av, type ShareContentSource as aw, type ShareDeliveryAuthorizationV3Receipt as ax, type ShareDeliveryAuthorizationV3Request as ay, type ShareDetachedProof as az, type AccountDelegationQueryOptions as b, type ShareRecipientPolicy as b0, ShareRecipientPolicySchema as b1, type ShareRecipientResult as b2, type ShareRecipientTarget as b3, ShareRecipientTargetSchema as b4, type ShareResource as b5, ShareResourceSchema as b6, type ShareSaveOptions as b7, type ShareSchema as b8, type ShareSqlContentSource as b9, normalizeShareActions as bA, normalizeShareRecipientTarget as bB, normalizeShareResource as bC, parsePortableDelegation as bD, parseShareArtifact as bE, parseShareUrl as bF, restoreDelegatedShareKey as bG, serializePortableDelegation as bH, shareCapabilityAllows as bI, signShareEnvelope as bJ, validateOwnerSharePolicyRegistration as bK, validateOwnerSharePolicyRegistrationBytes as bL, validateShareDeliveryAuthorizationV3Bytes as bM, verifyShareCid as bN, verifyShareEnvelope as bO, CapabilityKeyRegistry as bP, type CapabilityKeyRegistryErrorCode as bQ, CapabilityKeyRegistryErrorCodes as bR, type StoredDelegationChain as bS, createCapabilityKeyRegistry as bT, type ShareWireAction as ba, SharingService as bb, type SharingServiceConfig as bc, type SignedDelegation as bd, type SpaceInfo as be, type SpaceOwnership as bf, type VerifyShareEnvelopeOptions as bg, canonicalOwnerSharePolicy as bh, computeOwnerShareRegistrationCid as bi, computeShareCid as bj, createDelegatedShareKey as bk, createPolicyEnforcementDelegation as bl, createShareArtifact as bm, createShareArtifactAsync as bn, createSharePolicy as bo, createSharingService as bp, decryptShareBytesAsync as bq, delegatePortablePolicySession as br, encodeInlineShareUrl as bs, encodeShareArtifact as bt, encodeShareUrl as bu, encryptShareBytes as bv, encryptShareBytesAsync as bw, importPortableDelegation as bx, intersectShareCapabilities as by, isV2ShareLink as bz, type AccountDelegationRecord as c, type AccountDelegationResource as d, type CapabilityEntry as e, type CreateDelegationParams as f, type CreateDelegationWasmParams as g, type CreateDelegationWasmResult as h, type CreateOwnerDelegationParams as i, type CredentialInvitationRequest as j, DELIVERY_ADMISSION_DOMAIN as k, type DelegateReceivedShareParams as l, type DelegatedResource as m, type DelegatedShareAccess as n, type DelegatedShareKey as o, type Delegation as p, type DelegationApiResponse as q, type DelegationChain as r, type DelegationChainV2 as s, type DelegationDirection as t, type DelegationErrorCode as u, DelegationErrorCodes as v, type DelegationFilters as w, type DelegationManagerConfig as x, type DelegationRecord as y, type DelegationRevocationReceipt as z };
@@ -3494,108 +3494,10 @@ declare function validateOwnerSharePolicyRegistration(value: unknown, expected:
3494
3494
  /** Validate the exact UTF-8 response bytes emitted by the registration route. */
3495
3495
  declare function validateOwnerSharePolicyRegistrationBytes(bytesValue: Uint8Array, expected: RegisterOwnerSharePolicyParams): OwnerSharePolicyRegistrationReceipt;
3496
3496
 
3497
- /** Matches V2_DELIVERY_DOMAIN in tinycloud-node-server/src/share_v2.rs. */
3498
- declare const SHARE_DELIVERY_AUTHORIZATION_DOMAIN = "xyz.tinycloud.share/delivery-authorization/v2\0";
3499
- /** Exact camelCase mirror of the Rust `V2DeliveryRequest` wire struct. */
3500
- interface ShareDeliveryAuthorizationRequest {
3501
- readonly envelopeCid: string;
3502
- readonly shareCid: string;
3503
- readonly shareId: string;
3504
- readonly registrationCid: string;
3505
- readonly policyCid: string;
3506
- readonly delegationCid: string;
3507
- readonly enforcementDelegationCid: string;
3508
- readonly recipientEmail: string;
3509
- readonly shareUrl: string;
3510
- readonly documentName: string;
3511
- readonly jti: string;
3512
- readonly idempotencyKey: string;
3513
- readonly expiresAt: string;
3514
- readonly requestBodyDigest: string;
3515
- }
3516
- /** Exact mirror of the `authorization` object the Node route signs and returns. */
3517
- interface ShareDeliveryAuthorization {
3518
- readonly type: "TinyCloudShareDeliveryAuthorization";
3519
- readonly version: 2;
3520
- readonly jti: string;
3521
- readonly shareCid: string;
3522
- readonly shareId: string;
3523
- readonly registrationCid: string;
3524
- readonly delegationCid: string;
3525
- readonly enforcementDelegationCid: string;
3526
- readonly envelopeCid: string;
3527
- readonly policyCid: string;
3528
- readonly nodeAudience: string;
3529
- readonly targetOrigin: string;
3530
- /**
3531
- * The OpenCredentials witness this delivery is scoped to, sourced from
3532
- * Node's own trusted credentials origin. Deliberately distinct from
3533
- * `nodeAudience` (the node's own DID) and `returnOrigin` (Share's page
3534
- * origin) — conflating any of these three would let a party impersonate
3535
- * another's audience.
3536
- */
3537
- readonly openCredentialsAudience: string;
3538
- readonly holder: string;
3539
- readonly recipientMatcher: unknown;
3540
- readonly deliveryEmail: string;
3541
- readonly shareUrl: string;
3542
- readonly returnOrigin: string;
3543
- readonly documentName: string;
3544
- readonly senderDid: string;
3545
- readonly senderTrust: string;
3546
- readonly contentSource: unknown;
3547
- readonly contentSourceDigest: string;
3548
- readonly shareExpiresAt: string;
3549
- readonly issuedAt: string;
3550
- readonly reportAbuseToken: string;
3551
- readonly actions: readonly string[];
3552
- readonly resource: string;
3553
- readonly authorityMaterialHandle: string;
3554
- readonly authorityMaterialDigest: string;
3555
- readonly requestBodyDigest: string;
3556
- readonly idempotencyKey: string;
3557
- readonly expiresAt: string;
3558
- readonly dataAuthority: false;
3559
- }
3560
- interface ShareDeliveryAuthorizationReceipt {
3561
- readonly authorization: ShareDeliveryAuthorization;
3562
- readonly proof: {
3563
- readonly alg: "EdDSA";
3564
- readonly kid: string;
3565
- readonly signature: string;
3566
- };
3567
- }
3568
- interface ValidateShareDeliveryAuthorizationExpected {
3569
- readonly request: ShareDeliveryAuthorizationRequest;
3570
- /** The enrolled receipt key from the node trust bundle. */
3571
- readonly nodeProof: {
3572
- readonly kid: string;
3573
- readonly publicKey: Uint8Array;
3574
- };
3575
- /**
3576
- * The OpenCredentials witness origin the caller trusts, from the same
3577
- * trust bundle as `nodeProof`. Validated independently of the
3578
- * authorization's own `nodeAudience`/`returnOrigin` fields so a Node that
3579
- * mislabels or omits its credentials origin fails closed here rather than
3580
- * silently inheriting one of those unrelated identities.
3581
- */
3582
- readonly credentialsAudience: string;
3583
- }
3584
- /**
3585
- * Validate the exact UTF-8 response bytes emitted by
3586
- * `POST /share/v2/deliveries/authorize`, bind them to the submitted
3587
- * request, and verify the Node's detached EdDSA proof.
3588
- */
3589
- declare function validateShareDeliveryAuthorizationBytes(bytesValue: Uint8Array, expected: ValidateShareDeliveryAuthorizationExpected): ShareDeliveryAuthorizationReceipt;
3590
- /** Build the trusted-signer descriptor `did:key:...#z...` expects from a raw node signing key. */
3591
- declare function shareDeliveryTrustedKid(publicKey: Uint8Array): string;
3592
-
3593
3497
  declare const CREDENTIAL_INVITATION_REQUEST_DOMAIN = "xyz.tinycloud.credentials/invitation-request/v1\0";
3594
3498
  declare const DELIVERY_ADMISSION_DOMAIN = "xyz.tinycloud.policy/delivery-admission/v0\0";
3595
3499
  interface ShareDeliveryAuthorizationV3Request {
3596
3500
  readonly envelope: Record<string, unknown>;
3597
- readonly sealedEnvelope: string;
3598
- readonly envelopeKey: string;
3599
3501
  readonly shareCid: string;
3600
3502
  readonly recipientEmail: string;
3601
3503
  readonly shareUrl: string;
@@ -3612,6 +3514,8 @@ interface CredentialInvitationRequest {
3612
3514
  readonly credentialType: string;
3613
3515
  readonly returnLink: string;
3614
3516
  readonly envelopeRef: string;
3517
+ readonly label: string;
3518
+ readonly shareExpiresAt: string;
3615
3519
  readonly audience: string;
3616
3520
  readonly issuedAt: string;
3617
3521
  readonly expiresAt: string;
@@ -3627,6 +3531,8 @@ interface DeliveryAdmission {
3627
3531
  readonly credentialType: string;
3628
3532
  readonly returnLink: string;
3629
3533
  readonly envelopeRef: string;
3534
+ readonly label: string;
3535
+ readonly shareExpiresAt: string;
3630
3536
  readonly senderKeyDid: string;
3631
3537
  readonly audience: string;
3632
3538
  readonly issuedAt: string;
@@ -3650,7 +3556,7 @@ interface ShareDeliveryAuthorizationV3Receipt {
3650
3556
  declare function validateShareDeliveryAuthorizationV3Bytes(bytes: Uint8Array, expected: {
3651
3557
  readonly request: ShareDeliveryAuthorizationV3Request;
3652
3558
  readonly senderKeyDid: string;
3653
- readonly credentialsAudience: string;
3559
+ readonly deliveryAudience: string;
3654
3560
  }): Omit<ShareDeliveryAuthorizationV3Receipt, "proof">;
3655
3561
 
3656
3562
  /**
@@ -4635,4 +4541,4 @@ declare const ShareNativeResponseSchema: z.ZodDiscriminatedUnion<"action", [z.Zo
4635
4541
  }>]>;
4636
4542
  type ShareNativeResponse = z.infer<typeof ShareNativeResponseSchema>;
4637
4543
 
4638
- export { type OwnerSharePolicyRegistration as $, type AccountDelegationPage as A, type DelegationStatus as B, CREDENTIAL_INVITATION_REQUEST_DOMAIN as C, DelegationManager as D, type DeliveryAdmission as E, type EncodedShareData as F, type GenerateShareParams as G, type ISharingService as H, type ICapabilityKeyRegistry as I, type IngestOptions as J, type JWK as K, type KeyInfo as L, type KeyProvider as M, type KeyType as N, MAX_CONTENT_BYTES as O, MAX_SEALED_SHARE_CONTENT_BYTES as P, MAX_SHARE_ARTIFACT_BYTES as Q, type Result as R, MAX_SHARE_CONTENT_BYTES as S, MemorySenderShareKeyStorage as T, MemorySenderShareRecordStorage as U, MemoryShareCache as V, type OwnerDelegationPermission as W, type OwnerDelegationReceipt as X, type OwnerShareAction as Y, type OwnerShareDecryption as Z, type OwnerShareMatcher as _, type DelegationError as a, type ShareReadInvocationV1 as a$, type OwnerSharePolicyRegistrationReceipt as a0, type OwnerSharePolicyV2 as a1, type PortableDelegationImportReceipt as a2, type ReceiveOptions as a3, type RegisterOwnerSharePolicyParams as a4, SHARE_DELIVERY_AUTHORIZATION_DOMAIN as a5, type SenderShareKeyStorage as a6, type SenderShareRecord as a7, type SenderShareRecordStorage as a8, type SenderShareRevocationScope as a9, type ShareDeliveryAuthorizationRequest as aA, type ShareDeliveryAuthorizationV3Receipt as aB, type ShareDeliveryAuthorizationV3Request as aC, type ShareDetachedProof as aD, ShareEnvelopeError as aE, type ShareEnvelopeV2 as aF, type ShareExpiryBounds as aG, type ShareKvContentSource as aH, type ShareLink as aI, type ShareLinkData as aJ, type ShareLinkLocation as aK, type ShareListEntry as aL, type ShareListResult as aM, type ShareNativeAction as aN, type ShareNativeInvokeEnvelopeV1 as aO, type ShareNativeInvokeErrorResult as aP, type ShareNativeInvokeInput as aQ, type ShareNativeInvokeResult as aR, type ShareNativeInvokeSuccessResult as aS, type ShareNativeResponse as aT, ShareNativeResponseSchema as aU, type SharePolicy as aV, type SharePolicyBinding as aW, type SharePolicySession as aX, type SharePolicySessionV1 as aY, type SharePolicySessionWireV1 as aZ, type PortableDelegation as a_, SenderShareStore as aa, type ShareAccess as ab, ShareAccessError as ac, type ShareAccessV2 as ad, type ShareAction as ae, ShareActionSchema as af, type ShareAddressedDelegationEnvelopeV2 as ag, ShareAddressedDelegationEnvelopeV2Schema as ah, type ShareAddressedDelegationRequestV2 as ai, ShareAddressedDelegationRequestV2Schema as aj, type ShareAddressedDelegationResponseV2 as ak, ShareAddressedDelegationResponseV2Schema as al, type ShareAddressedRecipientMatcher as am, type ShareArtifactInput as an, type ShareArtifactResult as ao, type ShareArtifactV2 as ap, type ShareCache as aq, type ShareCacheEntry as ar, type ShareCacheKey as as, type ShareCacheMetadata as at, type ShareCapabilityLike as au, ShareConflict as av, type ShareContentMetadata as aw, type ShareContentSource as ax, type ShareDeliveryAuthorization as ay, type ShareDeliveryAuthorizationReceipt as az, type AccountDelegationQueryOptions as b, type ShareReadResult as b0, ShareRecipientClient as b1, type ShareRecipientClientOptions as b2, ShareRecipientClientOptionsSchema as b3, type ShareRecipientPolicy as b4, ShareRecipientPolicySchema as b5, type ShareRecipientResult as b6, type ShareRecipientTarget as b7, ShareRecipientTargetSchema as b8, type ShareResource as b9, encryptShareBytes as bA, encryptShareBytesAsync as bB, importPortableDelegation as bC, intersectShareCapabilities as bD, isV2ShareLink as bE, normalizeShareActions as bF, normalizeShareRecipientTarget as bG, normalizeShareResource as bH, parsePortableDelegation as bI, parseShareArtifact as bJ, parseShareUrl as bK, restoreDelegatedShareKey as bL, serializePortableDelegation as bM, shareCapabilityAllows as bN, shareDeliveryTrustedKid as bO, signShareEnvelope as bP, validateOwnerSharePolicyRegistration as bQ, validateOwnerSharePolicyRegistrationBytes as bR, validateShareDeliveryAuthorizationBytes as bS, validateShareDeliveryAuthorizationV3Bytes as bT, verifyShareCid as bU, verifyShareEnvelope as bV, CapabilityKeyRegistry as bW, type CapabilityKeyRegistryErrorCode as bX, CapabilityKeyRegistryErrorCodes as bY, type StoredDelegationChain as bZ, createCapabilityKeyRegistry as b_, ShareResourceSchema as ba, type ShareSaveOptions as bb, type ShareSchema as bc, type ShareSqlContentSource as bd, type ShareWireAction as be, SharingService as bf, type SharingServiceConfig as bg, type SignedDelegation as bh, type SpaceInfo as bi, type SpaceOwnership as bj, type ValidateShareDeliveryAuthorizationExpected as bk, type VerifyShareEnvelopeOptions as bl, canonicalOwnerSharePolicy as bm, computeOwnerShareRegistrationCid as bn, computeShareCid as bo, createDelegatedShareKey as bp, createPolicyEnforcementDelegation as bq, createShareArtifact as br, createShareArtifactAsync as bs, createSharePolicy as bt, createSharingService as bu, decryptShareBytesAsync as bv, delegatePortablePolicySession as bw, encodeInlineShareUrl as bx, encodeShareArtifact as by, encodeShareUrl as bz, type AccountDelegationRecord as c, type AccountDelegationResource as d, type CapabilityEntry as e, type CreateDelegationParams as f, type CreateDelegationWasmParams as g, type CreateDelegationWasmResult as h, type CreateOwnerDelegationParams as i, type CredentialInvitationRequest as j, DELIVERY_ADMISSION_DOMAIN as k, type DelegateReceivedShareParams as l, type DelegatedResource as m, type DelegatedShareAccess as n, type DelegatedShareKey as o, type Delegation as p, type DelegationApiResponse as q, type DelegationChain as r, type DelegationChainV2 as s, type DelegationDirection as t, type DelegationErrorCode as u, DelegationErrorCodes as v, type DelegationFilters as w, type DelegationManagerConfig as x, type DelegationRecord as y, type DelegationRevocationReceipt as z };
4544
+ export { type OwnerSharePolicyRegistration as $, type AccountDelegationPage as A, type DelegationStatus as B, CREDENTIAL_INVITATION_REQUEST_DOMAIN as C, DelegationManager as D, type DeliveryAdmission as E, type EncodedShareData as F, type GenerateShareParams as G, type ISharingService as H, type ICapabilityKeyRegistry as I, type IngestOptions as J, type JWK as K, type KeyInfo as L, type KeyProvider as M, type KeyType as N, MAX_CONTENT_BYTES as O, MAX_SEALED_SHARE_CONTENT_BYTES as P, MAX_SHARE_ARTIFACT_BYTES as Q, type Result as R, MAX_SHARE_CONTENT_BYTES as S, MemorySenderShareKeyStorage as T, MemorySenderShareRecordStorage as U, MemoryShareCache as V, type OwnerDelegationPermission as W, type OwnerDelegationReceipt as X, type OwnerShareAction as Y, type OwnerShareDecryption as Z, type OwnerShareMatcher as _, type DelegationError as a, ShareRecipientClientOptionsSchema as a$, type OwnerSharePolicyRegistrationReceipt as a0, type OwnerSharePolicyV2 as a1, type PortableDelegationImportReceipt as a2, type ReceiveOptions as a3, type RegisterOwnerSharePolicyParams as a4, type SenderShareKeyStorage as a5, type SenderShareRecord as a6, type SenderShareRecordStorage as a7, type SenderShareRevocationScope as a8, SenderShareStore as a9, ShareEnvelopeError as aA, type ShareEnvelopeV2 as aB, type ShareExpiryBounds as aC, type ShareKvContentSource as aD, type ShareLink as aE, type ShareLinkData as aF, type ShareLinkLocation as aG, type ShareListEntry as aH, type ShareListResult as aI, type ShareNativeAction as aJ, type ShareNativeInvokeEnvelopeV1 as aK, type ShareNativeInvokeErrorResult as aL, type ShareNativeInvokeInput as aM, type ShareNativeInvokeResult as aN, type ShareNativeInvokeSuccessResult as aO, type ShareNativeResponse as aP, ShareNativeResponseSchema as aQ, type SharePolicy as aR, type SharePolicyBinding as aS, type SharePolicySession as aT, type SharePolicySessionV1 as aU, type SharePolicySessionWireV1 as aV, type PortableDelegation as aW, type ShareReadInvocationV1 as aX, type ShareReadResult as aY, ShareRecipientClient as aZ, type ShareRecipientClientOptions as a_, type ShareAccess as aa, ShareAccessError as ab, type ShareAccessV2 as ac, type ShareAction as ad, ShareActionSchema as ae, type ShareAddressedDelegationEnvelopeV2 as af, ShareAddressedDelegationEnvelopeV2Schema as ag, type ShareAddressedDelegationRequestV2 as ah, ShareAddressedDelegationRequestV2Schema as ai, type ShareAddressedDelegationResponseV2 as aj, ShareAddressedDelegationResponseV2Schema as ak, type ShareAddressedRecipientMatcher as al, type ShareArtifactInput as am, type ShareArtifactResult as an, type ShareArtifactV2 as ao, type ShareCache as ap, type ShareCacheEntry as aq, type ShareCacheKey as ar, type ShareCacheMetadata as as, type ShareCapabilityLike as at, ShareConflict as au, type ShareContentMetadata as av, type ShareContentSource as aw, type ShareDeliveryAuthorizationV3Receipt as ax, type ShareDeliveryAuthorizationV3Request as ay, type ShareDetachedProof as az, type AccountDelegationQueryOptions as b, type ShareRecipientPolicy as b0, ShareRecipientPolicySchema as b1, type ShareRecipientResult as b2, type ShareRecipientTarget as b3, ShareRecipientTargetSchema as b4, type ShareResource as b5, ShareResourceSchema as b6, type ShareSaveOptions as b7, type ShareSchema as b8, type ShareSqlContentSource as b9, normalizeShareActions as bA, normalizeShareRecipientTarget as bB, normalizeShareResource as bC, parsePortableDelegation as bD, parseShareArtifact as bE, parseShareUrl as bF, restoreDelegatedShareKey as bG, serializePortableDelegation as bH, shareCapabilityAllows as bI, signShareEnvelope as bJ, validateOwnerSharePolicyRegistration as bK, validateOwnerSharePolicyRegistrationBytes as bL, validateShareDeliveryAuthorizationV3Bytes as bM, verifyShareCid as bN, verifyShareEnvelope as bO, CapabilityKeyRegistry as bP, type CapabilityKeyRegistryErrorCode as bQ, CapabilityKeyRegistryErrorCodes as bR, type StoredDelegationChain as bS, createCapabilityKeyRegistry as bT, type ShareWireAction as ba, SharingService as bb, type SharingServiceConfig as bc, type SignedDelegation as bd, type SpaceInfo as be, type SpaceOwnership as bf, type VerifyShareEnvelopeOptions as bg, canonicalOwnerSharePolicy as bh, computeOwnerShareRegistrationCid as bi, computeShareCid as bj, createDelegatedShareKey as bk, createPolicyEnforcementDelegation as bl, createShareArtifact as bm, createShareArtifactAsync as bn, createSharePolicy as bo, createSharingService as bp, decryptShareBytesAsync as bq, delegatePortablePolicySession as br, encodeInlineShareUrl as bs, encodeShareArtifact as bt, encodeShareUrl as bu, encryptShareBytes as bv, encryptShareBytesAsync as bw, importPortableDelegation as bx, intersectShareCapabilities as by, isV2ShareLink as bz, type AccountDelegationRecord as c, type AccountDelegationResource as d, type CapabilityEntry as e, type CreateDelegationParams as f, type CreateDelegationWasmParams as g, type CreateDelegationWasmResult as h, type CreateOwnerDelegationParams as i, type CredentialInvitationRequest as j, DELIVERY_ADMISSION_DOMAIN as k, type DelegateReceivedShareParams as l, type DelegatedResource as m, type DelegatedShareAccess as n, type DelegatedShareKey as o, type Delegation as p, type DelegationApiResponse as q, type DelegationChain as r, type DelegationChainV2 as s, type DelegationDirection as t, type DelegationErrorCode as u, DelegationErrorCodes as v, type DelegationFilters as w, type DelegationManagerConfig as x, type DelegationRecord as y, type DelegationRevocationReceipt as z };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tinycloud/sdk-core",
3
- "version": "3.0.0-beta.7",
3
+ "version": "3.0.0-beta.9",
4
4
  "description": "Core TinyCloud SDK - shared interfaces and TinyCloud class",
5
5
  "author": "TinyCloud, Inc.",
6
6
  "license": "EGPL",
@@ -53,10 +53,10 @@
53
53
  "@multiformats/multiaddr-to-uri": "^12.0.0",
54
54
  "@multiformats/uri-to-multiaddr": "^10.0.0",
55
55
  "@noble/curves": "^1.9.7",
56
- "@tinycloud/share-envelope": "0.2.1-beta.2",
57
- "@tinycloud/share-sdk": "0.3.0-beta.2",
56
+ "@tinycloud/share-envelope": "1.0.0-beta.3",
57
+ "@tinycloud/share-sdk": "1.0.0-beta.3",
58
58
  "@tinycloud/bootstrap": "2.7.0",
59
- "@tinycloud/sdk-services": "2.11.0",
59
+ "@tinycloud/sdk-services": "3.0.0-beta.8",
60
60
  "multiformats": "^13.4.1",
61
61
  "ms": "^2.1.3",
62
62
  "siwe": "^3.0.0",