I have to parse a JSON structure, which contains an unknown element name.
Normally I would access the data something like this.
my $layer1 = $responselayer->{'data'};
my $layer2 = $layer2->{'123'};
my $layer3 = $layer3->{'Details'};
print $layer3->{'name'};
Since the details number (123 / 945 / 345) is repeated in a random order (although unique in this case), I do not know how to address the data on 'Details' level.
"data":
{
"123":
{
"Details":
{
"name":"Jake",
"description":"aaa",
}
},
"945":
{
"Details":
{
"name":"Jim",
"description":"bbb",
}
},
"345":
{
"Details":
{
"name":"Bob",
"description":"ccc",
}
}
}
Thanks!