@xmtp/node-bindings 0.0.38 → 0.0.39
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/bindings_node.darwin-arm64.node +0 -0
- package/dist/bindings_node.darwin-x64.node +0 -0
- package/dist/bindings_node.linux-arm64-gnu.node +0 -0
- package/dist/bindings_node.linux-arm64-musl.node +0 -0
- package/dist/bindings_node.linux-x64-gnu.node +0 -0
- package/dist/bindings_node.linux-x64-musl.node +0 -0
- package/dist/bindings_node.win32-x64-msvc.node +0 -0
- package/dist/index.d.ts +66 -3
- package/dist/index.js +8 -1
- package/dist/version.json +3 -3
- package/package.json +4 -4
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/dist/index.d.ts
CHANGED
|
@@ -42,6 +42,7 @@ export declare class Conversation {
|
|
|
42
42
|
publishMessages(): Promise<void>
|
|
43
43
|
sync(): Promise<void>
|
|
44
44
|
findMessages(opts?: ListMessagesOptions | undefined | null): Promise<Array<Message>>
|
|
45
|
+
findMessagesWithReactions(opts?: ListMessagesOptions | undefined | null): Promise<Array<MessageWithReactions>>
|
|
45
46
|
processStreamedGroupMessage(envelopeBytes: Uint8Array): Promise<Message>
|
|
46
47
|
listMembers(): Promise<Array<GroupMember>>
|
|
47
48
|
adminList(): Array<string>
|
|
@@ -76,6 +77,7 @@ export declare class Conversation {
|
|
|
76
77
|
removeMessageDisappearingSettings(): Promise<void>
|
|
77
78
|
messageDisappearingSettings(): MessageDisappearingSettings | null
|
|
78
79
|
isMessageDisappearingEnabled(): boolean
|
|
80
|
+
getHmacKeys(): Array<HmacKey>
|
|
79
81
|
}
|
|
80
82
|
|
|
81
83
|
export declare class ConversationListItem {
|
|
@@ -161,6 +163,19 @@ export declare const enum ConsentState {
|
|
|
161
163
|
Denied = 2
|
|
162
164
|
}
|
|
163
165
|
|
|
166
|
+
export declare const enum ContentType {
|
|
167
|
+
Unknown = 0,
|
|
168
|
+
Text = 1,
|
|
169
|
+
GroupMembershipChange = 2,
|
|
170
|
+
GroupUpdated = 3,
|
|
171
|
+
Reaction = 4,
|
|
172
|
+
ReadReceipt = 5,
|
|
173
|
+
Reply = 6,
|
|
174
|
+
Attachment = 7,
|
|
175
|
+
RemoteAttachment = 8,
|
|
176
|
+
TransactionReference = 9
|
|
177
|
+
}
|
|
178
|
+
|
|
164
179
|
export interface ContentTypeId {
|
|
165
180
|
authorityId: string
|
|
166
181
|
typeId: string
|
|
@@ -196,6 +211,10 @@ export interface CreateGroupOptions {
|
|
|
196
211
|
messageDisappearingSettings?: MessageDisappearingSettings
|
|
197
212
|
}
|
|
198
213
|
|
|
214
|
+
export declare export declare function decodeMultiRemoteAttachment(bytes: Uint8Array): MultiRemoteAttachment
|
|
215
|
+
|
|
216
|
+
export declare export declare function decodeReaction(bytes: Uint8Array): Reaction
|
|
217
|
+
|
|
199
218
|
export declare const enum DeliveryStatus {
|
|
200
219
|
Unpublished = 0,
|
|
201
220
|
Published = 1,
|
|
@@ -210,6 +229,10 @@ export interface EncodedContent {
|
|
|
210
229
|
content: Uint8Array
|
|
211
230
|
}
|
|
212
231
|
|
|
232
|
+
export declare export declare function encodeMultiRemoteAttachment(multiRemoteAttachment: MultiRemoteAttachment): Uint8Array
|
|
233
|
+
|
|
234
|
+
export declare export declare function encodeReaction(reaction: Reaction): Uint8Array
|
|
235
|
+
|
|
213
236
|
export declare export declare function generateInboxId(accountAddress: string): string
|
|
214
237
|
|
|
215
238
|
export declare export declare function getInboxIdForAddress(host: string, isSecure: boolean, accountAddress: string): Promise<string | null>
|
|
@@ -232,7 +255,7 @@ export declare const enum GroupPermissionsOptions {
|
|
|
232
255
|
}
|
|
233
256
|
|
|
234
257
|
export interface HmacKey {
|
|
235
|
-
key:
|
|
258
|
+
key: Uint8Array
|
|
236
259
|
epoch: bigint
|
|
237
260
|
}
|
|
238
261
|
|
|
@@ -254,13 +277,11 @@ export declare export declare function isAddressAuthorized(host: string, inboxId
|
|
|
254
277
|
export declare export declare function isInstallationAuthorized(host: string, inboxId: string, installationId: Uint8Array): Promise<boolean>
|
|
255
278
|
|
|
256
279
|
export interface ListConversationsOptions {
|
|
257
|
-
allowedStates?: Array<GroupMembershipState>
|
|
258
280
|
consentStates?: Array<ConsentState>
|
|
259
281
|
createdAfterNs?: number
|
|
260
282
|
createdBeforeNs?: number
|
|
261
283
|
includeDuplicateDms: boolean
|
|
262
284
|
limit?: number
|
|
263
|
-
conversationType?: ConversationType
|
|
264
285
|
}
|
|
265
286
|
|
|
266
287
|
export interface ListMessagesOptions {
|
|
@@ -269,6 +290,7 @@ export interface ListMessagesOptions {
|
|
|
269
290
|
limit?: number
|
|
270
291
|
deliveryStatus?: DeliveryStatus
|
|
271
292
|
direction?: SortDirection
|
|
293
|
+
contentTypes?: Array<ContentType>
|
|
272
294
|
}
|
|
273
295
|
|
|
274
296
|
export declare const enum LogLevel {
|
|
@@ -306,12 +328,21 @@ export interface MessageDisappearingSettings {
|
|
|
306
328
|
inNs: number
|
|
307
329
|
}
|
|
308
330
|
|
|
331
|
+
export interface MessageWithReactions {
|
|
332
|
+
message: Message
|
|
333
|
+
reactions: Array<Message>
|
|
334
|
+
}
|
|
335
|
+
|
|
309
336
|
export declare const enum MetadataField {
|
|
310
337
|
GroupName = 0,
|
|
311
338
|
Description = 1,
|
|
312
339
|
ImageUrlSquare = 2
|
|
313
340
|
}
|
|
314
341
|
|
|
342
|
+
export interface MultiRemoteAttachment {
|
|
343
|
+
attachments: Array<RemoteAttachmentInfo>
|
|
344
|
+
}
|
|
345
|
+
|
|
315
346
|
export declare const enum PermissionLevel {
|
|
316
347
|
Member = 0,
|
|
317
348
|
Admin = 1,
|
|
@@ -346,6 +377,38 @@ export declare const enum PermissionUpdateType {
|
|
|
346
377
|
UpdateMetadata = 4
|
|
347
378
|
}
|
|
348
379
|
|
|
380
|
+
export interface Reaction {
|
|
381
|
+
reference: string
|
|
382
|
+
referenceInboxId: string
|
|
383
|
+
action: ReactionAction
|
|
384
|
+
content: string
|
|
385
|
+
schema: ReactionSchema
|
|
386
|
+
}
|
|
387
|
+
|
|
388
|
+
export declare const enum ReactionAction {
|
|
389
|
+
Unknown = 0,
|
|
390
|
+
Added = 1,
|
|
391
|
+
Removed = 2
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
export declare const enum ReactionSchema {
|
|
395
|
+
Unknown = 0,
|
|
396
|
+
Unicode = 1,
|
|
397
|
+
Shortcode = 2,
|
|
398
|
+
Custom = 3
|
|
399
|
+
}
|
|
400
|
+
|
|
401
|
+
export interface RemoteAttachmentInfo {
|
|
402
|
+
secret: Uint8Array
|
|
403
|
+
contentDigest: string
|
|
404
|
+
nonce: Uint8Array
|
|
405
|
+
scheme: string
|
|
406
|
+
url: string
|
|
407
|
+
salt: Uint8Array
|
|
408
|
+
contentLength?: number
|
|
409
|
+
filename?: string
|
|
410
|
+
}
|
|
411
|
+
|
|
349
412
|
export declare const enum SignatureRequestType {
|
|
350
413
|
AddWallet = 0,
|
|
351
414
|
CreateInbox = 1,
|
package/dist/index.js
CHANGED
|
@@ -365,7 +365,7 @@ if (!nativeBinding) {
|
|
|
365
365
|
throw new Error(`Failed to load native binding`)
|
|
366
366
|
}
|
|
367
367
|
|
|
368
|
-
const { Client, Conversation, ConversationListItem, Conversations, GroupMember, GroupMetadata, GroupPermissions, StreamCloser, ConsentEntityType, ConsentState, ConversationType, createClient, DeliveryStatus, generateInboxId, getInboxIdForAddress, GroupMembershipState, GroupMessageKind, GroupPermissionsOptions, isAddressAuthorized, isInstallationAuthorized, LogLevel, MetadataField, PermissionLevel, PermissionPolicy, PermissionUpdateType, SignatureRequestType, SortDirection, verifySignedWithPublicKey } = nativeBinding
|
|
368
|
+
const { Client, Conversation, ConversationListItem, Conversations, GroupMember, GroupMetadata, GroupPermissions, StreamCloser, ConsentEntityType, ConsentState, ContentType, ConversationType, createClient, decodeMultiRemoteAttachment, decodeReaction, DeliveryStatus, encodeMultiRemoteAttachment, encodeReaction, generateInboxId, getInboxIdForAddress, GroupMembershipState, GroupMessageKind, GroupPermissionsOptions, isAddressAuthorized, isInstallationAuthorized, LogLevel, MetadataField, PermissionLevel, PermissionPolicy, PermissionUpdateType, ReactionAction, ReactionSchema, SignatureRequestType, SortDirection, verifySignedWithPublicKey } = nativeBinding
|
|
369
369
|
export { Client }
|
|
370
370
|
export { Conversation }
|
|
371
371
|
export { ConversationListItem }
|
|
@@ -376,9 +376,14 @@ export { GroupPermissions }
|
|
|
376
376
|
export { StreamCloser }
|
|
377
377
|
export { ConsentEntityType }
|
|
378
378
|
export { ConsentState }
|
|
379
|
+
export { ContentType }
|
|
379
380
|
export { ConversationType }
|
|
380
381
|
export { createClient }
|
|
382
|
+
export { decodeMultiRemoteAttachment }
|
|
383
|
+
export { decodeReaction }
|
|
381
384
|
export { DeliveryStatus }
|
|
385
|
+
export { encodeMultiRemoteAttachment }
|
|
386
|
+
export { encodeReaction }
|
|
382
387
|
export { generateInboxId }
|
|
383
388
|
export { getInboxIdForAddress }
|
|
384
389
|
export { GroupMembershipState }
|
|
@@ -391,6 +396,8 @@ export { MetadataField }
|
|
|
391
396
|
export { PermissionLevel }
|
|
392
397
|
export { PermissionPolicy }
|
|
393
398
|
export { PermissionUpdateType }
|
|
399
|
+
export { ReactionAction }
|
|
400
|
+
export { ReactionSchema }
|
|
394
401
|
export { SignatureRequestType }
|
|
395
402
|
export { SortDirection }
|
|
396
403
|
export { verifySignedWithPublicKey }
|
package/dist/version.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xmtp/node-bindings",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.39",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://git@github.com/xmtp/libxmtp.git",
|
|
@@ -46,10 +46,10 @@
|
|
|
46
46
|
"prettier": "^3.5.0",
|
|
47
47
|
"prettier-plugin-packagejson": "^2.5.8",
|
|
48
48
|
"tsx": "^4.19.3",
|
|
49
|
-
"typescript": "^5.
|
|
50
|
-
"uuid": "^11.0
|
|
49
|
+
"typescript": "^5.8.2",
|
|
50
|
+
"uuid": "^11.1.0",
|
|
51
51
|
"viem": "^2.23.2",
|
|
52
|
-
"vite": "^6.
|
|
52
|
+
"vite": "^6.2.0",
|
|
53
53
|
"vite-tsconfig-paths": "^5.1.4",
|
|
54
54
|
"vitest": "^3.0.4",
|
|
55
55
|
"zx": "^8.3.2"
|