@tinycloud/node-sdk 2.4.0-beta.3 → 2.4.0-beta.6

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.
@@ -1,4 +1,4 @@
1
- import { ISessionStorage, PersistedSessionData, AutoSignStrategy, AutoRejectStrategy, CallbackStrategy, IUserAuthorization, ISigner, ISpaceCreationHandler, IWasmBindings, SiweConfig, Manifest, ComposedManifestRequest, ClientSession, TinyCloudSession, Extension, SignInOptions, Delegation, DelegatedResource, PermissionEntry, TelemetryConfig, IKVService, ISQLService, IDuckDbService, IHooksService, INotificationHandler, IENSResolver, IDataVaultService, IEncryptionService, NetworkDescriptor, ISecretsService, ICapabilityKeyRegistry, DelegationManager, ISpaceService, ISpace, ISharingService, CreateDelegationParams, DelegationResult, ResolvedDelegate, KeyProvider, ISessionManager, JWK } from '@tinycloud/sdk-core';
1
+ import { ISessionStorage, PersistedSessionData, AutoSignStrategy, AutoRejectStrategy, CallbackStrategy, IUserAuthorization, ISigner, ISpaceCreationHandler, IWasmBindings, SiweConfig, Manifest, ComposedManifestRequest, ClientSession, TinyCloudSession, Extension, SignInOptions, Delegation, DelegatedResource, PermissionEntry, TelemetryConfig, IKVService, ISQLService, IDuckDbService, IHooksService, INotificationHandler, IENSResolver, AccountService, IDataVaultService, IEncryptionService, NetworkDescriptor, ISecretsService, ICapabilityKeyRegistry, DelegationManager, ISpaceService, ISpace, ISharingService, CreateDelegationParams, DelegationResult, ResolvedDelegate, KeyProvider, ISessionManager, JWK } from '@tinycloud/sdk-core';
2
2
  import { EventEmitter } from 'events';
3
3
  import { InvokeFunction } from '@tinycloud/sdk-services';
4
4
 
