Store Attribute in a variable and then iterate over the loop using for loop

{
“Name”: “newShiply”,
“CreationDate”: “2023-7-26”,
“Commands”: [
{
“Command”: “open”,
“Target”: “https://www.shiply.com/search”,
“Value”: “”,
“Description”: “”
},
{
“Command”: “storeAttribute”,
“Target”: “xpath=//td[@class="table-search-result-td search-cell"]//div[@class="search-cell-box-content"]/a@href”,
“Value”: “link1”,
“Description”: “”
},
{
“Command”: “echo”,
“Target”: “listing = ${link1}”,
“Value”: “”,
“Description”: “”
},
{
“Command”: “open”,
“Target”: “${link1}”,
“Value”: “”,
“Description”: “”
},
{
“Command”: “clickAndWait”,
“Target”: “linkText=Ask a question”,
“Value”: “”,
“Targets”: [
“linkText=Ask a question”,
“xpath=//[@id="pagePanel"]/div/div[2]/div/div[4]/div/a",
“xpath=//div[4]/div/a”,
“css=#pagePanel > div > div.row > div.col-md-8.listing-info-box > div:nth-child(4) > div.panel-heading.ask-question-header > a”
],
“Description”: “”
},
{
“Command”: “click”,
“Target”: “id=MessageMessage”,
“Value”: “”,
“Targets”: [
“id=MessageMessage”,
“name=data[Message][message]”,
"xpath=//
[@id="MessageMessage"]”,
“xpath=//textarea[@id=‘MessageMessage’]”,
“xpath=//textarea”,
“css=#MessageMessage”
],
“Description”: “”
},
{
“Command”: “click”,
“Target”: “id=MessageMessage”,
“Value”: “”,
“Targets”: [
“id=MessageMessage”,
“name=data[Message][message]”,
“xpath=//[@id="MessageMessage"]",
“xpath=//textarea[@id=‘MessageMessage’]”,
“xpath=//textarea”,
“css=#MessageMessage”
],
“Description”: “”
},
{
“Command”: “type”,
“Target”: “id=MessageMessage”,
“Value”: “Rate is for operable vehicles only please confirm dates and availability before accepting quote”,
“Targets”: [
“id=MessageMessage”,
“name=data[Message][message]”,
"xpath=//
[@id="MessageMessage"]”,
“xpath=//textarea[@id=‘MessageMessage’]”,
“xpath=//textarea”,
“css=#MessageMessage”
],
“Description”: “”
},
{
“Command”: “clickAndWait”,
“Target”: “id=submitBtnText-msg”,
“Value”: “”,
“Targets”: [
“id=submitBtnText-msg”,
“xpath=//*[@id="submitBtnText-msg"]”,
“xpath=//span[@id=‘submitBtnText-msg’]”,
“xpath=//div[3]/button/span”,
“css=#submitBtnText-msg”
],
“Description”: “”
},
{
“Command”: “pause”,
“Target”: “180000”,
“Value”: “”,
“Description”: “”
},
{
“Command”: “refresh”,
“Target”: “https://www.shiply.com/search”,
“Value”: “”,
“Description”: “”
}
]
}

so what basically i want is to get 5 or 10 herf links from attribute store them in a variable and the iterate over it, like we do in python selenium, so can anyone help?