added view toAPI, updated Interaction module with better scoping