Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

client.getGroupApprovalRequests(message.chat.id) returns empty #3248

Open
1 task done
TVARecordings opened this issue Oct 18, 2024 · 0 comments
Open
1 task done

client.getGroupApprovalRequests(message.chat.id) returns empty #3248

TVARecordings opened this issue Oct 18, 2024 · 0 comments

Comments

@TVARecordings
Copy link

Are you using the latest version of the library?

  • I have checked and am using the latest version of the library.

What type of session are you experiencing this issue on?

Multi-device and I have set multiDevice to true in my config OR am using the --multi-device flag

What type of host account are you experiencing this issue on?

Business account

Mode

EASY API/CLI

Current Behavior

const PendingGroupApprovalRequests = await client.getGroupApprovalRequests(message.chat.id)
await sleep(5000)

returns an empty object, although there are 80 requests pending.

Expected Behavior

Expected a array of contact id's,

Steps To Reproduce

Run this code:

case 'handlegroupjoinrequest':
if (isAdmin) {
const PendingGroupApprovalRequests = await client.getGroupApprovalRequests(message.chat.id)
await sleep(5000)
console.log(PendingGroupApprovalRequests = ,PendingGroupApprovalRequests)
await client.sendText(from, PendingGroupApprovalRequests = \n\n${JSON.stringify(PendingGroupApprovalRequests,null,2)}\n\n${PendingGroupApprovalRequests})
}
break;

create() code OR full CLI command + CONFIG

No response

DEBUG INFO

{
  "WA_VERSION": "2.3000.1017469827",
  "WA_AUTOMATE_VERSION": "4.74.0",
  "BROWSER_VERSION": "Chrome/130.0.6723.58",
  "START_TS": 1729271896245,
  "RAM_INFO": "Total: 68.62 GB | Free: 50.10 GB",
  "PPTR_VERSION": "23.6.0",
  "LATEST_VERSION": true,
  "CLI": false,
  "PATCH_HASH": "CACHED-3aa89",
  "LAUNCH_TIME_MS": 7866,
  "ACC_TYPE": "BUSINESS",
  "chats": 69,
  "messages": 165,
  "contacts": 6544,
  "isBiz": true,
  "isMd": true,
  "INSTANCE_ID": "5f51ebc5-cbc5-477e-8e89-fce3b1615f42"
}

Environment

- OS: Windows 10
- Node: 20.16.0
- npm: 10.8.3

Screenshots/Logs

No response

Anything else?

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant