add rest support