Catmandu::Fix::get_json - get JSON data from an URL as fix function
# returns the hash get_json("http://example.com/json") # stores the in path.key get_json("http://example.com/json", path: path.key)
This Catmandu::Fix provides a method to fetch JSON data from an URL. The response is added as new item or to a field of the current item.
By now the only additional option of Catmandu::Importer::getJSON supported by this fix function are dry and cache. Future releases will also support setting the URL to a field value of the current item.
dry
cache
To install Catmandu::Importer::getJSON, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Catmandu::Importer::getJSON
CPAN shell
perl -MCPAN -e shell install Catmandu::Importer::getJSON
For more information on module installation, please visit the detailed CPAN module installation guide.