@wppconnect/wa-js 1.1.13 → 1.1.17

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.
Files changed (32) hide show
  1. package/CHANGELOG.md +31 -0
  2. package/dist/chat/functions/index.d.ts +3 -0
  3. package/dist/chat/functions/openChatAt.d.ts +27 -0
  4. package/dist/chat/functions/openChatBottom.d.ts +27 -0
  5. package/dist/chat/functions/openChatFromUnread.d.ts +27 -0
  6. package/dist/group/functions/ensureGroup.d.ts +1 -1
  7. package/dist/group/functions/getGroupInfoFromInviteCode.d.ts +51 -0
  8. package/dist/group/functions/getInviteCode.d.ts +26 -0
  9. package/dist/group/functions/index.d.ts +8 -0
  10. package/dist/group/functions/join.d.ts +28 -0
  11. package/dist/group/functions/leave.d.ts +27 -0
  12. package/dist/group/functions/revokeInviteCode.d.ts +28 -0
  13. package/dist/group/functions/setDescription.d.ts +27 -0
  14. package/dist/group/functions/setProperty.d.ts +54 -0
  15. package/dist/group/functions/setSubject.d.ts +27 -0
  16. package/dist/whatsapp/collections/ParticipantCollection.d.ts +1 -1
  17. package/dist/whatsapp/enums/GROUP_SETTING_TYPE.d.ts +22 -0
  18. package/dist/whatsapp/enums/index.d.ts +1 -0
  19. package/dist/whatsapp/functions/createMsgProtobuf.d.ts +20 -0
  20. package/dist/whatsapp/functions/index.d.ts +7 -0
  21. package/dist/whatsapp/functions/sendCallSignalingMsg.d.ts +34 -0
  22. package/dist/whatsapp/functions/sendExitGroup.d.ts +18 -0
  23. package/dist/whatsapp/functions/sendJoinGroupViaInvite.d.ts +18 -0
  24. package/dist/whatsapp/functions/sendQueryGroupInvite.d.ts +44 -0
  25. package/dist/whatsapp/functions/sendQueryGroupInviteCode.d.ts +18 -0
  26. package/dist/whatsapp/functions/sendRevokeGroupInviteCode.d.ts +18 -0
  27. package/dist/whatsapp/functions/setGroup.d.ts +23 -0
  28. package/dist/whatsapp/misc/Cmd.d.ts +4 -3
  29. package/dist/whatsapp/models/ChatModel.d.ts +2 -1
  30. package/dist/whatsapp/models/GroupMetadataModel.d.ts +2 -2
  31. package/dist/wppconnect-wa.js +1 -1
  32. package/package.json +12 -11
