update to use the current api syntax