@usearete/sdk 0.21.0 → 0.22.0

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/index.d.ts CHANGED
@@ -849,39 +849,53 @@ type ProgramPdas<T extends Record<string, PdaFactory>> = T;
849
849
  declare function createProgramPdas<T extends Record<string, PdaFactory>>(pdas: T): ProgramPdas<T>;
850
850
 
851
851
  type ConnectionState = 'disconnected' | 'connecting' | 'connected' | 'reconnecting' | 'error';
852
+ /**
853
+ * `cursor` is the `{epoch}:{offset}` position of the event that produced the
854
+ * update on a replayable append view. Store it alongside the data and pass it
855
+ * back as `after` to resume exactly where you stopped. Absent on state and
856
+ * list views, which project membership rather than a tape.
857
+ */
852
858
  type Update<T> = {
853
859
  type: 'upsert';
854
860
  key: string;
855
861
  data: T;
862
+ cursor?: string;
856
863
  } | {
857
864
  type: 'patch';
858
865
  key: string;
859
866
  data: Partial<T>;
867
+ cursor?: string;
860
868
  } | {
861
869
  type: 'remove';
862
870
  key: string;
871
+ cursor?: string;
863
872
  } | {
864
873
  type: 'delete';
865
874
  key: string;
875
+ cursor?: string;
866
876
  };
867
877
  type RichUpdate<T> = {
868
878
  type: 'created';
869
879
  key: string;
870
880
  data: T;
881
+ cursor?: string;
871
882
  } | {
872
883
  type: 'updated';
873
884
  key: string;
874
885
  before: T;
875
886
  after: T;
876
887
  patch?: unknown;
888
+ cursor?: string;
877
889
  } | {
878
890
  type: 'removed';
879
891
  key: string;
880
892
  lastKnown?: T;
893
+ cursor?: string;
881
894
  } | {
882
895
  type: 'deleted';
883
896
  key: string;
884
897
  lastKnown?: T;
898
+ cursor?: string;
885
899
  };
886
900
  type ViewKeyValue = string | number | bigint;
887
901
  type ViewKeyFields<TKey> = unknown extends TKey ? readonly string[] : TKey extends object ? readonly Extract<keyof TKey, string>[] : readonly string[];
@@ -1079,6 +1093,8 @@ interface QuerySnapshot<T = unknown> {
1079
1093
  readonly data: readonly T[];
1080
1094
  readonly isLoading: boolean;
1081
1095
  readonly isRefreshing: boolean;
1096
+ /** Cursor of the last event delivered on this query; absent until one is. */
1097
+ readonly cursor?: string;
1082
1098
  readonly error?: AreteError;
1083
1099
  }
