api additions and test cases