Added new automated tests for API Service.

Change-Id: I1999b600c87c92a907d9ad03589db1c2912d7964