Right click and message tab to tab

Site link- (removed)
I use the json below to message each profile, but normally i open all the profiles in new tabs and run this json, this goes to each tab and message to each profile, if they already messaged go to next tab. then i close all profiles (tabs) manually go to next page in search results do the same again.
what changes has to do in json to auto mate manual process i do.

So - 12 tabs open > run my json > then close 12 tabs > next page

{
"Name": "x",
"CreationDate": "2020-8-12",
"Commands": [
{
"Command": "click",
"Target": "name=message",
"Value": ""
},
{
"Command": "click",
"Target": "name=message",
"Value": ""
},
{
"Command": "type",
"Target": "name=message",
"Value": "Hi, We have a room available"
},
{
"Command": "click",
"Target": "xpath=/html/body/div[1]/div/div[3]/div/div/div[3]/div/aside/div[1]/div[2]/form/div/button",
"Value": ""
},
{
"Command": "selectWindow",
"Target": "tab=1",
"Value": ""
}
]
}

Create a simple macro code to open 1 link, send a message, after open another link e send another message.

With loop in few line of codes you can do this work.

thanks, what is the jason should be for open > Message > back then i can loop it for 12 profiles

You must create a single with 1 cicle after with loop you can execute 12 times