implemented new api