Apple - How to refresh the shared list in the Finder's side panel?

Relaunch the Finder

option+right click [or Ctrl+Opt+left click] the Finder icon in the Dock, last item is Relaunch.

Or try this I found on StackOverflow Automator Command to Refresh ALL Finder/all Finder Windows - works for Finder windows, can't test for Shared items.

tell application "Finder"
    set theWindows to every window
    repeat with i from 1 to number of items in theWindows
        set this_item to item i of theWindows
        set theView to current view of this_item
        if theView is list view then
            set current view of this_item to icon view
        else
            set current view of this_item to list view

        end if
        set current view of this_item to theView
    end repeat


end tell

Or use Terminal app to performing it manually

killall Finder

Also turning WiFi off and back on should refresh the shared list.