package/CHANGELOG.md CHANGED
@@ -1,3 +1,34 @@
1
+ ## 1.1.17 (2022-02-12)
2
+
3
+
4
+
5
+ ## 1.1.16 (2022-02-06)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * exported WPP.group.getGroupInfoFromInviteCode function ([0616778](https://github.com/wppconnect-team/wa-js/commit/0616778ea749f69d76b7eb79bcd1135fdaeaf70f))
11
+
12
+
13
+
14
+ ## 1.1.15 (2022-02-06)
15
+
16
+
17
+ ### Bug Fixes
18
+
19
+ * Fixed permission check for set group subject/description ([0ff6d58](https://github.com/wppconnect-team/wa-js/commit/0ff6d5892252150524f0595d711ff42338bdb29c))
20
+
21
+
22
+
23
+ ## 1.1.14 (2022-01-28)
24
+
25
+
26
+ ### Bug Fixes
27
+
28
+ * Fixed WPP.contact.queryExists to avoid stuck in MD ([53ef3b4](https://github.com/wppconnect-team/wa-js/commit/53ef3b4ce2ad779509e08d5eec89ee53e193ba7a))
29
+
30
+
31
+
1
32
  ## 1.1.13 (2022-01-28)
2
33
 
3
34
 
@@ -29,6 +29,9 @@ export { markIsRead } from './markIsRead';
29
29
  export { markIsRecording } from './markIsRecording';
30
30
  export { markIsUnread } from './markIsUnread';
31
31
  export { mute } from './mute';
32
+ export { openChatAt } from './openChatAt';
33
+ export { openChatBottom } from './openChatBottom';
34
+ export { openChatFromUnread } from './openChatFromUnread';
32
35
  export { LinkPreviewOptions, prepareLinkPreview } from './prepareLinkPreview';
33
36
  export { MessageButtonsOptions, prepareMessageButtons, } from './prepareMessageButtons';
34
37
  export { prepareRawMessage } from './prepareRawMessage';
@@ -0,0 +1,27 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Wid } from '../../whatsapp';
17
+ /**
18
+ * Open the chat in the WhatsApp interface in a specific message
19
+ *
20
+ * @example
21
+ * ```javascript
22
+ * await WPP.chat.openChatAt('<number>@c.us', <message_id>);
23
+ * ```
24
+ *
25
+ * @category Chat
26
+ */
27
+ export declare function openChatAt(chatId: string | Wid, messageId: string): Promise<boolean>;
@@ -0,0 +1,27 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Wid } from '../../whatsapp';
17
+ /**
18
+ * Open the chat in the WhatsApp interface in bottom position
19
+ *
20
+ * @example
21
+ * ```javascript
22
+ * await WPP.chat.openChatBottom('<number>@c.us');
23
+ * ```
24
+ *
25
+ * @category Chat
26
+ */
27
+ export declare function openChatBottom(chatId: string | Wid): Promise<boolean>;
@@ -0,0 +1,27 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Wid } from '../../whatsapp';
17
+ /**
18
+ * Open the chat in the WhatsApp interface from first unread message
19
+ *
20
+ * @example
21
+ * ```javascript
22
+ * await WPP.chat.openChatFromUnread('<number>@c.us');
23
+ * ```
24
+ *
25
+ * @category Chat
26
+ */
27
+ export declare function openChatFromUnread(chatId: string | Wid): Promise<boolean>;
@@ -14,4 +14,4 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  import { Wid } from '../../whatsapp';
17
- export declare function ensureGroup(groupId: string | Wid): import("../../whatsapp").ChatModel;
17
+ export declare function ensureGroup(groupId: string | Wid, checkIsAdmin?: boolean): import("../../whatsapp").ChatModel;
@@ -0,0 +1,51 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ /**
17
+ * Get group info from an inviteCode
18
+ *
19
+ * @example
20
+ * ```javascript
21
+ * await WPP.group.getGroupInfoFromInviteCode('<inviteCode>');
22
+ * ```
23
+ *
24
+ * @category Group
25
+ */
26
+ export declare function getGroupInfoFromInviteCode(inviteCode: string): Promise<{
27
+ descOwner: string;
28
+ id: string;
29
+ owner: string;
30
+ participants: {
31
+ id: string;
32
+ isAdmin: boolean;
33
+ isSuperAdmin: boolean;
34
+ }[];
35
+ subjectOwner: string;
36
+ announce: boolean;
37
+ creation: number;
38
+ desc: string;
39
+ descId: string;
40
+ descTime: number;
41
+ noFrequentlyForwarded: boolean;
42
+ parent: boolean;
43
+ pvId?: string | undefined;
44
+ restrict: boolean;
45
+ size: number;
46
+ status: number;
47
+ subject: string;
48
+ subjectTime: number;
49
+ support: boolean;
50
+ suspended: boolean;
51
+ }>;
@@ -0,0 +1,26 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Wid } from '../../whatsapp';
17
+ /**
18
+ * Get the currend invite code of the group
19
+ *
20
+ * @example
21
+ * ```javascript
22
+ * const code = WPP.group.getInviteCode('<group-id>@g.us');
23
+ * const link = 'https://chat.whatsapp.com/' + code;
24
+ * ```
25
+ */
26
+ export declare function getInviteCode(groupId: string | Wid): Promise<string>;
@@ -22,10 +22,18 @@ export { create } from './create';
22
22
  export { demoteParticipants } from './demoteParticipants';
23
23
  export { ensureGroup } from './ensureGroup';
24
24
  export { ensureGroupAndParticipants } from './ensureGroupAndParticipants';
25
+ export { getGroupInfoFromInviteCode } from './getGroupInfoFromInviteCode';
26
+ export { getInviteCode } from './getInviteCode';
25
27
  export { getParticipants } from './getParticipants';
26
28
  export { iAmAdmin } from './iAmAdmin';
27
29
  export { iAmMember } from './iAmMember';
28
30
  export { iAmRestrictedMember } from './iAmRestrictedMember';
29
31
  export { iAmSuperAdmin } from './iAmSuperAdmin';
32
+ export { join } from './join';
33
+ export { leave } from './leave';
30
34
  export { promoteParticipants } from './promoteParticipants';
