Updated for the new api packages