fixes #4699 - support Puppet environments API for directory envs

First use of Puppet's API...

* https://github.com/puppetlabs/puppet/blob/master/api/docs/http_api_index.md
* https://github.com/puppetlabs/puppet/blob/master/api/docs/http_environments.md
I think it would be useful to verify more details about data that's coming back: there's no validation that data received  from puppet affects data returned by the method...