@tinycloud/sdk-core 2.11.0-beta.0 → 2.11.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/delegations/index.cjs +10 -2
- package/dist/delegations/index.cjs.map +1 -1
- package/dist/delegations/index.d.cts +2 -2
- package/dist/delegations/index.d.ts +2 -2
- package/dist/delegations/index.js +10 -2
- package/dist/delegations/index.js.map +1 -1
- package/dist/index.cjs +10 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +10 -2
- package/dist/index.js.map +1 -1
- package/dist/{recipient-types.schema-B2wH53_t.d.cts → recipient-types.schema-CWIt63Qp.d.cts} +34 -4
- package/dist/{recipient-types.schema-B2wH53_t.d.ts → recipient-types.schema-CWIt63Qp.d.ts} +34 -4
- package/package.json +1 -1
package/dist/{recipient-types.schema-B2wH53_t.d.cts → recipient-types.schema-CWIt63Qp.d.cts}
RENAMED
|
@@ -3229,16 +3229,43 @@ interface OwnerDelegationReceipt {
|
|
|
3229
3229
|
readonly actions: readonly string[];
|
|
3230
3230
|
readonly expiry: Date;
|
|
3231
3231
|
};
|
|
3232
|
+
/** Exact service-scoped capabilities encoded in the signed owner delegation. */
|
|
3233
|
+
readonly permissions: readonly OwnerDelegationPermission[];
|
|
3232
3234
|
}
|
|
3233
|
-
interface
|
|
3234
|
-
|
|
3235
|
-
readonly
|
|
3235
|
+
interface OwnerDelegationPermission {
|
|
3236
|
+
/** Canonical long-form service name, for example `tinycloud.kv`. */
|
|
3237
|
+
readonly service: string;
|
|
3238
|
+
/** Exact service resource path. Encryption permissions use a network URN. */
|
|
3236
3239
|
readonly path: string;
|
|
3240
|
+
/** Canonical full action URNs belonging to `service`. */
|
|
3237
3241
|
readonly actions: readonly string[];
|
|
3242
|
+
}
|
|
3243
|
+
interface CreateOwnerDelegationBase {
|
|
3244
|
+
readonly delegateDid: string;
|
|
3245
|
+
readonly spaceId: string;
|
|
3238
3246
|
readonly expiresAt: Date;
|
|
3239
3247
|
}
|
|
3248
|
+
/**
|
|
3249
|
+
* A wallet-rooted owner delegation accepts either the historical single-path
|
|
3250
|
+
* shape or an exact list of service-scoped permissions. The two forms are
|
|
3251
|
+
* mutually exclusive so callers cannot sign authority from one field while
|
|
3252
|
+
* displaying or persisting a contradictory second field.
|
|
3253
|
+
*/
|
|
3254
|
+
type CreateOwnerDelegationParams = CreateOwnerDelegationBase & ({
|
|
3255
|
+
readonly path: string;
|
|
3256
|
+
readonly actions: readonly string[];
|
|
3257
|
+
readonly permissions?: never;
|
|
3258
|
+
} | {
|
|
3259
|
+
readonly permissions: readonly OwnerDelegationPermission[];
|
|
3260
|
+
readonly path?: never;
|
|
3261
|
+
readonly actions?: never;
|
|
3262
|
+
});
|
|
3240
3263
|
declare const MAX_CONTENT_BYTES: number;
|
|
3241
3264
|
type OwnerShareAction = "tinycloud.kv/get" | "tinycloud.kv/list" | "tinycloud.kv/metadata" | "tinycloud.kv/put";
|
|
3265
|
+
interface OwnerShareDecryption {
|
|
3266
|
+
readonly networkId: string;
|
|
3267
|
+
readonly action: "tinycloud.encryption/decrypt";
|
|
3268
|
+
}
|
|
3242
3269
|
type OwnerShareMatcher = {
|
|
3243
3270
|
readonly kind: "exactEmail";
|
|
3244
3271
|
readonly value: string;
|
|
@@ -3264,6 +3291,7 @@ interface OwnerSharePolicyV2 {
|
|
|
3264
3291
|
readonly path: string;
|
|
3265
3292
|
};
|
|
3266
3293
|
readonly actions: readonly OwnerShareAction[];
|
|
3294
|
+
readonly decryption?: OwnerShareDecryption;
|
|
3267
3295
|
readonly contentSource: {
|
|
3268
3296
|
readonly kind: "kv";
|
|
3269
3297
|
readonly space: string;
|
|
@@ -3331,6 +3359,7 @@ interface OwnerSharePolicyRegistration {
|
|
|
3331
3359
|
readonly path: string;
|
|
3332
3360
|
};
|
|
3333
3361
|
readonly actions: readonly OwnerShareAction[];
|
|
3362
|
+
readonly decryption?: OwnerShareDecryption;
|
|
3334
3363
|
readonly contentSource: {
|
|
3335
3364
|
readonly kind: "kv";
|
|
3336
3365
|
readonly space: string;
|
|
@@ -3374,6 +3403,7 @@ declare function createPolicyEnforcementDelegation(input: {
|
|
|
3374
3403
|
readonly nodeAudience: string;
|
|
3375
3404
|
readonly path: string;
|
|
3376
3405
|
readonly actions: readonly OwnerShareAction[];
|
|
3406
|
+
readonly decryption?: OwnerShareDecryption;
|
|
3377
3407
|
readonly contentSourceDigest: string;
|
|
3378
3408
|
readonly expiresAt: string;
|
|
3379
3409
|
}): Promise<SignedDelegation>;
|
|
@@ -4404,4 +4434,4 @@ declare const ShareNativeResponseSchema: z.ZodDiscriminatedUnion<"action", [z.Zo
|
|
|
4404
4434
|
}>]>;
|
|
4405
4435
|
type ShareNativeResponse = z.infer<typeof ShareNativeResponseSchema>;
|
|
4406
4436
|
|
|
4407
|
-
export { type
|
|
4437
|
+
export { type RegisterOwnerSharePolicyParams as $, type AccountDelegationPage as A, type KeyProvider as B, type CapabilityEntry as C, DelegationManager as D, type EncodedShareData as E, type KeyType as F, type GenerateShareParams as G, MAX_SEALED_SHARE_CONTENT_BYTES as H, type ICapabilityKeyRegistry as I, type JWK as J, type KeyInfo as K, MAX_SHARE_ARTIFACT_BYTES as L, MAX_CONTENT_BYTES as M, MAX_SHARE_CONTENT_BYTES as N, MemorySenderShareKeyStorage as O, MemorySenderShareRecordStorage as P, MemoryShareCache as Q, type Result as R, type OwnerDelegationPermission as S, type OwnerDelegationReceipt as T, type OwnerShareAction as U, type OwnerShareDecryption as V, type OwnerShareMatcher as W, type OwnerSharePolicyRegistration as X, type OwnerSharePolicyRegistrationReceipt as Y, type OwnerSharePolicyV2 as Z, type ReceiveOptions as _, type DelegationError as a, type ShareRecipientTarget as a$, SHARE_DELIVERY_AUTHORIZATION_DOMAIN as a0, type SenderShareKeyStorage as a1, type SenderShareRecord as a2, type SenderShareRecordStorage as a3, type SenderShareRevocationScope as a4, SenderShareStore as a5, type ShareAccess as a6, ShareAccessError as a7, type ShareAccessV2 as a8, type ShareAction as a9, type ShareKvContentSource as aA, type ShareLink as aB, type ShareLinkData as aC, type ShareLinkLocation as aD, type ShareListEntry as aE, type ShareListResult as aF, type ShareNativeAction as aG, type ShareNativeInvokeEnvelopeV1 as aH, type ShareNativeInvokeErrorResult as aI, type ShareNativeInvokeInput as aJ, type ShareNativeInvokeResult as aK, type ShareNativeInvokeSuccessResult as aL, type ShareNativeResponse as aM, ShareNativeResponseSchema as aN, type SharePolicy as aO, type SharePolicyBinding as aP, type SharePolicySession as aQ, type SharePolicySessionV1 as aR, type SharePolicySessionWireV1 as aS, type ShareReadInvocationV1 as aT, type ShareReadResult as aU, ShareRecipientClient as aV, type ShareRecipientClientOptions as aW, ShareRecipientClientOptionsSchema as aX, type ShareRecipientPolicy as aY, ShareRecipientPolicySchema as aZ, type ShareRecipientResult as a_, ShareActionSchema as aa, type ShareAddressedDelegationEnvelopeV2 as ab, ShareAddressedDelegationEnvelopeV2Schema as ac, type ShareAddressedDelegationRequestV2 as ad, ShareAddressedDelegationRequestV2Schema as ae, type ShareAddressedDelegationResponseV2 as af, ShareAddressedDelegationResponseV2Schema as ag, type ShareAddressedRecipientMatcher as ah, type ShareArtifactInput as ai, type ShareArtifactResult as aj, type ShareArtifactV2 as ak, type ShareCache as al, type ShareCacheEntry as am, type ShareCacheKey as an, type ShareCacheMetadata as ao, type ShareCapabilityLike as ap, ShareConflict as aq, type ShareContentMetadata as ar, type ShareContentSource as as, type ShareDeliveryAuthorization as at, type ShareDeliveryAuthorizationReceipt as au, type ShareDeliveryAuthorizationRequest as av, type ShareDetachedProof as aw, ShareEnvelopeError as ax, type ShareEnvelopeV2 as ay, type ShareExpiryBounds as az, type AccountDelegationQueryOptions as b, ShareRecipientTargetSchema as b0, type ShareResource as b1, ShareResourceSchema as b2, type ShareSaveOptions as b3, type ShareSchema as b4, type ShareSqlContentSource as b5, type ShareWireAction as b6, SharingService as b7, type SharingServiceConfig as b8, type SignedDelegation as b9, restoreDelegatedShareKey as bA, shareCapabilityAllows as bB, shareDeliveryTrustedKid as bC, signShareEnvelope as bD, validateOwnerSharePolicyRegistration as bE, validateOwnerSharePolicyRegistrationBytes as bF, validateShareDeliveryAuthorizationBytes as bG, verifyShareCid as bH, verifyShareEnvelope as bI, CapabilityKeyRegistry as bJ, type CapabilityKeyRegistryErrorCode as bK, CapabilityKeyRegistryErrorCodes as bL, type StoredDelegationChain as bM, createCapabilityKeyRegistry as bN, type SpaceInfo as ba, type SpaceOwnership as bb, type ValidateShareDeliveryAuthorizationExpected as bc, type VerifyShareEnvelopeOptions as bd, canonicalOwnerSharePolicy as be, computeOwnerShareRegistrationCid as bf, computeShareCid as bg, createDelegatedShareKey as bh, createPolicyEnforcementDelegation as bi, createShareArtifact as bj, createShareArtifactAsync as bk, createSharePolicy as bl, createSharingService as bm, decryptShareBytesAsync as bn, encodeInlineShareUrl as bo, encodeShareArtifact as bp, encodeShareUrl as bq, encryptShareBytes as br, encryptShareBytesAsync as bs, intersectShareCapabilities as bt, isV2ShareLink as bu, normalizeShareActions as bv, normalizeShareRecipientTarget as bw, normalizeShareResource as bx, parseShareArtifact as by, parseShareUrl as bz, type AccountDelegationRecord as c, type AccountDelegationResource as d, type CreateDelegationParams as e, type CreateDelegationWasmParams as f, type CreateDelegationWasmResult as g, type CreateOwnerDelegationParams as h, type DelegateReceivedShareParams as i, type DelegatedResource as j, type DelegatedShareAccess as k, type DelegatedShareKey as l, type Delegation as m, type DelegationApiResponse as n, type DelegationChain as o, type DelegationChainV2 as p, type DelegationDirection as q, type DelegationErrorCode as r, DelegationErrorCodes as s, type DelegationFilters as t, type DelegationManagerConfig as u, type DelegationRecord as v, type DelegationRevocationReceipt as w, type DelegationStatus as x, type ISharingService as y, type IngestOptions as z };
|
|
@@ -3229,16 +3229,43 @@ interface OwnerDelegationReceipt {
|
|
|
3229
3229
|
readonly actions: readonly string[];
|
|
3230
3230
|
readonly expiry: Date;
|
|
3231
3231
|
};
|
|
3232
|
+
/** Exact service-scoped capabilities encoded in the signed owner delegation. */
|
|
3233
|
+
readonly permissions: readonly OwnerDelegationPermission[];
|
|
3232
3234
|
}
|
|
3233
|
-
interface
|
|
3234
|
-
|
|
3235
|
-
readonly
|
|
3235
|
+
interface OwnerDelegationPermission {
|
|
3236
|
+
/** Canonical long-form service name, for example `tinycloud.kv`. */
|
|
3237
|
+
readonly service: string;
|
|
3238
|
+
/** Exact service resource path. Encryption permissions use a network URN. */
|
|
3236
3239
|
readonly path: string;
|
|
3240
|
+
/** Canonical full action URNs belonging to `service`. */
|
|
3237
3241
|
readonly actions: readonly string[];
|
|
3242
|
+
}
|
|
3243
|
+
interface CreateOwnerDelegationBase {
|
|
3244
|
+
readonly delegateDid: string;
|
|
3245
|
+
readonly spaceId: string;
|
|
3238
3246
|
readonly expiresAt: Date;
|
|
3239
3247
|
}
|
|
3248
|
+
/**
|
|
3249
|
+
* A wallet-rooted owner delegation accepts either the historical single-path
|
|
3250
|
+
* shape or an exact list of service-scoped permissions. The two forms are
|
|
3251
|
+
* mutually exclusive so callers cannot sign authority from one field while
|
|
3252
|
+
* displaying or persisting a contradictory second field.
|
|
3253
|
+
*/
|
|
3254
|
+
type CreateOwnerDelegationParams = CreateOwnerDelegationBase & ({
|
|
3255
|
+
readonly path: string;
|
|
3256
|
+
readonly actions: readonly string[];
|
|
3257
|
+
readonly permissions?: never;
|
|
3258
|
+
} | {
|
|
3259
|
+
readonly permissions: readonly OwnerDelegationPermission[];
|
|
3260
|
+
readonly path?: never;
|
|
3261
|
+
readonly actions?: never;
|
|
3262
|
+
});
|
|
3240
3263
|
declare const MAX_CONTENT_BYTES: number;
|
|
3241
3264
|
type OwnerShareAction = "tinycloud.kv/get" | "tinycloud.kv/list" | "tinycloud.kv/metadata" | "tinycloud.kv/put";
|
|
3265
|
+
interface OwnerShareDecryption {
|
|
3266
|
+
readonly networkId: string;
|
|
3267
|
+
readonly action: "tinycloud.encryption/decrypt";
|
|
3268
|
+
}
|
|
3242
3269
|
type OwnerShareMatcher = {
|
|
3243
3270
|
readonly kind: "exactEmail";
|
|
3244
3271
|
readonly value: string;
|
|
@@ -3264,6 +3291,7 @@ interface OwnerSharePolicyV2 {
|
|
|
3264
3291
|
readonly path: string;
|
|
3265
3292
|
};
|
|
3266
3293
|
readonly actions: readonly OwnerShareAction[];
|
|
3294
|
+
readonly decryption?: OwnerShareDecryption;
|
|
3267
3295
|
readonly contentSource: {
|
|
3268
3296
|
readonly kind: "kv";
|
|
3269
3297
|
readonly space: string;
|
|
@@ -3331,6 +3359,7 @@ interface OwnerSharePolicyRegistration {
|
|
|
3331
3359
|
readonly path: string;
|
|
3332
3360
|
};
|
|
3333
3361
|
readonly actions: readonly OwnerShareAction[];
|
|
3362
|
+
readonly decryption?: OwnerShareDecryption;
|
|
3334
3363
|
readonly contentSource: {
|
|
3335
3364
|
readonly kind: "kv";
|
|
3336
3365
|
readonly space: string;
|
|
@@ -3374,6 +3403,7 @@ declare function createPolicyEnforcementDelegation(input: {
|
|
|
3374
3403
|
readonly nodeAudience: string;
|
|
3375
3404
|
readonly path: string;
|
|
3376
3405
|
readonly actions: readonly OwnerShareAction[];
|
|
3406
|
+
readonly decryption?: OwnerShareDecryption;
|
|
3377
3407
|
readonly contentSourceDigest: string;
|
|
3378
3408
|
readonly expiresAt: string;
|
|
3379
3409
|
}): Promise<SignedDelegation>;
|
|
@@ -4404,4 +4434,4 @@ declare const ShareNativeResponseSchema: z.ZodDiscriminatedUnion<"action", [z.Zo
|
|
|
4404
4434
|
}>]>;
|
|
4405
4435
|
type ShareNativeResponse = z.infer<typeof ShareNativeResponseSchema>;
|
|
4406
4436
|
|
|
4407
|
-
export { type
|
|
4437
|
+
export { type RegisterOwnerSharePolicyParams as $, type AccountDelegationPage as A, type KeyProvider as B, type CapabilityEntry as C, DelegationManager as D, type EncodedShareData as E, type KeyType as F, type GenerateShareParams as G, MAX_SEALED_SHARE_CONTENT_BYTES as H, type ICapabilityKeyRegistry as I, type JWK as J, type KeyInfo as K, MAX_SHARE_ARTIFACT_BYTES as L, MAX_CONTENT_BYTES as M, MAX_SHARE_CONTENT_BYTES as N, MemorySenderShareKeyStorage as O, MemorySenderShareRecordStorage as P, MemoryShareCache as Q, type Result as R, type OwnerDelegationPermission as S, type OwnerDelegationReceipt as T, type OwnerShareAction as U, type OwnerShareDecryption as V, type OwnerShareMatcher as W, type OwnerSharePolicyRegistration as X, type OwnerSharePolicyRegistrationReceipt as Y, type OwnerSharePolicyV2 as Z, type ReceiveOptions as _, type DelegationError as a, type ShareRecipientTarget as a$, SHARE_DELIVERY_AUTHORIZATION_DOMAIN as a0, type SenderShareKeyStorage as a1, type SenderShareRecord as a2, type SenderShareRecordStorage as a3, type SenderShareRevocationScope as a4, SenderShareStore as a5, type ShareAccess as a6, ShareAccessError as a7, type ShareAccessV2 as a8, type ShareAction as a9, type ShareKvContentSource as aA, type ShareLink as aB, type ShareLinkData as aC, type ShareLinkLocation as aD, type ShareListEntry as aE, type ShareListResult as aF, type ShareNativeAction as aG, type ShareNativeInvokeEnvelopeV1 as aH, type ShareNativeInvokeErrorResult as aI, type ShareNativeInvokeInput as aJ, type ShareNativeInvokeResult as aK, type ShareNativeInvokeSuccessResult as aL, type ShareNativeResponse as aM, ShareNativeResponseSchema as aN, type SharePolicy as aO, type SharePolicyBinding as aP, type SharePolicySession as aQ, type SharePolicySessionV1 as aR, type SharePolicySessionWireV1 as aS, type ShareReadInvocationV1 as aT, type ShareReadResult as aU, ShareRecipientClient as aV, type ShareRecipientClientOptions as aW, ShareRecipientClientOptionsSchema as aX, type ShareRecipientPolicy as aY, ShareRecipientPolicySchema as aZ, type ShareRecipientResult as a_, ShareActionSchema as aa, type ShareAddressedDelegationEnvelopeV2 as ab, ShareAddressedDelegationEnvelopeV2Schema as ac, type ShareAddressedDelegationRequestV2 as ad, ShareAddressedDelegationRequestV2Schema as ae, type ShareAddressedDelegationResponseV2 as af, ShareAddressedDelegationResponseV2Schema as ag, type ShareAddressedRecipientMatcher as ah, type ShareArtifactInput as ai, type ShareArtifactResult as aj, type ShareArtifactV2 as ak, type ShareCache as al, type ShareCacheEntry as am, type ShareCacheKey as an, type ShareCacheMetadata as ao, type ShareCapabilityLike as ap, ShareConflict as aq, type ShareContentMetadata as ar, type ShareContentSource as as, type ShareDeliveryAuthorization as at, type ShareDeliveryAuthorizationReceipt as au, type ShareDeliveryAuthorizationRequest as av, type ShareDetachedProof as aw, ShareEnvelopeError as ax, type ShareEnvelopeV2 as ay, type ShareExpiryBounds as az, type AccountDelegationQueryOptions as b, ShareRecipientTargetSchema as b0, type ShareResource as b1, ShareResourceSchema as b2, type ShareSaveOptions as b3, type ShareSchema as b4, type ShareSqlContentSource as b5, type ShareWireAction as b6, SharingService as b7, type SharingServiceConfig as b8, type SignedDelegation as b9, restoreDelegatedShareKey as bA, shareCapabilityAllows as bB, shareDeliveryTrustedKid as bC, signShareEnvelope as bD, validateOwnerSharePolicyRegistration as bE, validateOwnerSharePolicyRegistrationBytes as bF, validateShareDeliveryAuthorizationBytes as bG, verifyShareCid as bH, verifyShareEnvelope as bI, CapabilityKeyRegistry as bJ, type CapabilityKeyRegistryErrorCode as bK, CapabilityKeyRegistryErrorCodes as bL, type StoredDelegationChain as bM, createCapabilityKeyRegistry as bN, type SpaceInfo as ba, type SpaceOwnership as bb, type ValidateShareDeliveryAuthorizationExpected as bc, type VerifyShareEnvelopeOptions as bd, canonicalOwnerSharePolicy as be, computeOwnerShareRegistrationCid as bf, computeShareCid as bg, createDelegatedShareKey as bh, createPolicyEnforcementDelegation as bi, createShareArtifact as bj, createShareArtifactAsync as bk, createSharePolicy as bl, createSharingService as bm, decryptShareBytesAsync as bn, encodeInlineShareUrl as bo, encodeShareArtifact as bp, encodeShareUrl as bq, encryptShareBytes as br, encryptShareBytesAsync as bs, intersectShareCapabilities as bt, isV2ShareLink as bu, normalizeShareActions as bv, normalizeShareRecipientTarget as bw, normalizeShareResource as bx, parseShareArtifact as by, parseShareUrl as bz, type AccountDelegationRecord as c, type AccountDelegationResource as d, type CreateDelegationParams as e, type CreateDelegationWasmParams as f, type CreateDelegationWasmResult as g, type CreateOwnerDelegationParams as h, type DelegateReceivedShareParams as i, type DelegatedResource as j, type DelegatedShareAccess as k, type DelegatedShareKey as l, type Delegation as m, type DelegationApiResponse as n, type DelegationChain as o, type DelegationChainV2 as p, type DelegationDirection as q, type DelegationErrorCode as r, DelegationErrorCodes as s, type DelegationFilters as t, type DelegationManagerConfig as u, type DelegationRecord as v, type DelegationRevocationReceipt as w, type DelegationStatus as x, type ISharingService as y, type IngestOptions as z };
|