use as api server