31
35
  export { removeParticipants } from './removeParticipants';
36
+ export { revokeInviteCode } from './revokeInviteCode';
37
+ export { setDescription } from './setDescription';
38
+ export { GroupProperty, setProperty } from './setProperty';
39
+ export { setSubject } from './setSubject';
@@ -0,0 +1,28 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ /**
17
+ * Join in a group from an invite code.
18
+ *
19
+ * @example
20
+ * ```javascript
21
+ * await WPP.group.join('abcde....');
22
+ * ```
23
+ *
24
+ * @category Group
25
+ */
26
+ export declare function join(inviteCode: string): Promise<{
27
+ id: string;
28
+ }>;
@@ -0,0 +1,27 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Wid } from '../../whatsapp';
17
+ /**
18
+ * Leave from a group.
19
+ *
20
+ * @example
21
+ * ```javascript
22
+ * await WPP.group.leave('<number>@g.us');
23
+ * ```
24
+ *
25
+ * @category Group
26
+ */
27
+ export declare function leave(groupId: string | Wid): Promise<void>;
@@ -0,0 +1,28 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Wid } from '../../whatsapp';
17
+ /**
18
+ * Revoke the current invite code and generate new one.
19
+ *
20
+ * @example
21
+ * ```javascript
22
+ * const code = WPP.group.revokeInviteCode('<group-id>@g.us');
23
+ * const link = 'https://chat.whatsapp.com/' + code;
24
+ * ```
25
+ *
26
+ * @category Group
27
+ */
28
+ export declare function revokeInviteCode(groupId: string | Wid): Promise<string>;
@@ -0,0 +1,27 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Wid } from '../../whatsapp';
17
+ /**
18
+ * Define the group description
19
+ *
20
+ * @example
21
+ * ```javascript
22
+ * await WPP.group.setDescription('<group-id>@g.us', 'new group description');
23
+ * ```
24
+ *
25
+ * @category Group
26
+ */
27
+ export declare function setDescription(groupId: string | Wid, description: string): Promise<boolean>;
@@ -0,0 +1,54 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Wid } from '../../whatsapp';
17
+ export declare enum GroupProperty {
18
+ ANNOUNCEMENT = "announcement",
19
+ EPHEMERAL = "ephemeral",
20
+ RESTRICT = "restrict"
21
+ }
22
+ /**
23
+ * Set the group property
24
+ *
25
+ * @example
26
+ * ```javascript
27
+ * // Only admins can send message
28
+ * await WPP.group.setProperty('<group-id>@g.us', 'announcement', true);
29
+ *
30
+ * // All can send message
31
+ * await WPP.group.setProperty('<group-id>@g.us', 'announcement', false);
32
+ *
33
+ * // Disatble temporary messages
34
+ * await WPP.group.setProperty('<group-id>@g.us', 'ephemeral', 0);
35
+ *
36
+ * // Enable temporary messages for 24 hours
37
+ * await WPP.group.setProperty('<group-id>@g.us', 'ephemeral', 86400);
38
+ *
39
+ * // Enable temporary messages for 7 days
40
+ * await WPP.group.setProperty('<group-id>@g.us', 'ephemeral', 604800);
41
+ *
42
+ * // Enable temporary messages for 90 days
43
+ * await WPP.group.setProperty('<group-id>@g.us', 'ephemeral', 7776000);
44
+ *
45
+ * // Only admins can edit group properties
46
+ * await WPP.group.setProperty('<group-id>@g.us', 'restrict', true);
47
+ *
48
+ * // All can edit group properties
49
+ * await WPP.group.setProperty('<group-id>@g.us', 'restrict', false);
50
+ * ```
51
+ *
52
+ * @category Group
53
+ */
54
+ export declare function setProperty(groupId: string | Wid, property: GroupProperty, value: 0 | 1 | 86400 | 604800 | 7776000 | boolean): Promise<boolean>;
@@ -0,0 +1,27 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Wid } from '../../whatsapp';
17
+ /**
18
+ * Define the group subject
19
+ *
20
+ * @example
21
+ * ```javascript
22
+ * await WPP.group.setSubject('<group-id>@g.us', 'new group subject');
23
+ * ```
24
+ *
25
+ * @category Group
26
+ */
27
+ export declare function setSubject(groupId: string | Wid, subject: string): Promise<boolean>;
@@ -15,7 +15,7 @@
15
15
  */
16
16
  import { ParticipantModel } from '../models';
17
17
  import { Collection } from './Collection';
