@xmtp/node-sdk 5.0.0 → 5.0.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/index.d.ts +7 -7
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ContentCodec, ContentTypeId } from '@xmtp/content-type-primitives';
|
|
2
2
|
import * as _xmtp_node_bindings from '@xmtp/node-bindings';
|
|
3
|
-
import { ContentTypeId as ContentTypeId$1, DeliveryStatus, GroupMessageKind, Reaction, DecodedMessage as DecodedMessage$1, LeaveRequest, ReadReceipt, Attachment, RemoteAttachment, TransactionReference, WalletSendCalls, Actions, Intent, MultiRemoteAttachment, GroupUpdated,
|
|
4
|
-
export { Action, ActionStyle, Actions, ApiStats, Attachment, Consent, ConsentEntityType, ConsentState, ContentType, ConversationDebugInfo, ConversationListItem, ConversationType, CreateDmOptions, CreateGroupOptions, Cursor, DeliveryStatus, EncryptedAttachment, GroupMember, GroupMembershipState, GroupMessageKind, GroupMetadata, GroupPermissions, GroupPermissionsOptions, GroupSyncSummary, GroupUpdated, HmacKey, Identifier, IdentifierKind, IdentityStats, Inbox, InboxState, Installation, Intent, KeyPackageStatus, LeaveRequest, Lifetime, ListConversationsOptions, ListConversationsOrderBy, ListMessagesOptions, LogLevel, LogOptions, Message, MessageDisappearingSettings, MessageSortBy, MetadataField, MetadataFieldChange, MultiRemoteAttachment, PermissionLevel, PermissionPolicy, PermissionPolicySet, PermissionUpdateType, Reaction, ReactionAction, ReactionSchema, ReadReceipt, RemoteAttachment, RemoteAttachmentInfo, SendMessageOpts, SignatureRequestHandle, SortDirection, TransactionMetadata, TransactionReference, UserPreferenceUpdate, WalletCall, WalletSendCalls, contentTypeActions, contentTypeAttachment, contentTypeGroupUpdated, contentTypeIntent, contentTypeLeaveRequest, contentTypeMarkdown, contentTypeMultiRemoteAttachment, contentTypeReaction, contentTypeReadReceipt, contentTypeRemoteAttachment, contentTypeReply, contentTypeText, contentTypeTransactionReference, contentTypeWalletSendCalls, decryptAttachment, encodeActions, encodeAttachment, encodeIntent, encodeMarkdown, encodeMultiRemoteAttachment, encodeReaction, encodeReadReceipt, encodeRemoteAttachment, encodeText, encodeTransactionReference, encodeWalletSendCalls, encryptAttachment } from '@xmtp/node-bindings';
|
|
3
|
+
import { ContentTypeId as ContentTypeId$1, DeliveryStatus, GroupMessageKind, Reaction, DecodedMessage as DecodedMessage$1, LeaveRequest, ReadReceipt, Attachment, RemoteAttachment, TransactionReference, WalletSendCalls, Actions, Intent, MultiRemoteAttachment, GroupUpdated, LogLevel, Identifier, StreamCloser, Conversation as Conversation$1, Message, EncodedContent, SendMessageOpts, Reply, ListMessagesOptions, ConsentState, PermissionUpdateType, PermissionPolicy, MetadataField, Conversations as Conversations$1, CreateGroupOptions, CreateDmOptions, ListConversationsOptions, ConversationType, Client as Client$1, Consent, ConsentEntityType, UserPreferenceUpdate, SignatureRequestHandle } from '@xmtp/node-bindings';
|
|
4
|
+
export { Action, ActionStyle, Actions, ApiStats, Attachment, Consent, ConsentEntityType, ConsentState, ContentType, ConversationDebugInfo, ConversationListItem, ConversationType, CreateDmOptions, CreateGroupOptions, Cursor, DeliveryStatus, EncryptedAttachment, GroupMember, GroupMembershipState, GroupMessageKind, GroupMetadata, GroupPermissions, GroupPermissionsOptions, GroupSyncSummary, GroupUpdated, HmacKey, Identifier, IdentifierKind, IdentityStats, Inbox, InboxState, Installation, Intent, KeyPackageStatus, LeaveRequest, Lifetime, ListConversationsOptions, ListConversationsOrderBy, ListMessagesOptions, LogLevel, LogOptions, Message, MessageDisappearingSettings, MessageSortBy, MetadataField, MetadataFieldChange, MultiRemoteAttachment, PermissionLevel, PermissionPolicy, PermissionPolicySet, PermissionUpdateType, Reaction, ReactionAction, ReactionSchema, ReadReceipt, RemoteAttachment, RemoteAttachmentInfo, Reply, SendMessageOpts, SignatureRequestHandle, SortDirection, TransactionMetadata, TransactionReference, UserPreferenceUpdate, WalletCall, WalletSendCalls, contentTypeActions, contentTypeAttachment, contentTypeGroupUpdated, contentTypeIntent, contentTypeLeaveRequest, contentTypeMarkdown, contentTypeMultiRemoteAttachment, contentTypeReaction, contentTypeReadReceipt, contentTypeRemoteAttachment, contentTypeReply, contentTypeText, contentTypeTransactionReference, contentTypeWalletSendCalls, decryptAttachment, encodeActions, encodeAttachment, encodeIntent, encodeMarkdown, encodeMultiRemoteAttachment, encodeReaction, encodeReadReceipt, encodeRemoteAttachment, encodeText, encodeTransactionReference, encodeWalletSendCalls, encryptAttachment } from '@xmtp/node-bindings';
|
|
5
5
|
|
|
6
6
|
/**
|
|
7
7
|
* Pre-configured URLs for the XMTP network based on the environment
|
|
@@ -185,13 +185,13 @@ type OtherOptions = {
|
|
|
185
185
|
nonce?: bigint;
|
|
186
186
|
};
|
|
187
187
|
type ClientOptions = NetworkOptions & StorageOptions & ContentOptions & OtherOptions;
|
|
188
|
-
type
|
|
189
|
-
referenceId:
|
|
188
|
+
type EnrichedReply<T = unknown, U = unknown> = {
|
|
189
|
+
referenceId: string;
|
|
190
190
|
content: T;
|
|
191
191
|
inReplyTo: DecodedMessage<U> | null;
|
|
192
192
|
};
|
|
193
193
|
type BuiltInContentTypes = string | LeaveRequest | Reaction | ReadReceipt | Attachment | RemoteAttachment | TransactionReference | WalletSendCalls | Actions | Intent | MultiRemoteAttachment | GroupUpdated;
|
|
194
|
-
type ExtractCodecContentTypes<C extends ContentCodec[] = []> = C extends readonly [] ? BuiltInContentTypes : [...C][number] extends ContentCodec<infer T> ? T | BuiltInContentTypes |
|
|
194
|
+
type ExtractCodecContentTypes<C extends ContentCodec[] = []> = C extends readonly [] ? BuiltInContentTypes : [...C][number] extends ContentCodec<infer T> ? T | BuiltInContentTypes | EnrichedReply<T | BuiltInContentTypes, T | BuiltInContentTypes> : BuiltInContentTypes;
|
|
195
195
|
|
|
196
196
|
declare class InboxReassignError extends Error {
|
|
197
197
|
constructor();
|
|
@@ -446,7 +446,7 @@ declare class Conversation<ContentTypes = unknown> {
|
|
|
446
446
|
* @param isOptimistic - Whether to send the message optimistically
|
|
447
447
|
* @returns Promise that resolves with the message ID after it has been sent
|
|
448
448
|
*/
|
|
449
|
-
sendReply(reply: Reply
|
|
449
|
+
sendReply(reply: Reply, isOptimistic?: boolean): Promise<string>;
|
|
450
450
|
/**
|
|
451
451
|
* Sends a transaction reference message
|
|
452
452
|
*
|
|
@@ -1439,4 +1439,4 @@ declare class Client<ContentTypes = ExtractCodecContentTypes> {
|
|
|
1439
1439
|
}
|
|
1440
1440
|
|
|
1441
1441
|
export { AccountAlreadyAssociatedError, ApiUrls, Client, ClientNotInitializedError, Conversation, Conversations, DEFAULT_RETRY_ATTEMPTS, DEFAULT_RETRY_DELAY, DecodedMessage, Dm, Group, HistorySyncUrls, InboxReassignError, MissingContentTypeError, SignerUnavailableError, StreamFailedError, StreamInvalidRetryAttemptsError, createStream, generateInboxId, getInboxIdForIdentifier, isHexString, validHex };
|
|
1442
|
-
export type { AsyncStreamProxy, BuiltInContentTypes, ClientOptions, ContentOptions, EOASigner, ExtractCodecContentTypes, HexString, NetworkOptions, OtherOptions,
|
|
1442
|
+
export type { AsyncStreamProxy, BuiltInContentTypes, ClientOptions, ContentOptions, EOASigner, EnrichedReply, ExtractCodecContentTypes, HexString, NetworkOptions, OtherOptions, SCWSigner, Signer, StorageOptions, StreamCallback, StreamFunction, StreamOptions, StreamValueMutator, XmtpEnv };
|