# URL's within JSON generated content

**URL:** <https://discourse.gohugo.io/t/urls-within-json-generated-content/18038>\
**Category:** support\
**Created:** [April 10, 2019, 9:59pm UTC](https://discourse.gohugo.io/t/urls-within-json-generated-content/18038 "2019-04-10T21:59:08Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Bonteq](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/bonteq/32/8359_2.png) [@Bonteq](https://discourse.gohugo.io/u/Bonteq)\
**Post date:** [April 10, 2019, 9:59pm UTC](https://discourse.gohugo.io/t/urls-within-json-generated-content/18038/1 "2019-04-10T21:59:08Z")

</div>

repo: [https://github.com/CodyBontecou/mtgranks\_hugo](https://github.com/CodyBontecou/mtgranks_hugo)  
data: [https://mtgjson.com/json/AllSets.json](https://mtgjson.com/json/AllSets.json)

I am using the data linked above to generate a ton of links. The problem is, these links aren’t properly referencing the template I want them to (or any template for that matter).

How do I gain control of the URL routing for data generated content?

---

<div class="post-metadata">

**Author:** ![maiki](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/maiki/32/16384_2.png) [@maiki](https://discourse.gohugo.io/u/maiki)\
**Post date:** [April 11, 2019, 2:36am UTC](https://discourse.gohugo.io/t/urls-within-json-generated-content/18038/2 "2019-04-11T02:36:15Z")

</div>

Hugo currently, as I type this, right now in spacetime, does not generate pages from data.

> [@Bonteq](#):
>
> How do I gain control of the URL routing for data generated content?

I can’t tell from looking at the repo what is happening. Is it supposed to create pages for each card? From the repo, there doesn’t look like many pages will be generated.

---

<div class="post-metadata">

**Author:** ![Bonteq](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/bonteq/32/8359_2.png) [@Bonteq](https://discourse.gohugo.io/u/Bonteq)\
**Post date:** [April 11, 2019, 2:41pm UTC](https://discourse.gohugo.io/t/urls-within-json-generated-content/18038/3 "2019-04-11T14:41:03Z")

</div>

Hey Maiki,

Sorry, I should have been a bit more explicit. I have a local data directory that contains the AllSets.json file linked above at [mtgjson.com](http://mtgjson.com). I didn’t want to include such a large file in my repo, so I decided to link to it instead. My hope is the actual data file is irrelevant, I’m more concerned about the routing and content creation that occurs when JSON data is provided.

> Hugo currently, as I type this, right now in spacetime, does not generate pages from data.

Hugo won’t iterate over my JSON file and create HTML pages with the values requested? I’m confused, I thought this was a huge aspect of Hugo.

---

<div class="post-metadata">

**Author:** ![RickCogley](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/rickcogley/32/10269_2.png) [@RickCogley](https://discourse.gohugo.io/u/RickCogley)\
**Post date:** [April 11, 2019, 2:45pm UTC](https://discourse.gohugo.io/t/urls-within-json-generated-content/18038/4 "2019-04-11T14:45:13Z")

</div>

You can use Hugo’s commands in your template to:

- generate lists of data, like a table, on a page,
- pull specific values, indexing on some value, from your data and put that on a page

… but it does not create pages from the data. This has been requested for a while now but is not there yet.

---

<div class="post-metadata">

**Author:** ![Bonteq](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/bonteq/32/8359_2.png) [@Bonteq](https://discourse.gohugo.io/u/Bonteq)\
**Post date:** [April 11, 2019, 2:51pm UTC](https://discourse.gohugo.io/t/urls-within-json-generated-content/18038/5 "2019-04-11T14:51:57Z")

</div>

Ah, interesting. Would a solution here be to convert the JSON to individual .md files?

---

<div class="post-metadata">

**Author:** ![maiki](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/maiki/32/16384_2.png) [@maiki](https://discourse.gohugo.io/u/maiki)\
**Post date:** [April 11, 2019, 6:41pm UTC](https://discourse.gohugo.io/t/urls-within-json-generated-content/18038/6 "2019-04-11T18:41:24Z")

</div>

Yeah, you could do that. I’m just gonna wait until Hugo _does_ build pages from data. I’ve waited a couple years, I’m patient. 🙂
