fully converted to wc api