1084
1100
  interface QueryLease {
@@ -1088,6 +1104,8 @@ interface QueryLease {
1088
1104
  onChange(callback: () => void): UnsubscribeFn;
1089
1105
  onUpdate<T = unknown>(callback: (update: Update<T>) => void): UnsubscribeFn;
1090
1106
  onRichUpdate<T = unknown>(callback: (update: RichUpdate<T>) => void): UnsubscribeFn;
1107
+ /** Current failure, if any, without materializing a snapshot. */
1108
+ getError(): AreteError | undefined;
1091
1109
  refresh(): Promise<void>;
1092
1110
  release(): void;
1093
1111
  }
@@ -1109,7 +1127,10 @@ interface WatchOptions<TSchema = unknown> {
1109
1127
  schema?: Schema<TSchema>;
1110
1128
  /** Whether to include initial snapshot (defaults to true) */
1111
1129
  withSnapshot?: boolean;
1112
- /** Cursor for resuming from a specific point (_seq value) */
1130
+ /**
1131
+ * Resume after this `{epoch}:{offset}` cursor, exclusive. Use a `cursor`
1132
+ * taken from an update, never a `_seq` value.
1133
+ */
1113
1134
  after?: string;
1114
1135
  /** Maximum number of entities to include in snapshot */
1115
1136
  snapshotLimit?: number;
@@ -1208,6 +1229,24 @@ declare const DEFAULT_CONFIG: Required<Pick<AreteConfig, 'autoReconnect' | 'reco
1208
1229
  * These codes match the Rust AuthErrorCode enum for cross-platform consistency.
1209
1230
  */
1210
1231
  type AuthErrorCode = 'TOKEN_MISSING' | 'TOKEN_EXPIRED' | 'TOKEN_INVALID_SIGNATURE' | 'TOKEN_INVALID_FORMAT' | 'TOKEN_INVALID_ISSUER' | 'TOKEN_INVALID_AUDIENCE' | 'TOKEN_MISSING_CLAIM' | 'TOKEN_KEY_NOT_FOUND' | 'ORIGIN_MISMATCH' | 'ORIGIN_REQUIRED' | 'ORIGIN_NOT_ALLOWED' | 'AUTH_REQUIRED' | 'MISSING_AUTHORIZATION_HEADER' | 'INVALID_AUTHORIZATION_FORMAT' | 'INVALID_API_KEY' | 'EXPIRED_API_KEY' | 'USER_NOT_FOUND' | 'SECRET_KEY_REQUIRED' | 'DEPLOYMENT_ACCESS_DENIED' | 'RATE_LIMIT_EXCEEDED' | 'WEBSOCKET_SESSION_RATE_LIMIT_EXCEEDED' | 'CONNECTION_LIMIT_EXCEEDED' | 'SUBSCRIPTION_LIMIT_EXCEEDED' | 'SNAPSHOT_LIMIT_EXCEEDED' | 'EGRESS_LIMIT_EXCEEDED' | 'QUOTA_EXCEEDED' | 'INVALID_STATIC_TOKEN' | 'INTERNAL_ERROR';
1232
+ /**
1233
+ * Refusals of a replay cursor. Each has a distinct recovery, so they reach the
1234
+ * consumer as the wire code rather than being folded into a generic failure.
1235
+ */
1236
+ type ReplayErrorCode =
1237
+ /** Older than the retained window; resubscribe with no `after`. */
1238
+ 'cursor-expired'
1239
+ /** The tape was rebuilt; discard the stored cursor. */
1240
+ | 'cursor-epoch-changed'
1241
+ /** An offset this view never issued. */
1242
+ | 'cursor-unknown'
1243
+ /** Not an `{epoch}:{offset}` string. */
1244
+ | 'invalid-cursor'
1245
+ /** Replay would cross a known discontinuity; see `replayWindow.gapAfter`. */
1246
+ | 'replay-gap'
1247
+ /** Records were skipped in flight and delivery stopped; see `recoverFrom`. */
1248
+ | 'replay-lagged';
1249
+ declare function isReplayErrorCode(code: string): code is ReplayErrorCode;
1211
1250
  declare class AreteError extends Error {
1212
1251
  code: string | AuthErrorCode;
1213
1252
  details?: unknown | undefined;
@@ -1250,11 +1289,26 @@ interface IdentifiedFrame {
1250
1289
  protocolVersion: 2;
1251
1290
  subscriptionId: string;
1252
1291
  }
1292
+ /**
1293
+ * Offsets an append view can still replay. Offsets restart whenever a tape is
1294
+ * rebuilt, so they only mean anything inside `epoch`.
1295
+ */
1296
+ interface ReplayWindow {
1297
+ epoch: string;
1298
+ /** Oldest retained offset. */
1299
+ earliest: number;
1300
+ /** Offset the next event will take; a consumer at `next - 1` is caught up. */
1301
+ next: number;
1302
+ /** Last offset before a known discontinuity. */
1303
+ gapAfter?: number;
1304
+ }
1253
1305
  interface SubscribedFrame extends IdentifiedFrame {
1254
1306
  op: 'subscribed';
1255
1307
  query: SubscriptionQuery;
1256
1308
  mode: FrameMode;
1257
1309
  sort?: SortConfig;
1310
+ /** Present on append views backed by the journal. */
1311
+ replayWindow?: ReplayWindow;
1258
1312
  }
1259
1313
  interface UnsubscribedFrame extends IdentifiedFrame {
1260
1314
  op: 'unsubscribed';
@@ -1267,6 +1321,8 @@ interface EntityFrame<T = unknown> extends IdentifiedFrame {
1267
1321
  data: T | null;
1268
1322
  append?: string[];
1269
1323
  seq?: string;
1324
+ /** Dense, monotonic position on the view's tape. Absent on state/list views. */
1325
+ offset?: number;
1270
1326
  }
1271
1327
  interface SnapshotEntity<T = unknown> {
1272
1328
  key: string;
@@ -1294,6 +1350,10 @@ interface ErrorFrame {
1294
1350
  retry_after?: number;
1295
1351
  suggested_action?: string;
1296
1352
  docs_url?: string;
1353
+ /** Present on cursor refusals: what the view can still serve. */
1354
+ replayWindow?: ReplayWindow;
1355
+ /** Present on `replay-lagged`: cursor of the last record delivered before the gap. */
1356
+ recoverFrom?: string;
1297
1357
  }
1298
1358
  type Frame<T = unknown> = EntityFrame<T> | SnapshotFrame<T> | SubscribedFrame | UnsubscribedFrame | ErrorFrame;
1299
1359
  declare function isSnapshotFrame<T>(frame: Frame<T>): frame is SnapshotFrame<T>;
@@ -1304,6 +1364,20 @@ declare function isEntityFrame<T>(frame: Frame<T>): frame is EntityFrame<T>;
1304
1364
  declare function parseFrame(data: ArrayBuffer | string): Frame;
1305
1365
  declare function parseFrameFromBlob(blob: Blob): Promise<Frame>;
1306
1366
  declare function isValidFrame(frame: unknown): frame is Frame;
1367
+ /**
1368
+ * Builds the `{epoch}:{offset}` cursor a consumer stores and sends back as
1369
+ * `query.after`. An offset only means something inside the epoch the
1370
+ * acknowledgement named, so the epoch has to be carried across frames.
1371
+ */
1372
+ declare class CursorTracker {
1373
+ private readonly epochs;
1374
+ private readonly cursors;
1375
+ /** Records the frame and returns the cursor it carries, if any. */
1376
+ observe(frame: Frame): string | undefined;
1377
+ /** The last cursor delivered on a subscription, for resuming after a drop. */
1378
+ last(subscriptionId: string): string | undefined;
1379
+ forget(subscriptionId: string): void;
1380
+ }
1307
1381
 
1308
1382
  type FrameHandler = <T>(frame: Frame<T>) => void;
1309
1383
  /** Replace the extra hosted suffixes. Pass `[]` to keep only the default. */
@@ -1327,6 +1401,12 @@ declare class ConnectionManager {
1327
1401
  private currentState;
1328
1402
  private subscriptionQueue;
1329
1403
  private activeSubscriptions;
1404
+ /**
1405
+ * Replay positions per subscription. Shared with the frame processor rather
1406
+ * than duplicated: both observe the same frame stream, and this one is
1407
+ * pruned on unsubscribe, so the processor gets that pruning for free.
1408
+ */
1409
+ readonly cursors: CursorTracker;
1330
1410
  private socketGeneration;
1331
1411
  private pendingConnect;
1332
1412
  private frameHandlers;
@@ -1440,6 +1520,8 @@ declare class QueryStore {
1440
1520
  unregister(subscriptionId: string): void;
1441
1521
  getSubscription(subscriptionId: string): Subscription | undefined;
1442
1522
  getQueryKey(subscriptionId: string): string | undefined;
1523
+ /** The current failure without rebuilding the snapshot's data. */
1524
+ getError(subscriptionId: string): AreteError | undefined;
1443
1525
  getSnapshot<T>(subscriptionId: string): QuerySnapshot<T> | undefined;
1444
1526
  onChange(subscriptionId: string, callback: () => void): UnsubscribeFn;
1445
1527
  onUpdate<T>(subscriptionId: string, callback: (update: Update<T>) => void): UnsubscribeFn;
@@ -1447,7 +1529,7 @@ declare class QueryStore {
1447
1529
  acknowledge(subscriptionId: string, effectiveQuery: SubscriptionQuery, mode: FrameMode, sort?: SortConfig): void;
1448
1530
  stageSnapshot(frame: SnapshotFrame, keys: readonly string[]): void;
1449
1531
  applyLive(subscriptionId: string, key: string, update: Update<unknown>, richUpdate?: RichUpdate<unknown>, sequence?: string): void;
1450
- deleteGlobal(view: string, key: string, lastKnown?: unknown): void;
1532
+ deleteGlobal(view: string, key: string, lastKnown?: unknown, subscriptionId?: string, cursor?: string): void;
1451
1533
  evict(view: string, key: string): void;
1452
1534
  failFrame(frame: ErrorFrame): void;
1453
1535
  beginRefresh(subscriptionId: string, waitForSnapshot?: boolean): Promise<void>;
@@ -1518,6 +1600,15 @@ declare class FrameProcessor {
1518
1600
  private isProcessing;
1519
1601
  private latestProcessedSlot;
1520
1602
  private processedSlotWaiters;
1603
+ private cursors;
1604
+ /**
1605
+ * Observe the connection's cursor tracker instead of a private one.
1606
+ *
1607
+ * The connection prunes on unsubscribe; this processor never sees an
1608
+ * `unsubscribed` frame, so its own tracker would grow for the life of the
1609
+ * page as a React app mounts and unmounts components with different queries.
1610
+ */
1611
+ useCursorTracker(cursors: CursorTracker): void;
1521
1612
  constructor(storage: StorageAdapter, config?: FrameProcessorConfig);
1522
1613
  private getSchema;
1523
1614
  private normalizeEntity;
@@ -2547,6 +2638,15 @@ declare class MemoryAdapter implements StorageAdapter {
2547
2638
  notifyRichUpdate<T>(viewPath: string, key: string, update: RichUpdate<T>): void;
2548
2639
  }
2549
2640
 
2641
+ /**
2642
+ * A replayable record was dropped locally before the consumer read it.
2643
+ * `cursor` is the last one delivered, so the stream can be resumed from it
2644
+ * with `after` rather than silently skipping the lost records.
2645
+ */
2646
+ declare class StreamGapError extends AreteError {
2647
+ readonly cursor: string | undefined;
2648
+ constructor(cursor: string | undefined);
2649
+ }
2550
2650
  declare function createUpdateStream<T>(_storage: StorageAdapter, subscriptionRegistry: SubscriptionRegistry, query: SubscriptionQuery, keyFilter?: string, snapshotEnabled?: boolean): AsyncIterable<Update<T>>;
2551
2651
  declare function createEntityStream<T>(_storage: StorageAdapter, subscriptionRegistry: SubscriptionRegistry, query: SubscriptionQuery, options?: WatchOptions<any>, keyFilter?: string): AsyncIterable<T>;
2552
2652
  declare function createRichUpdateStream<T>(_storage: StorageAdapter, subscriptionRegistry: SubscriptionRegistry, query: SubscriptionQuery, keyFilter?: string, snapshotEnabled?: boolean): AsyncIterable<RichUpdate<T>>;
@@ -2560,5 +2660,5 @@ declare const Arete: typeof Arete$1 & {
2560
2660
  session: typeof createSession;
2561
2661
  };
2562
2662
 
2563
- export { ASSOCIATED_TOKEN_PROGRAM_ADDRESS, Arete, AreteError, ConnectionManager, DEFAULT_CONFIG, DEFAULT_MAX_ENTRIES_PER_VIEW, FrameProcessor, InstructionError, MemoryAdapter, OPERATION_KIND, OperationCallbackError, OperationExecutionError, PROGRAM_OPERATION_EXTENSIONS, ProcessedSlotTimeoutError, QueryStore, ReadRequestError, SPL_TOKEN_PROGRAM_ADDRESS, STACK_RUNTIME_EXTENSIONS, SYSTEM_PROGRAM_ADDRESS, SubscriptionRegistry, TOKEN_2022_PROGRAM_ADDRESS, TRANSACTION_RESOURCE_OPTION_KEYS, TransactionExecutionError, TransactionOptionsError, TransactionTransportError, account, appendFlowTransactions, appendTransactionInstructions, applyConnectedStackExtensions, arg, buildInstruction, bytes, canonicalQueryKey, chainAccountLoader, createChainClient, createEntityStream, createHostedSolanaGatewayTransports, createInstructionExecutor, createInstructionHandler, createPreparedFlow, createPreparedInstruction, createPreparedTransaction, createPreparedTransactionBody, createProgramPdas, createPublicKeySeed, createRichUpdateStream, createSeed, createSession, createSignerRegistry, createSubscriptionId, createTransactionTransport, createTypedListView, createTypedStateView, createTypedViews, createUpdateStream, decodeBase58, defineProgramExtensions, defineStackExtensions, deriveAssociatedTokenAccount, deriveHttpEndpoint, findProgramAddress as derivePda, describePreparedOperation, encodeBase58, executeInstruction, executePreparedOperation, extendProgram, extendPrograms, extendStack, findProgramAddress, findProgramAddressSync, flowOperation, formatPreparedOperation, formatProgramError, formatRawToUi, getMintDecimals, getOperationKind, getProgramRuntimeExtensions, getStackRuntimeExtensions, getTransactionFailureOutcome, hostedWebsocketSuffixes, inspectPreparedOperation, instructionOperation, isEntityFrame, isErrorFrame, isHostedAreteEndpoint, isSnapshotFrame, isSubscribedFrame, isUnsubscribedFrame, isValidFrame, literal, normalizeSubscription, normalizeSubscriptionQuery, normalizeSubscriptionRequest, normalizeTransactionError, parseFrame, parseFrameFromBlob, parseInstructionError, parseUiAmountToRaw, pda, prependFlowTransactionInstructions, prependTransactionInstructions, programAccountRead, programQuery, resolveAccounts, resolveAmount, resolveAmountToRaw, resolveAmountsToRaw, resolveTokenProgramAddress, resolveTransactionBuildOptions, safeToRawAmount, serializeInstructionData, serializeViewKey, setHostedWebsocketSuffixes, stackQuery, stringifyBigints, toJsonValue, toRawAmount, toWireResourceOptions, transactionOperation, unwrapOperationExecutionError, validateAccountResolution, validateProgramReadDescriptor, validateSubscriptionId, withProgramRead, withPrograms };
2564
- export type { AccountCategory, AccountLoader, AccountMeta, AccountResolutionOptions, AccountResolutionResult, AmountInput, AnyOperation, AreteConfig, AreteOptions, AreteOptionsWithStorage, ArgSchema, ArgType, AuthConfig, AuthTokenRequest, AuthTokenResult, AuthTokenTarget, BuildOptions, BuiltAccountMeta, BuiltInstruction, ChainClient, ChainClock, ChainFailedTransactionOutcome, CompositionSessionOptions, ConfirmationLevel, ConfirmedTransactionOutcome, ConnectOptions, ConnectedArete, ConnectedStackClient, ConnectionState, ConnectionStateCallback, ContextSlotOptions, CreatePreparedFlowInput, CreatePreparedInstructionInput, CreatePreparedTransactionInput, DefaultViewKey, EntityFrame, ErrorFrame, ErrorMetadata, ExecuteOptions, ExecutionResult, ExtendedProgramDefinition, ExtendedStackDefinition, FlowOperation, FlowOperationNamespace, FlowOperationReceipt, Frame, FrameMode, FrameOp, FrameProcessorConfig, FrameValidationDiagnostic, HostedSolanaGatewayBindings, HostedSolanaGatewayCapabilityBinding, HostedSolanaGatewayTransportOptions, HostedSolanaGatewayTransports, HttpAuthMetadata, InstructionExecutor, InstructionHandler, InstructionHandlerConfig, InstructionOperation, InstructionOperationNamespace, JsonObject, JsonPrimitive, JsonValue, LatestBlockhashResult, MergeProgramMaps, MintAccountInfo, NativeBalanceInfo, NonEmptyReadonlyArray, NotSubmittedTransactionOutcome, OperationCallbackPhase, OperationExecutionEvent, OperationExecutionHost, OperationExecutionOptions, OperationExecutionSuccessEvent, OperationInspection, OperationInspectionOptions, OperationKind, OperationKindBrand, OperationNamespace, OperationPlan, OperationReceiptFor, OperationTransactionReceipt, PdaConfig, PdaDeriveContext, PdaFactory, PdaProgram, PdaProgramSelector, PdaSeed, PreparedFlow, PreparedInstruction, PreparedOperation, PreparedOperationDescription, PreparedTransaction, PreparedTransactionBody, PreparedTransactionInstruction, PreparedTransactionOperation, ProgramAccountBatchItem, ProgramAccountBatchResult, ProgramAccountReadDefinition, ProgramError, ProgramExtensionInput, ProgramInterface, ProgramOperationContext, ProgramOperations, ProgramOperationsOf, ProgramPdas, ProgramQueryDefinition, ProgramReadBinding, ProgramReadBindingAuthTarget, ProgramReadDescriptor, ProgramReadDescriptors, ProgramReadOf, ProgramReadOverride, ProgramReadOverrides, ProgramReadRequest, ProgramReadTransport, ProgramReleaseReference, ProgramRuntimeExtensionCarrier, ProgramRuntimeExtensions, ProgramSdkDefinition, ProgramsInterface, QueriesInterface, QueryLease, QuerySnapshot, RawAccountInfo, RawInstructionsInterface, RawProgramsInterface, ReadArgumentCount, ReadArgumentCounts, ReadTransportMethod, ResolvedAccount, ResolvedAccounts, ResolvedTransactionBuildOptions, ResolvedTransactionResourceOptions, ResourceLamports, ResourceUnits, RichUpdate, RichUpdateCallback, Schema, SchemaResult, SeedDef, SendOptions, SendResult, Session, SessionDefinition, SessionMemberOptions, SessionOptions, SignerRegistry, SingleTransactionOperationReceipt, SnapshotEntity, SnapshotFrame, SocketIssue, SocketIssueCallback, SolanaGatewayAuthMetadata, SolanaGatewayAuthScope, SolanaGatewayBindingAuthTarget, SortConfig, SortOrder, StackConnectedExtensions, StackDefinition, StackEndpoints, StackExtensionClient, StackExtensionInput, StackQueryDefinition, StackRuntimeExtensionCarrier, StackRuntimeExtensions, StackWithAttachedPrograms, StorageAdapter, StorageAdapterConfig, StringifiedBigints, SubmittedUnknownTransactionOutcome, SubscribeCallback, SubscribedFrame, Subscription, SubscriptionIdentity, SubscriptionOptions, SubscriptionQuery, SubscriptionRequest, SubscriptionSnapshotOptions, TokenAccountInfo, TokenBalanceInfo, TokenBalanceInput, TransactionBuildCapability, TransactionBuildOptions, TransactionCommitment, TransactionFailureOutcome, TransactionFailurePhase, TransactionFailureStatus, TransactionFeeResult, TransactionInspectionOptions, TransactionInspectionResult, TransactionOperation, TransactionOperationNamespace, TransactionOptions, TransactionOptionsErrorCode, TransactionOutcome, TransactionRequestContext, TransactionResourceOptionKey, TransactionResourceOptions, TransactionSendOptions, TransactionSendResult, TransactionSignatureStatus, TransactionSimulationOptions, TransactionSimulationResult, TransactionTransport, TransactionTransportErrorBody, TransactionVersion, TypedAccountReader, TypedInstruction, TypedListView, TypedQueryExecutor, TypedStateView, TypedViewGroup, TypedViews, UnsubscribeFn, UnsubscribedFrame, Update, UpdateCallback, ViewDef, ViewGroup, ViewKeyFields, ViewKeyValue, ViewSortConfig, WaitForProcessedSlotOptions, WalletAdapter, WalletConnectOptions, WalletExecutionContext, WalletState, WatchOptions, WebSocketFactoryInit };
2663
+ export { ASSOCIATED_TOKEN_PROGRAM_ADDRESS, Arete, AreteError, ConnectionManager, DEFAULT_CONFIG, DEFAULT_MAX_ENTRIES_PER_VIEW, FrameProcessor, InstructionError, MemoryAdapter, OPERATION_KIND, OperationCallbackError, OperationExecutionError, PROGRAM_OPERATION_EXTENSIONS, ProcessedSlotTimeoutError, QueryStore, ReadRequestError, SPL_TOKEN_PROGRAM_ADDRESS, STACK_RUNTIME_EXTENSIONS, SYSTEM_PROGRAM_ADDRESS, StreamGapError, SubscriptionRegistry, TOKEN_2022_PROGRAM_ADDRESS, TRANSACTION_RESOURCE_OPTION_KEYS, TransactionExecutionError, TransactionOptionsError, TransactionTransportError, account, appendFlowTransactions, appendTransactionInstructions, applyConnectedStackExtensions, arg, buildInstruction, bytes, canonicalQueryKey, chainAccountLoader, createChainClient, createEntityStream, createHostedSolanaGatewayTransports, createInstructionExecutor, createInstructionHandler, createPreparedFlow, createPreparedInstruction, createPreparedTransaction, createPreparedTransactionBody, createProgramPdas, createPublicKeySeed, createRichUpdateStream, createSeed, createSession, createSignerRegistry, createSubscriptionId, createTransactionTransport, createTypedListView, createTypedStateView, createTypedViews, createUpdateStream, decodeBase58, defineProgramExtensions, defineStackExtensions, deriveAssociatedTokenAccount, deriveHttpEndpoint, findProgramAddress as derivePda, describePreparedOperation, encodeBase58, executeInstruction, executePreparedOperation, extendProgram, extendPrograms, extendStack, findProgramAddress, findProgramAddressSync, flowOperation, formatPreparedOperation, formatProgramError, formatRawToUi, getMintDecimals, getOperationKind, getProgramRuntimeExtensions, getStackRuntimeExtensions, getTransactionFailureOutcome, hostedWebsocketSuffixes, inspectPreparedOperation, instructionOperation, isEntityFrame, isErrorFrame, isHostedAreteEndpoint, isReplayErrorCode, isSnapshotFrame, isSubscribedFrame, isUnsubscribedFrame, isValidFrame, literal, normalizeSubscription, normalizeSubscriptionQuery, normalizeSubscriptionRequest, normalizeTransactionError, parseFrame, parseFrameFromBlob, parseInstructionError, parseUiAmountToRaw, pda, prependFlowTransactionInstructions, prependTransactionInstructions, programAccountRead, programQuery, resolveAccounts, resolveAmount, resolveAmountToRaw, resolveAmountsToRaw, resolveTokenProgramAddress, resolveTransactionBuildOptions, safeToRawAmount, serializeInstructionData, serializeViewKey, setHostedWebsocketSuffixes, stackQuery, stringifyBigints, toJsonValue, toRawAmount, toWireResourceOptions, transactionOperation, unwrapOperationExecutionError, validateAccountResolution, validateProgramReadDescriptor, validateSubscriptionId, withProgramRead, withPrograms };
2664
+ export type { AccountCategory, AccountLoader, AccountMeta, AccountResolutionOptions, AccountResolutionResult, AmountInput, AnyOperation, AreteConfig, AreteOptions, AreteOptionsWithStorage, ArgSchema, ArgType, AuthConfig, AuthTokenRequest, AuthTokenResult, AuthTokenTarget, BuildOptions, BuiltAccountMeta, BuiltInstruction, ChainClient, ChainClock, ChainFailedTransactionOutcome, CompositionSessionOptions, ConfirmationLevel, ConfirmedTransactionOutcome, ConnectOptions, ConnectedArete, ConnectedStackClient, ConnectionState, ConnectionStateCallback, ContextSlotOptions, CreatePreparedFlowInput, CreatePreparedInstructionInput, CreatePreparedTransactionInput, DefaultViewKey, EntityFrame, ErrorFrame, ErrorMetadata, ExecuteOptions, ExecutionResult, ExtendedProgramDefinition, ExtendedStackDefinition, FlowOperation, FlowOperationNamespace, FlowOperationReceipt, Frame, FrameMode, FrameOp, FrameProcessorConfig, FrameValidationDiagnostic, HostedSolanaGatewayBindings, HostedSolanaGatewayCapabilityBinding, HostedSolanaGatewayTransportOptions, HostedSolanaGatewayTransports, HttpAuthMetadata, InstructionExecutor, InstructionHandler, InstructionHandlerConfig, InstructionOperation, InstructionOperationNamespace, JsonObject, JsonPrimitive, JsonValue, LatestBlockhashResult, MergeProgramMaps, MintAccountInfo, NativeBalanceInfo, NonEmptyReadonlyArray, NotSubmittedTransactionOutcome, OperationCallbackPhase, OperationExecutionEvent, OperationExecutionHost, OperationExecutionOptions, OperationExecutionSuccessEvent, OperationInspection, OperationInspectionOptions, OperationKind, OperationKindBrand, OperationNamespace, OperationPlan, OperationReceiptFor, OperationTransactionReceipt, PdaConfig, PdaDeriveContext, PdaFactory, PdaProgram, PdaProgramSelector, PdaSeed, PreparedFlow, PreparedInstruction, PreparedOperation, PreparedOperationDescription, PreparedTransaction, PreparedTransactionBody, PreparedTransactionInstruction, PreparedTransactionOperation, ProgramAccountBatchItem, ProgramAccountBatchResult, ProgramAccountReadDefinition, ProgramError, ProgramExtensionInput, ProgramInterface, ProgramOperationContext, ProgramOperations, ProgramOperationsOf, ProgramPdas, ProgramQueryDefinition, ProgramReadBinding, ProgramReadBindingAuthTarget, ProgramReadDescriptor, ProgramReadDescriptors, ProgramReadOf, ProgramReadOverride, ProgramReadOverrides, ProgramReadRequest, ProgramReadTransport, ProgramReleaseReference, ProgramRuntimeExtensionCarrier, ProgramRuntimeExtensions, ProgramSdkDefinition, ProgramsInterface, QueriesInterface, QueryLease, QuerySnapshot, RawAccountInfo, RawInstructionsInterface, RawProgramsInterface, ReadArgumentCount, ReadArgumentCounts, ReadTransportMethod, ReplayErrorCode, ReplayWindow, ResolvedAccount, ResolvedAccounts, ResolvedTransactionBuildOptions, ResolvedTransactionResourceOptions, ResourceLamports, ResourceUnits, RichUpdate, RichUpdateCallback, Schema, SchemaResult, SeedDef, SendOptions, SendResult, Session, SessionDefinition, SessionMemberOptions, SessionOptions, SignerRegistry, SingleTransactionOperationReceipt, SnapshotEntity, SnapshotFrame, SocketIssue, SocketIssueCallback, SolanaGatewayAuthMetadata, SolanaGatewayAuthScope, SolanaGatewayBindingAuthTarget, SortConfig, SortOrder, StackConnectedExtensions, StackDefinition, StackEndpoints, StackExtensionClient, StackExtensionInput, StackQueryDefinition, StackRuntimeExtensionCarrier, StackRuntimeExtensions, StackWithAttachedPrograms, StorageAdapter, StorageAdapterConfig, StringifiedBigints, SubmittedUnknownTransactionOutcome, SubscribeCallback, SubscribedFrame, Subscription, SubscriptionIdentity, SubscriptionOptions, SubscriptionQuery, SubscriptionRequest, SubscriptionSnapshotOptions, TokenAccountInfo, TokenBalanceInfo, TokenBalanceInput, TransactionBuildCapability, TransactionBuildOptions, TransactionCommitment, TransactionFailureOutcome, TransactionFailurePhase, TransactionFailureStatus, TransactionFeeResult, TransactionInspectionOptions, TransactionInspectionResult, TransactionOperation, TransactionOperationNamespace, TransactionOptions, TransactionOptionsErrorCode, TransactionOutcome, TransactionRequestContext, TransactionResourceOptionKey, TransactionResourceOptions, TransactionSendOptions, TransactionSendResult, TransactionSignatureStatus, TransactionSimulationOptions, TransactionSimulationResult, TransactionTransport, TransactionTransportErrorBody, TransactionVersion, TypedAccountReader, TypedInstruction, TypedListView, TypedQueryExecutor, TypedStateView, TypedViewGroup, TypedViews, UnsubscribeFn, UnsubscribedFrame, Update, UpdateCallback, ViewDef, ViewGroup, ViewKeyFields, ViewKeyValue, ViewSortConfig, WaitForProcessedSlotOptions, WalletAdapter, WalletConnectOptions, WalletExecutionContext, WalletState, WatchOptions, WebSocketFactoryInit };