@@ -859,6 +859,7 @@ declare class TinyCloudNode {
859
859
  private _encryption?;
860
860
  private _baseSecrets?;
861
861
  private _secrets?;
862
+ private _account?;
862
863
  /** Cached public KV with proper delegation (set by ensurePublicSpace) */
863
864
  private _publicKV?;
864
865
  /** Session key ID - always available */
@@ -961,6 +962,15 @@ declare class TinyCloudNode {
961
962
  * Available after signIn().
962
963
  */
963
964
  get spaceId(): string | undefined;
965
+ /**
966
+ * Get the account space ID for this wallet identity.
967
+ * Available after wallet-backed sign-in or a restored session with address metadata.
968
+ */
969
+ get accountSpaceId(): string | undefined;
970
+ /**
971
+ * Account-level application and delegation helpers.
972
+ */
973
+ get account(): AccountService;
964
974
  /**
965
975
  * Get the current TinyCloud session.
966
976
  * Available after signIn().
@@ -976,6 +986,8 @@ declare class TinyCloudNode {
976
986
  signIn(options?: SignInOptions): Promise<void>;
977
987
  private ownedSpaceId;
978
988
  private writeManifestRegistryRecords;
989
+ private requestedEncryptionNetworkIds;
990
+ private ensureRequestedEncryptionNetworks;
979
991
  private ensureOwnedSpaceHosted;
980
992
  /**
981
993
  * Host one of this user's owned spaces by name (e.g. `"applications"`).
@@ -1192,7 +1204,7 @@ declare class TinyCloudNode {
1192
1204
  get encryption(): IEncryptionService;
1193
1205
  getEncryptionNetwork(nameOrNetworkId?: string): Promise<NetworkDescriptor | null>;
1194
1206
  createEncryptionNetwork(name?: string): Promise<NetworkDescriptor>;
1195
- ensureEncryptionNetwork(name?: string): Promise<NetworkDescriptor>;
1207
+ ensureEncryptionNetwork(nameOrNetworkId?: string): Promise<NetworkDescriptor>;
1196
1208
  /**
1197
1209
  * App-facing secrets API backed by the `secrets` space vault.
1198
1210
  */
@@ -1,4 +1,4 @@
1
- import { ISessionStorage, PersistedSessionData, AutoSignStrategy, AutoRejectStrategy, CallbackStrategy, IUserAuthorization, ISigner, ISpaceCreationHandler, IWasmBindings, SiweConfig, Manifest, ComposedManifestRequest, ClientSession, TinyCloudSession, Extension, SignInOptions, Delegation, DelegatedResource, PermissionEntry, TelemetryConfig, IKVService, ISQLService, IDuckDbService, IHooksService, INotificationHandler, IENSResolver, IDataVaultService, IEncryptionService, NetworkDescriptor, ISecretsService, ICapabilityKeyRegistry, DelegationManager, ISpaceService, ISpace, ISharingService, CreateDelegationParams, DelegationResult, ResolvedDelegate, KeyProvider, ISessionManager, JWK } from '@tinycloud/sdk-core';
1
+ import { ISessionStorage, PersistedSessionData, AutoSignStrategy, AutoRejectStrategy, CallbackStrategy, IUserAuthorization, ISigner, ISpaceCreationHandler, IWasmBindings, SiweConfig, Manifest, ComposedManifestRequest, ClientSession, TinyCloudSession, Extension, SignInOptions, Delegation, DelegatedResource, PermissionEntry, TelemetryConfig, IKVService, ISQLService, IDuckDbService, IHooksService, INotificationHandler, IENSResolver, AccountService, IDataVaultService, IEncryptionService, NetworkDescriptor, ISecretsService, ICapabilityKeyRegistry, DelegationManager, ISpaceService, ISpace, ISharingService, CreateDelegationParams, DelegationResult, ResolvedDelegate, KeyProvider, ISessionManager, JWK } from '@tinycloud/sdk-core';
2
2
  import { EventEmitter } from 'events';
3
3
  import { InvokeFunction } from '@tinycloud/sdk-services';
4
4
 
@@ -859,6 +859,7 @@ declare class TinyCloudNode {
859
859
  private _encryption?;
860
860
  private _baseSecrets?;
861
861
  private _secrets?;
862
+ private _account?;
862
863
  /** Cached public KV with proper delegation (set by ensurePublicSpace) */
863
864
  private _publicKV?;
864
865
  /** Session key ID - always available */
@@ -961,6 +962,15 @@ declare class TinyCloudNode {
961
962
  * Available after signIn().
962
963
  */
963
964
  get spaceId(): string | undefined;
965
+ /**
966
+ * Get the account space ID for this wallet identity.
967
+ * Available after wallet-backed sign-in or a restored session with address metadata.
968
+ */
969
+ get accountSpaceId(): string | undefined;
970
+ /**
971
+ * Account-level application and delegation helpers.
972
+ */
973
+ get account(): AccountService;
964
974
  /**
965
975
  * Get the current TinyCloud session.
966
976
  * Available after signIn().
@@ -976,6 +986,8 @@ declare class TinyCloudNode {
976
986
  signIn(options?: SignInOptions): Promise<void>;
977
987
  private ownedSpaceId;
978
988
  private writeManifestRegistryRecords;
989
+ private requestedEncryptionNetworkIds;
990
+ private ensureRequestedEncryptionNetworks;
979
991
  private ensureOwnedSpaceHosted;
980
992
  /**
981
993
  * Host one of this user's owned spaces by name (e.g. `"applications"`).
@@ -1192,7 +1204,7 @@ declare class TinyCloudNode {
1192
1204
  get encryption(): IEncryptionService;
1193
1205
  getEncryptionNetwork(nameOrNetworkId?: string): Promise<NetworkDescriptor | null>;
1194
1206
  createEncryptionNetwork(name?: string): Promise<NetworkDescriptor>;
1195
- ensureEncryptionNetwork(name?: string): Promise<NetworkDescriptor>;
1207
+ ensureEncryptionNetwork(nameOrNetworkId?: string): Promise<NetworkDescriptor>;
1196
1208
  /**
1197
1209
  * App-facing secrets API backed by the `secrets` space vault.
1198
1210
  */