Server-side code.