solve api errors once and for all hopefully