Adding metrics API with specs