updated api design