added list_metrics query and a length-based pagination sample