Port to the new API