WIP: more API methods using promises.