Extracted JSON client functions into seperate package

Closes #317 
`d.Dial` -- `pinned.Config.Dial` does however.