@muhkoo/connect 0.3.0-alpha.0 → 0.4.0-alpha.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/connect.d.ts CHANGED
@@ -936,6 +936,14 @@ declare class EncryptedSession {
936
936
  interface WSTransportOptions {
937
937
  /** WebSocket URL, e.g. `ws://localhost:8787/foo`. */
938
938
  url: string;
939
+ /**
940
+ * Optional async provider for a FRESH connection URL, called before each
941
+ * RECONNECT. Use it when the URL carries a single-use/expiring credential
942
+ * (e.g. a one-time WS upgrade ticket): on reconnect the baked-in ticket is
943
+ * already consumed/expired, so without this the reconnect is rejected and the
944
+ * transport burns through its attempts. The initial connect uses `url` as-is.
945
+ */
946
+ urlProvider?: () => string | Promise<string>;
939
947
  /**
940
948
  * Stable identifier for this connection (a channel / space / personal-space
941
949
  * id). Lifecycle + MESSAGE events are namespaced by it on the shared
@@ -991,6 +999,7 @@ declare class WSTransport extends EventCore {
991
999
  readonly off: (event: EventCoreEvents, handler: EventListener | CallableFunction) => void;
992
1000
  private scopedEvent;
993
1001
  private url;
1002
+ private urlProvider?;
994
1003
  private socket;
995
1004
  private _isConnected;
996
1005
  private _isConnecting;
@@ -1586,6 +1595,12 @@ interface WriteToShardsInput {
1586
1595
  * resumable uploads: the same id always maps to the same manifest slot.
1587
1596
  */
1588
1597
  fileId?: string;
1598
+ /**
1599
+ * Optional upload-progress callback, invoked after each chunk finishes
1600
+ * (`completed` of `total` chunks). Lets a UI show a progress bar. Called once
1601
+ * with `(0, total)` before the first chunk so a bar can render immediately.
1602
+ */
1603
+ onProgress?: (completed: number, total: number) => void;
1589
1604
  }
1590
1605
  declare class FileStorage {
1591
1606
  private readonly space;
@@ -2279,6 +2294,7 @@ declare class HttpClient {
2279
2294
  readonly fetch: typeof fetch;
2280
2295
  get<T = unknown>(path: string): Promise<T>;
2281
2296
  post<T = unknown>(path: string, body?: unknown): Promise<T>;
2297
+ patch<T = unknown>(path: string, body?: unknown): Promise<T>;
2282
2298
  del<T = unknown>(path: string, body?: unknown): Promise<T>;
2283
2299
  private request;
2284
2300
  }
@@ -2516,6 +2532,23 @@ interface RosterMember {
2516
2532
  /** Base64url-encoded JWK of the member's identity ECDSA public key. */
2517
2533
  identityEcdsaPub?: string;
2518
2534
  }
2535
+ /** A shareable invite link to a space. Redeeming it allowlists the holder so
2536
+ * the keeper admits them. */
2537
+ interface InviteLink {
2538
+ /** The capability token; embed in a URL to share. */
2539
+ token: string;
2540
+ /** Member id (username) that created the link. */
2541
+ createdBy?: string;
2542
+ createdAt?: number;
2543
+ /** Epoch ms when the link stops working; 0 = never. */
2544
+ expiresAt?: number;
2545
+ /** Max redemptions; 0 = unlimited. */
2546
+ maxUses?: number;
2547
+ /** Redemptions so far. */
2548
+ uses?: number;
2549
+ /** Access level granted to redeemers ("viewer" | "editor"). */
2550
+ role?: string;
2551
+ }
2519
2552
 
2520
2553
  /**
2521
2554
  * PacketCipher — the strategy `Network` uses to seal/open a packet's payload.
@@ -2929,7 +2962,9 @@ declare class Space {
2929
2962
  memberId: string;
2930
2963
  identityEcdhPub: string;
2931
2964
  }>): Promise<number>;
2932
- putFile(file: File | Blob | Uint8Array, metadata: SpaceFileMetadata): Promise<{
2965
+ putFile(file: File | Blob | Uint8Array, metadata: SpaceFileMetadata, opts?: {
2966
+ onProgress?: (completed: number, total: number) => void;
2967
+ }): Promise<{
2933
2968
  manifest: FileManifest;
2934
2969
  stat: FileStat;
2935
2970
  }>;
@@ -3135,6 +3170,40 @@ declare class SpaceNamespace {
3135
3170
  joinChannel(name: string, opts?: {
3136
3171
  timeoutMs?: number;
3137
3172
  }): Promise<Space>;
3173
+ /** Mint a shareable invite link for a space. `opts.expiresInSec` / `maxUses`
3174
+ * bound it (0/undefined = unlimited); `opts.role` ("viewer"|"editor") is the
3175
+ * access granted to redeemers (default viewer). Returns the link. */
3176
+ createInviteLink(spaceId: string, opts?: {
3177
+ expiresInSec?: number;
3178
+ maxUses?: number;
3179
+ role?: string;
3180
+ }): Promise<InviteLink>;
3181
+ /** Set a member's role on a space ("viewer" | "editor"). Owner-only. */
3182
+ setMemberRole(spaceId: string, username: string, role: string): Promise<void>;
3183
+ /** Roster with roles (owner/members only). */
3184
+ members(spaceId: string): Promise<Array<{
3185
+ memberId: string;
3186
+ role: string;
3187
+ }>>;
3188
+ /** List a space's active invite links (creator/members only). */
3189
+ listInviteLinks(spaceId: string): Promise<InviteLink[]>;
3190
+ /** Revoke an invite link by token. */
3191
+ revokeInviteLink(spaceId: string, token: string): Promise<void>;
3192
+ /**
3193
+ * Join a space using an invite link: redeem the token (the keeper admits
3194
+ * this member), then connect and resolve once the group key arrives.
3195
+ * Returns the open {@link Space}.
3196
+ */
3197
+ joinByInvite(spaceId: string, token: string, opts?: {
3198
+ timeoutMs?: number;
3199
+ }): Promise<Space>;
3200
+ /** The current member roster of a space (member id → identity public keys). */
3201
+ roster(spaceId: string): Promise<Array<{
3202
+ memberId: string;
3203
+ identityEcdhPub: string;
3204
+ identityEcdsaPub?: string;
3205
+ }>>;
3206
+ private keyringFor;
3138
3207
  private build;
3139
3208
  /** Ensure the member has an identity keypair; return its public ECDH + ECDSA keys. */
3140
3209
  private ensureIdentity;
@@ -3143,6 +3212,236 @@ declare class SpaceNamespace {
3143
3212
  private myId;
3144
3213
  }
3145
3214
 
3215
+ /**
3216
+ * `client.agents` — manage an app's **Programmable Agents** (server-side
3217
+ * "virtual users" backed by Workers AI).
3218
+ *
3219
+ * const { config } = await client.agents.create(appId, {
3220
+ * handle: '@assistant', displayName: 'Assistant',
3221
+ * systemPrompt: 'You are a helpful teammate in this Space.',
3222
+ * triggers: [{ type: 'mention' }],
3223
+ * });
3224
+ * await client.agents.enable(appId, config.agentId, spaceId); // per-Space opt-in
3225
+ *
3226
+ * These are MANAGEMENT calls — the agent itself runs on the accelerator. Only an
3227
+ * app's owner or an editor of its shared Space may create/update/enable an agent
3228
+ * (viewers can read). Authorization rides the user session token; non-owner
3229
+ * editors pass their management Space via `opts.space`.
3230
+ *
3231
+ * v1 is "prompts + persona": a system prompt, a model, named prompt `skills`,
3232
+ * and `triggers` that decide when the agent speaks. No tools, no code.
3233
+ */
3234
+
3235
+ type AgentTriggerType = "mention" | "keyword" | "regex" | "always";
3236
+ interface AgentTrigger {
3237
+ type: AgentTriggerType;
3238
+ /** Required for `keyword` (case-insensitive substring) and `regex`. */
3239
+ pattern?: string;
3240
+ /** Name of a {@link AgentSkill} to run on match. */
3241
+ skill?: string;
3242
+ }
3243
+ interface AgentSkill {
3244
+ name: string;
3245
+ prompt: string;
3246
+ }
3247
+ interface AgentConfig {
3248
+ agentId: string;
3249
+ /** @-mention target, e.g. "@assistant". */
3250
+ handle: string;
3251
+ displayName: string;
3252
+ model: string;
3253
+ systemPrompt: string;
3254
+ skills: AgentSkill[];
3255
+ triggers: AgentTrigger[];
3256
+ /** Space ids this agent is enabled on (per-Space opt-in). */
3257
+ enabledSpaces: string[];
3258
+ caps: {
3259
+ dailyTokenBudget: number;
3260
+ };
3261
+ createdAt: number;
3262
+ updatedAt: number;
3263
+ }
3264
+ /** The editor-settable fields when creating an agent. */
3265
+ interface AgentCreateInput {
3266
+ handle: string;
3267
+ displayName: string;
3268
+ systemPrompt: string;
3269
+ model?: string;
3270
+ skills?: AgentSkill[];
3271
+ triggers?: AgentTrigger[];
3272
+ caps?: {
3273
+ dailyTokenBudget: number;
3274
+ };
3275
+ }
3276
+ type AgentUpdateInput = Partial<AgentCreateInput>;
3277
+ /** Create/get response — the config plus the agent's published identity keys. */
3278
+ interface AgentProvisioned {
3279
+ config: AgentConfig;
3280
+ /** The agent's Space member id (`__agent__:<agentId>`). */
3281
+ memberId: string;
3282
+ /** base64url-JWK identity ECDH public key (null until provisioned). */
3283
+ ecdhPub: string | null;
3284
+ /** base64url-JWK identity ECDSA public key — verifies the agent's messages. */
3285
+ ecdsaPub: string | null;
3286
+ }
3287
+ interface AgentsNamespaceDeps {
3288
+ http: HttpClient;
3289
+ }
3290
+ /** Common option: a management Space for delegated (non-owner) access. */
3291
+ interface AgentScopeOpts {
3292
+ space?: string;
3293
+ }
3294
+ declare class AgentsNamespace {
3295
+ private readonly deps;
3296
+ constructor(deps: AgentsNamespaceDeps);
3297
+ /** List the app's agents. */
3298
+ list(appId: string, opts?: AgentScopeOpts): Promise<AgentConfig[]>;
3299
+ /** Read one agent (config + identity keys). */
3300
+ get(appId: string, agentId: string, opts?: AgentScopeOpts): Promise<AgentProvisioned>;
3301
+ /** Create an agent (owner/editor only). */
3302
+ create(appId: string, input: AgentCreateInput, opts?: AgentScopeOpts): Promise<AgentProvisioned>;
3303
+ /** Update an agent's editor-settable fields (owner/editor only). */
3304
+ update(appId: string, agentId: string, patch: AgentUpdateInput, opts?: AgentScopeOpts): Promise<{
3305
+ config: AgentConfig;
3306
+ }>;
3307
+ /** Delete an agent (owner/editor only). */
3308
+ delete(appId: string, agentId: string, opts?: AgentScopeOpts): Promise<{
3309
+ deleted: boolean;
3310
+ }>;
3311
+ /** Enable the agent on a Space (per-Space opt-in). */
3312
+ enable(appId: string, agentId: string, spaceId: string, opts?: AgentScopeOpts): Promise<{
3313
+ config: AgentConfig;
3314
+ }>;
3315
+ /** Disable the agent on a Space. */
3316
+ disable(appId: string, agentId: string, spaceId: string, opts?: AgentScopeOpts): Promise<{
3317
+ config: AgentConfig;
3318
+ }>;
3319
+ private path;
3320
+ }
3321
+
3322
+ /**
3323
+ * `client.functions` — manage an app's **serverless functions** (developer-
3324
+ * authored code that runs on the accelerator).
3325
+ *
3326
+ * const { config } = await client.functions.deploy(appId, {
3327
+ * name: 'hello', displayName: 'Hello',
3328
+ * code: `export default { fetch: () => new Response('hi') }`,
3329
+ * triggers: { http: { enabled: true } },
3330
+ * });
3331
+ * // HTTP-reachable at hello--<slug>.fns.muhkoo.dev
3332
+ * await client.functions.enable(appId, config.functionId, spaceId); // Space-bound
3333
+ *
3334
+ * These are MANAGEMENT calls — the function itself runs on the accelerator
3335
+ * (uploaded just-in-time, decrypted only at invocation). Only an app's owner or
3336
+ * an editor of its shared Space may deploy/update/enable (viewers read).
3337
+ * Authorization rides the user session token; non-owner editors pass their
3338
+ * management Space via `opts.space`.
3339
+ *
3340
+ * v1 is "compute-only": a function is an untrusted single-module ES worker
3341
+ * (`export default { fetch }`) with NO platform bindings — it reaches the
3342
+ * platform as an external client (the end-user session is passed through). Two
3343
+ * triggers: `http` (its own subdomain) and `space` (invoked on Space messages,
3344
+ * like a Programmable Agent).
3345
+ */
3346
+
3347
+ type FunctionTriggerType = "keyword" | "regex" | "always";
3348
+ interface FunctionTrigger {
3349
+ type: FunctionTriggerType;
3350
+ /** Required for `keyword` (case-insensitive substring) and `regex`. */
3351
+ pattern?: string;
3352
+ }
3353
+ interface FunctionTriggers {
3354
+ /** HTTP-invocable at `<name>--<slug>.fns.<zone>`. */
3355
+ http?: {
3356
+ enabled: boolean;
3357
+ methods?: string[];
3358
+ };
3359
+ /** Invoked on matching Space messages (per-Space opt-in via enable). */
3360
+ space?: {
3361
+ match: FunctionTrigger[];
3362
+ };
3363
+ }
3364
+ interface FunctionCaps {
3365
+ /** Per-invocation CPU ceiling (ms). */
3366
+ cpuMs: number;
3367
+ /** Per-invocation subrequest ceiling. */
3368
+ subRequests: number;
3369
+ /** Hard daily invocation cap (0 = unlimited). */
3370
+ dailyInvocationBudget: number;
3371
+ }
3372
+ interface FunctionConfig {
3373
+ functionId: string;
3374
+ /** DNS-safe slug — the function's subdomain label + WfP script name part. */
3375
+ name: string;
3376
+ displayName: string;
3377
+ triggers: FunctionTriggers;
3378
+ /** Space ids this function is enabled on (per-Space opt-in for `space`). */
3379
+ enabledSpaces: string[];
3380
+ caps: FunctionCaps;
3381
+ scriptName: string;
3382
+ /** sha-256 of the last-deployed source. */
3383
+ codeHash?: string;
3384
+ /** When the source was last (re)deployed. */
3385
+ deployedAt?: number;
3386
+ createdAt: number;
3387
+ updatedAt: number;
3388
+ }
3389
+ /** The editor-settable fields when deploying a function. */
3390
+ interface FunctionDeployInput {
3391
+ name: string;
3392
+ displayName: string;
3393
+ /** Raw single-module ES worker source (`export default { fetch }`). */
3394
+ code: string;
3395
+ triggers?: FunctionTriggers;
3396
+ caps?: Partial<FunctionCaps>;
3397
+ }
3398
+ /** Update input — any subset, including new `code` to redeploy. */
3399
+ type FunctionUpdateInput = Partial<FunctionDeployInput>;
3400
+ interface FunctionsNamespaceDeps {
3401
+ http: HttpClient;
3402
+ }
3403
+ /** Common option: a management Space for delegated (non-owner) access. */
3404
+ interface FunctionScopeOpts {
3405
+ space?: string;
3406
+ }
3407
+ declare class FunctionsNamespace {
3408
+ private readonly deps;
3409
+ constructor(deps: FunctionsNamespaceDeps);
3410
+ /** List the app's functions. */
3411
+ list(appId: string, opts?: FunctionScopeOpts): Promise<FunctionConfig[]>;
3412
+ /** Read one function's config. */
3413
+ get(appId: string, functionId: string, opts?: FunctionScopeOpts): Promise<{
3414
+ config: FunctionConfig;
3415
+ }>;
3416
+ /** Read a function's decrypted source (owner/editor; for the editor UI). */
3417
+ code(appId: string, functionId: string, opts?: FunctionScopeOpts): Promise<{
3418
+ functionId: string;
3419
+ code: string;
3420
+ codeHash: string | null;
3421
+ }>;
3422
+ /** Deploy (create) a function (owner/editor only). */
3423
+ deploy(appId: string, input: FunctionDeployInput, opts?: FunctionScopeOpts): Promise<{
3424
+ config: FunctionConfig;
3425
+ }>;
3426
+ /** Update a function's editor-settable fields and/or redeploy its `code`. */
3427
+ update(appId: string, functionId: string, patch: FunctionUpdateInput, opts?: FunctionScopeOpts): Promise<{
3428
+ config: FunctionConfig;
3429
+ }>;
3430
+ /** Delete a function (owner/editor only). */
3431
+ delete(appId: string, functionId: string, opts?: FunctionScopeOpts): Promise<{
3432
+ deleted: boolean;
3433
+ }>;
3434
+ /** Enable the function on a Space (per-Space opt-in for the `space` trigger). */
3435
+ enable(appId: string, functionId: string, spaceId: string, opts?: FunctionScopeOpts): Promise<{
3436
+ config: FunctionConfig;
3437
+ }>;
3438
+ /** Disable the function on a Space. */
3439
+ disable(appId: string, functionId: string, spaceId: string, opts?: FunctionScopeOpts): Promise<{
3440
+ config: FunctionConfig;
3441
+ }>;
3442
+ private path;
3443
+ }
3444
+
3146
3445
  /** The hosted Muhkoo Accelerator — the default {@link ClientOptions.baseUrl}. */
3147
3446
  declare const DEFAULT_BASE_URL = "https://api.muhkoo.dev";
3148
3447
  interface ClientOptions {
@@ -3188,6 +3487,10 @@ declare class Client {
3188
3487
  readonly message: MessageNamespace;
3189
3488
  /** Fan-out group spaces — `client.space.createSpace(...)`, etc. */
3190
3489
  readonly space: SpaceNamespace;
3490
+ /** Programmable Agents — `client.agents.create(appId, …)`, etc. */
3491
+ readonly agents: AgentsNamespace;
3492
+ /** Serverless functions — `client.functions.deploy(appId, …)`, etc. */
3493
+ readonly functions: FunctionsNamespace;
3191
3494
  private readonly session;
3192
3495
  private readonly http;
3193
3496
  /** Subscribers notified when a session expires and can't be recovered. */
@@ -3255,8 +3558,30 @@ declare class KeyringClient implements KeyringTransport {
3255
3558
  epoch: number;
3256
3559
  }>;
3257
3560
  invite(username: string): Promise<void>;
3561
+ createInviteLink(opts?: {
3562
+ expiresInSec?: number;
3563
+ maxUses?: number;
3564
+ role?: string;
3565
+ }): Promise<InviteLink>;
3566
+ listInviteLinks(): Promise<InviteLink[]>;
3567
+ /** Set a member's role ("viewer" | "editor"). Owner-only on the server. */
3568
+ setMemberRole(username: string, role: string): Promise<void>;
3569
+ /** Roster with roles (owner/members only). */
3570
+ members(): Promise<Array<{
3571
+ memberId: string;
3572
+ role: string;
3573
+ }>>;
3574
+ revokeInviteLink(token: string): Promise<void>;
3575
+ /** Redeem a link: the server allowlists this member and asks the keeper to
3576
+ * wrap the group key for their identity. Caller must be authenticated. */
3577
+ redeemInvite(req: {
3578
+ token: string;
3579
+ identityEcdhPub: string;
3580
+ identityEcdsaPub?: string;
3581
+ desiredEpoch?: number;
3582
+ }): Promise<void>;
3258
3583
  fetchMetadata(): Promise<SpaceMetadata | null>;
3259
3584
  }
3260
3585
 
3261
- export { AES_GCM_IV_BYTES, AES_GCM_KEY_BYTES, AES_GCM_TAG_BYTES, AuthClient, AuthNamespace, AuthPublicInput, Authenticator, BroadcastChannel, BroadcastChannelEvents, ChannelExistsError, ChannelNotFoundError, ChunkCipher, Client, DEFAULT_BASE_URL, DoubleRatchet, DoubleRatchetCipher, DoubleRatchetManager, EncryptedSession, EventCore, EventCoreEvents, Field, Field as FieldElement, FileStorage, HashKnowledge, HttpClient, HttpError, KEEPER_MEMBER_ID, KeyStore, KeyringClient, KvNamespace, LocalStorageSessionStore, MemorySessionStore, Message, Message as MessageDefault, MessageNamespace, PBKDF2_DEFAULT_ITERATIONS, PREIMAGE_POK_VERIFICATION_KEY, Packet, PersonalSpaceClient, Poseidon, PreimagePoK, ReedSolomonCodec, Space as Room, SerializeMessage, SessionState, ShardClient, SharedSpaceClient, Space, SpaceKeyring, SpaceNamespace, SpacePacketCipher, StorageNamespace, WSTransport, ZkAuth, buildCommitment, compilePrograms, decodeFromHex, decorators, decryptAesGcm, defaultCircuitUrls, defaultSessionStore, deriveAesKeyFromPassphrase, deriveBitsHkdf, deriveIdentity, encodeToHex, encryptAesGcm, exportPublicKeyBase64, exportPublicKeyHex, generateAuthProof, getSubtle, initBn128Wasm, initRsWasm, initializeCircuits, manifestToStat, poseidonHash, quickVerify, randomBytes, shardHash, signMessage, toField, unwrapWithPassphrase, verify, verifyGroth16, verifyHashKnowledge, verifyPreimagePoK, wrapWithPassphrase };
3262
- export type { ACL, ACLEntry, AuthClientOptions, AuthKeyPair, AuthSuccess, AuthToken, AuthType, AuthUser, Bn128WasmInstance, BroadcastChannelEvent, BroadcastChannelOptions, ChannelLike, ChunkKeyMaterial, ChunkManifest, CipherFrame, CipherMessage, CipherMessageHeader, CircuitBufferConfig, CircuitUrls, ClientOptions, DehydratedKeypair, DehydratedKeys, DoubleRatchetCipherDeps, ECDHCurve, EncodeResult, EphemeralEvent, EpochKeyProvider, FileManifest, FileNamespaceDeps, FileStat, FileStorageOptions, Groth16Proof, HttpClientOptions, IncomingFrame, KeyExchangeFrame, KeyPair, Keypair, KeyringClientDeps, KeyringTransport, KvNamespaceDeps, LoginOptions, MessageBody, MessageDeletedEvent, MessageEvent, MessageHeaders, MessageNamespaceDeps, MessageOptions, MessageSubscription, MuhkooMessageEvent, OAuthProvider, PacketCipher, PacketHeaders, PacketOptions, Participant, Permission, PermissionCheckRequest, PermissionCheckResult, PersonalSpaceClientOptions, PublicKeyJWK, RatchetState, ReceiveResult, RegisterParams, Role, SpaceDeps as RoomDeps, SpaceFileMetadata as RoomFileMetadata, SealedHeaders, Session, SessionOptions, SessionStore, SetOptions, ShardClientOptions, SharedSpaceClientOptions, SnarkProof, SpaceChannelLike, SpaceDeps, SpaceFileMetadata, SpaceKeyCache, SpaceKeyringDeps, SpaceMessageEvent, SpaceNamespaceDeps, StorageChangeEvent, StoredSession, Subscription, UserIdentity, VerificationKey, WSMessage, WSMessageType, WSTransportOptions, WrappedPayload, WriteFileInput, WriteFileOptions, WriteToShardsInput, ZkAuthDeps, ZkAuthenticateRequest, ZkChallengeResponse, ZkCompiled, ZkIdentity, ZkRegisterRequest, ZkRegisterResponse };
3586
+ export { AES_GCM_IV_BYTES, AES_GCM_KEY_BYTES, AES_GCM_TAG_BYTES, AgentsNamespace, AuthClient, AuthNamespace, AuthPublicInput, Authenticator, BroadcastChannel, BroadcastChannelEvents, ChannelExistsError, ChannelNotFoundError, ChunkCipher, Client, DEFAULT_BASE_URL, DoubleRatchet, DoubleRatchetCipher, DoubleRatchetManager, EncryptedSession, EventCore, EventCoreEvents, Field, Field as FieldElement, FileStorage, FunctionsNamespace, HashKnowledge, HttpClient, HttpError, KEEPER_MEMBER_ID, KeyStore, KeyringClient, KvNamespace, LocalStorageSessionStore, MemorySessionStore, Message, Message as MessageDefault, MessageNamespace, PBKDF2_DEFAULT_ITERATIONS, PREIMAGE_POK_VERIFICATION_KEY, Packet, PersonalSpaceClient, Poseidon, PreimagePoK, ReedSolomonCodec, Space as Room, SerializeMessage, SessionState, ShardClient, SharedSpaceClient, Space, SpaceKeyring, SpaceNamespace, SpacePacketCipher, StorageNamespace, WSTransport, ZkAuth, buildCommitment, compilePrograms, decodeFromHex, decorators, decryptAesGcm, defaultCircuitUrls, defaultSessionStore, deriveAesKeyFromPassphrase, deriveBitsHkdf, deriveIdentity, encodeToHex, encryptAesGcm, exportPublicKeyBase64, exportPublicKeyHex, generateAuthProof, getSubtle, initBn128Wasm, initRsWasm, initializeCircuits, manifestToStat, poseidonHash, quickVerify, randomBytes, shardHash, signMessage, toField, unwrapWithPassphrase, verify, verifyGroth16, verifyHashKnowledge, verifyPreimagePoK, wrapWithPassphrase };
3587
+ export type { ACL, ACLEntry, AgentConfig, AgentCreateInput, AgentProvisioned, AgentScopeOpts, AgentSkill, AgentTrigger, AgentTriggerType, AgentUpdateInput, AgentsNamespaceDeps, AuthClientOptions, AuthKeyPair, AuthSuccess, AuthToken, AuthType, AuthUser, Bn128WasmInstance, BroadcastChannelEvent, BroadcastChannelOptions, ChannelLike, ChunkKeyMaterial, ChunkManifest, CipherFrame, CipherMessage, CipherMessageHeader, CircuitBufferConfig, CircuitUrls, ClientOptions, DehydratedKeypair, DehydratedKeys, DoubleRatchetCipherDeps, ECDHCurve, EncodeResult, EphemeralEvent, EpochKeyProvider, FileManifest, FileNamespaceDeps, FileStat, FileStorageOptions, FunctionCaps, FunctionConfig, FunctionDeployInput, FunctionScopeOpts, FunctionTrigger, FunctionTriggerType, FunctionTriggers, FunctionUpdateInput, FunctionsNamespaceDeps, Groth16Proof, HttpClientOptions, IncomingFrame, KeyExchangeFrame, KeyPair, Keypair, KeyringClientDeps, KeyringTransport, KvNamespaceDeps, LoginOptions, MessageBody, MessageDeletedEvent, MessageEvent, MessageHeaders, MessageNamespaceDeps, MessageOptions, MessageSubscription, MuhkooMessageEvent, OAuthProvider, PacketCipher, PacketHeaders, PacketOptions, Participant, Permission, PermissionCheckRequest, PermissionCheckResult, PersonalSpaceClientOptions, PublicKeyJWK, RatchetState, ReceiveResult, RegisterParams, Role, SpaceDeps as RoomDeps, SpaceFileMetadata as RoomFileMetadata, SealedHeaders, Session, SessionOptions, SessionStore, SetOptions, ShardClientOptions, SharedSpaceClientOptions, SnarkProof, SpaceChannelLike, SpaceDeps, SpaceFileMetadata, SpaceKeyCache, SpaceKeyringDeps, SpaceMessageEvent, SpaceNamespaceDeps, StorageChangeEvent, StoredSession, Subscription, UserIdentity, VerificationKey, WSMessage, WSMessageType, WSTransportOptions, WrappedPayload, WriteFileInput, WriteFileOptions, WriteToShardsInput, ZkAuthDeps, ZkAuthenticateRequest, ZkChallengeResponse, ZkCompiled, ZkIdentity, ZkRegisterRequest, ZkRegisterResponse };