Add documentation for generic REST controllers.

Fixes bug 1386837

Change-Id: I9cf30c7d55026d2364d7add3f7a9ca96b3348d31
Corrects ouptut -> output in docs/source/hooks.rst

Change-Id: I88823926b35a0762fb262779d6c3c5a25ef35eff
Merge "Add documentation for generic REST controllers."
tox: pass posargs to test command

Change-Id: Id66fc10d1d9e3340071b1af6d296c984b8b0ca81