Wire up the subscribe button and refactor some request handling code.