Update wrapper for new api