add rest api polling support

Please document the default implementatio is empty