tabs_move
Reorder browser tabs within a window or gather them into another window by ID. Use it to group tabs from one site together, and check the "Moved n of m" result since some moves are declined.
Instructions
Move tabs to a new position, optionally into another window
Reorders tabs within their window, or gathers them into a different window — to collect every tab for one site into a window of its own, create the window with create_window and pass its ID here.
Succeeding partially is normal, so check the result: it reads "Moved {n} of {m}", and a tab missing from the list did not move. Firefox declines some moves without raising an error, and the common one is that an unpinned tab cannot be placed in front of a pinned tab — with 3 pinned tabs, the lowest index an unpinned tab can reach is 3, and asking for 0, 1 or 2 moves nothing. Use tabs_list to see which tabs are pinned and what index each tab currently holds. A pinned tab can be moved to index 0 freely.
Moving between windows requires both to be normal windows, not popups, and either both private or both non-private.
profile_id is required: obtain it from profiles_list. All object IDs are local to that profile; never reuse them in another profile.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| index | No | Position to move to, counting from 0; -1 means the end (default: -1). An index inside a leading run of pinned tabs is refused for an unpinned tab — the move reports "No tabs moved" rather than failing. | |
| tab_ids | Yes | Tab ID, or several as a list (`[12, 15]`) or a JSON string (`"[12, 15]"`). Listed tabs keep their given order at the destination. | |
| window_id | No | Window to move the tabs into (optional, accepts int or string). Omit it to reorder within each tab's current window. | |
| profile_id | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |