fix: schema handling in API