add server-side classes and tests