Api migration functions