repair to work with redcapAPI