How do I get ids from json array using online tool/website.
Steps as below
- Online Tool: json query tool
- Query: input.customer.map(({Id}) => Id)
- Query type: JavaScript
{ "customer": [ { "Id": "173C0C69-C467-AC1D-E1EC-09329D5A55F3", "Name": "Harshal", "Mobile": "16531015 0130", "City": "Pune" }, { "Id": "A0250FDE-A421-FEC9-E67A-346A2630D48B", "Name": "Indigo", "Mobile": "16251026 8085", "City": "Pietracatella" }, { "Id": "6DF038AD-690F-1F66-7BBA-0317095F2C16", "Name": "Craig", "Mobile": "16761004 2272", "City": "Sawahlunto" }, { "Id": "E1896D0D-B52A-811E-98FF-54ED33B62A62", "Name": "Kuame", "Mobile": "16880609 0653", "City": "Villeneuve-d'Ascq" }, { "Id": "D0E623AB-9D12-6879-E5C2-E9DEF3806F1F", "Name": "Kelsie", "Mobile": "16600216 8448", "City": "Onoz" }, { "Id": "7CE3E05B-B9F1-14F1-5CD7-F0E097B7C34B", "Name": "Glenna", "Mobile": "16470806 0563", "City": "The Hague" }, { "Id": "3304E741-A5D3-9DFD-9775-3241B6B268C9", "Name": "Nicole", "Mobile": "16381107 1830", "City": "Budaun" }, { "Id": "11AFE4F1-BBB9-E71F-9B04-98C8886C4685", "Name": "Eleanor", "Mobile": "16220806 0521", "City": "McCallum" }, { "Id": "D29A626D-BA9C-9A60-89FE-82CA62CA2113", "Name": "Sara", "Mobile": "16860606 9261", "City": "Bevilacqua" } ] }
Result (Ids json array) as below
[ "173C0C69-C467-AC1D-E1EC-09329D5A55F3", "A0250FDE-A421-FEC9-E67A-346A2630D48B", "6DF038AD-690F-1F66-7BBA-0317095F2C16", "E1896D0D-B52A-811E-98FF-54ED33B62A62", "D0E623AB-9D12-6879-E5C2-E9DEF3806F1F", "7CE3E05B-B9F1-14F1-5CD7-F0E097B7C34B", "3304E741-A5D3-9DFD-9775-3241B6B268C9", "11AFE4F1-BBB9-E71F-9B04-98C8886C4685", "D29A626D-BA9C-9A60-89FE-82CA62CA2113" ]
Screenshot as below