Added additional code formatting and updates to API

Corrected and cleaned up things, formatted code API to match Orchestrator.