enable passing custom headers to client, GH-215

Code and doc updated to enable this feature, see GH-215