in reply to Parsing data from JSON response file.

Your question appears to be about JSON rather than about LWP. Can you write a short script that I can run on my own computer?

Update: I hacked out a lot, but not all extraneous stuff. Why do you need a loop here?

#!/usr/bin/perl use strict; use warnings; use Data::Dumper; # This a sample json data I am getting back in $data my $data = { 'zip' => 'AB3456', 'Tipo' => 'Boat', 'happen' => [ { 'descri' => 'Yellow Bike Tube' } ], 'explanation' => 'Order to go home.', 'notas' => [ { 'corpus' => 'Free Ship:PLAN C', 'To' => 'XQ0000Q', 'ExtraName' => 'Test User', 'sub' => '44 Bokes broken' } ], 'dados' => [ { 'valueA' => '2999', 'Creditd' => '-10', 'collect' => '120.00 usd', 'color' => 'Blue' } ], 'extraname' => 'Mary Lee Jones', 'account' => 'EX500RWX22' }; # This is fine, why is loop needed? # If there where multiple records like this, then there # would be an additional level of indirection and a loop # would be needed to get record specific values of "zip", etc. my $zip = $data->{zip}; my $descri = $data->{happen}[0]->{descri}; my $extra_name = $data->{notas}[0]->{ExtraName}; print "\n $zip - $descri - $extra_name\n"; __END__ Prints: AB3456 - Yellow Bike Tube - Test User