How to justify whether user is right-click on a link?

Like the topic said, is there any api to justify whether user is right-click on a link? And how can we get the link their are right-click on?