18
- /** @whatsapp 59638 */
18
+ /** @whatsapp 69125 */
19
19
  export declare class ParticipantCollection extends Collection<ParticipantModel> {
20
20
  static model: ParticipantModel;
21
21
  static comparator(): any;
@@ -0,0 +1,22 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ /** @whatsapp 11547 */
17
+ export declare enum GROUP_SETTING_TYPE {
18
+ ANNOUNCEMENT = "announcement",
19
+ RESTRICT = "restrict",
20
+ NO_FREQUENTLY_FORWARDED = "no_frequently_forwarded",
21
+ EPHEMERAL = "ephemeral"
22
+ }
@@ -13,6 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
+ export * from './GROUP_SETTING_TYPE';
16
17
  export * from './LogoutReason';
17
18
  export * from './OUTWARD_TYPES';
18
19
  export * from './SendMsgResult';
@@ -0,0 +1,20 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { MsgModel } from '..';
17
+ /** @whatsapp 56346 */
18
+ export declare function createMsgProtobuf(e: MsgModel, t?: {
19
+ [key: string]: any;
20
+ }): Promise<any>;
@@ -15,6 +15,7 @@
15
15
  */
16
16
  export * from './addAndSendMsgToChat';
17
17
  export * from './blockContact';
18
+ export * from './createMsgProtobuf';
18
19
  export * from './fetchLinkPreview';
19
20
  export * from './findChat';
20
21
  export * from './findFirstWebLink';
@@ -27,10 +28,16 @@ export * from './msgFindQuery';
27
28
  export * from './products';
28
29
  export * from './profilePic';
29
30
  export * from './randomId';
31
+ export * from './sendCallSignalingMsg';
30
32
  export * from './sendClear';
31
33
  export * from './sendCreateGroup';
32
34
  export * from './sendDelete';
35
+ export * from './sendExitGroup';
36
+ export * from './sendJoinGroupViaInvite';
33
37
  export * from './sendQueryExists';
38
+ export * from './sendQueryGroupInvite';
39
+ export * from './sendRevokeGroupInviteCode';
34
40
  export * from './sendTextMsgToChat';
41
+ export * from './setGroup';
35
42
  export * from './status';
36
43
  export * from './uploadProductImage';
@@ -0,0 +1,34 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Wid } from '..';
17
+ import { ChatModel } from '../models';
18
+ /** @whatsapp 67935 */
19
+ export declare function sendCallSignalingMsg(data: {
20
+ common: {
21
+ type?: string;
22
+ call_id?: string;
23
+ peer_jid: Wid;
24
+ };
25
+ payload: [
26
+ string,
27
+ {
28
+ 'call-id': string;
29
+ 'call-creator': string;
30
+ count?: any;
31
+ },
32
+ null
33
+ ];
34
+ }, tagId?: string): Promise<ChatModel>;
@@ -0,0 +1,18 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { ChatModel } from '..';
17
+ /** @whatsapp 94881 */
18
+ export declare function sendExitGroup(group: ChatModel): Promise<void>;
@@ -0,0 +1,18 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Wid } from '..';
17
+ /** @whatsapp 65705 */
18
+ export declare function sendJoinGroupViaInvite(code: string): Promise<Wid>;
@@ -0,0 +1,44 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Wid } from '..';
17
+ export interface QueryGroupInviteResult {
18
+ announce: boolean;
19
+ creation: number;
20
+ desc: string;
21
+ descId: string;
22
+ descOwner: Wid;
23
+ descTime: number;
24
+ id: Wid;
25
+ noFrequentlyForwarded: boolean;
26
+ owner: Wid;
27
+ parent: boolean;
28
+ participants: {
29
+ id: Wid;
30
+ isAdmin: boolean;
31
+ isSuperAdmin: boolean;
32
+ }[];
33
+ pvId?: string;
34
+ restrict: boolean;
35
+ size: number;
36
+ status: number;
37
+ subject: string;
38
+ subjectOwner: Wid;
39
+ subjectTime: number;
40
+ support: boolean;
41
+ suspended: boolean;
42
+ }
43
+ /** @whatsapp 85709 */
44
+ export declare function sendQueryGroupInvite(inviteCode: string): Promise<QueryGroupInviteResult>;
@@ -0,0 +1,18 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Wid } from '..';
17
+ /** @whatsapp 65705 */
18
+ export declare function sendQueryGroupInviteCode(groupId: Wid): Promise<string>;