many to many configuration and mail api example