moved legacy API to legacy directory