The Loyalty Group Token Enhancer Example shows how to configure a custom token enhancer.
The Adding new permissions example shows how to add a new permission to an existing user role.