first function. get info server. return json on output