server code in the base. Not tested