[example] Add an example of how to use the authorization hook