prepare for webAPI