Node.js
// Requires the documented scopes. Keep keys on your server.
// For writes, persist the request key first; inspect unknown results.
const result = await client.request("/groups/120000000000@g.us/invite/reset", { method: "POST", body: {"expectedCode":"CURRENT_INVITATION_CODE"}, idempotencyKey: process.env.IDEMPOTENCY_KEY });
console.log(result);
{
"state": "completed",
"code": "<string>",
"url": "<string>",
"replayed": true,
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}WhatsApp actions
Reset group invitation link
groups:invites on the selected group and current admin status. expectedCode must match the current invitation. Resets the current link and returns its replacement; unknown results never retry.
Node.js
// Requires the documented scopes. Keep keys on your server.
// For writes, persist the request key first; inspect unknown results.
const result = await client.request("/groups/120000000000@g.us/invite/reset", { method: "POST", body: {"expectedCode":"CURRENT_INVITATION_CODE"}, idempotencyKey: process.env.IDEMPOTENCY_KEY });
console.log(result);
{
"state": "completed",
"code": "<string>",
"url": "<string>",
"replayed": true,
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}{
"error": "<string>"
}