change to new api