Rhymen / go-whatsapp

WhatsApp Web API
MIT License
2.07k stars 493 forks source link

feat: add GetGroupMetadata #585

Open gazandic opened 3 years ago

gazandic commented 3 years ago

Hi, i would like to add group metadata ability on Rhymen go-whatsapp.

This feature will be useful for retrieving group information from JID or searching group (jid) by name. (by utilize Search and validate the group name with this function)

I already try it, and has this result.

{"id":"{{phoneNumber}}-16200151212@g.us","owner":"{{phoneNumber}}@c.us","subject":"{{groupName}}","creation":1620015508,"participants":[{"id":"{{phoneNumber1}}@c.us","isAdmin":false,"isSuperAdmin":false},{"id":"{{phoneNumber2}}@c.us","isAdmin":false,"isSuperAdmin":false},{"id":"{{phoneNumber3}}@c.us","isAdmin":false,"isSuperAdmin":false},{"id":"{{phoneNumber4}}@c.us","isAdmin":true,"isSuperAdmin":false},{"id":"{{phoneNumber}}@c.us","isAdmin":true,"isSuperAdmin":true}],"subjectTime":1620015508,"subjectOwner":"{{phoneNumber}}@c.us"} <nil>

AlmogBaku commented 3 years ago

This feature already exists for a while. at least on the master