Serverside code for to6