@wppconnect/wa-js - v4.7.1
    Preparing search index...

    Function setOrder

    • Set the order of custom lists using WhatsApp's native synchronized action. Pass every custom list id exactly once, in the desired order. Built-in and other lists retain their positions relative to the custom-list slots. Requires WhatsApp to enable list reordering for the account.

      Parameters

      • listIds: string[]

      Returns Promise<void>

      const ids = WPP.lists.list().map(list => list.id);
      await WPP.lists.setOrder(ids.reverse());
      console.log(WPP.lists.list());