Fix routing issue for API