update api to get plan schedule