Retrieve button only pops up when somebody steals one of your gems. You can then try to return it from the Defense Logs. You only get one chance - if you fail, you will not be able to retrieve the gem yourself anymore. However, you pop up in the Retrieve Logs of your friends and guildmates and they are able to help you. Each friend also gets no more than one try.

Please note, that retrieve attacks are not real attacks. When you or your friends retrieve a stolen gem, you get a copy of it. The actual gem is still in the hands of the thief who stole it. This is done to increase your chances of returning a stolen gem. In reality, the thief could never even install your gem in the totem. Retrieval chance is a bit lower than your chance to steal a gem during the usual attack. To actually "hurt" the player who stole your gem, make a revenge attack on them and try stealing some gold or gems they may have in their totem.