docs: fix return value doc for several API functions
docs: update example for (un)register_notification
docs: update code examples