Make API endpoints consistent with frontend