# HRPC Server Tutorial ## Simple Proto Server ```js const hrpc = require('hrpc') const server = hrpc.createServer() server.register('add', { async add({a, b}) { return {sum: a+b} } }) swarm.on('connection', conn => { server.pipe(conn).pipe(server) }) ``` **Client**: const client = hrpc.createClient(conn) const res = await client.add({a:1, b:2})