Replace a broken link
replace_linkEdit a broken link's href in the store's content so it points somewhere that works. This is the fix for an EXTERNAL broken link (a redirect can't help there) and the better fix for an internal one when the right page exists. Preview with preview_link_replacement first and get the merchant's go-ahead. Navigation menus can't be rewritten by the app.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"brokenLinkId": "<brokenLinkId>",
"newHref": "<newHref>"
},
"name": "replace_link"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| newHref | Yes | The URL or path the link should point at | |
| brokenLinkId | Yes | From list_broken_links |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ok | Yes | ||
| message | Yes | ||
| failures | No | ||
| remaining | Yes | Pages the time budget did not reach. Greater than zero means the fix is INCOMPLETE — call this tool again with the same arguments to continue. | |
| resourcesChanged | Yes | ||
| occurrencesReplaced | Yes |