How to access the items array in a JSON file

90 Views Asked by At

I want to access the JSON data for my YouTube channel and here is what I got

    {
  "version": "https://jsonfeed.org/version/1",
  "title": "Academy",
  "home_page_url": "https://www.youtube.com/channel/UCm814Any5c0GvOrRCUE3z8g",
  "author": {
    "name": "Academy"
  },
  "items": [{
      "guid": "yt:video:im1kHs3dBlQ",
      "url": "https://www.youtube.com/watch?v=im1kHs3dBlQ",
      "title": "TCP/IP Explained The Easy Way | Academy",
      "date_published": "2022-02-28T22:19:59.000Z",
      "author": {
        "name": "Academy"
      }
    },
    {
      "guid": "yt:video:q2U7Rg9KNG8",
      "url": "https://www.youtube.com/watch?v=q2U7Rg9KNG8",
      "title": "How Do You Know If A MAC Address is Unicast, Multicast or Broadcast | Academy",
      "date_published": "2022-02-28T05:37:30.000Z",
      "author": {
        "name": "Academy"
      }
    }
  ]
}

But the problem is that I am unable to because the data I want to loop is inside the items:[....].

One way i know to do this is to remove it from the file but i want to access it remotely using Hugo, so it is difficult for me to access it.

0

There are 0 best solutions below