# Can't retrieve documents from alternative locale

**URL:** <https://community.prismic.io/t/cant-retrieve-documents-from-alternative-locale/1714>\
**Category:** Developing with Prismic\
**Tags:** nuxtjs\
**Created:** [September 1, 2020, 3:20pm UTC](https://community.prismic.io/t/cant-retrieve-documents-from-alternative-locale/1714 "2020-09-01T15:20:58Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![hedzer](https://avatars.discourse-cdn.com/v4/letter/h/77aa72/32.png) [@hedzer](https://community.prismic.io/u/hedzer)\
**Post date:** [September 1, 2020, 3:20pm UTC](https://community.prismic.io/t/cant-retrieve-documents-from-alternative-locale/1714/1 "2020-09-01T15:20:58Z")

</div>

Hi there,

I'm using Nuxt and Slice Machine for my project. I have one main locale, which is Dutch and a secondary locale, which is English. For my reservations page I use the Dutch uid 'reserveren' and the English uid 'reservations'.

When I call the slice-zone all goes well for both locales. But when I try to retrieve the document in asyncData it only returns a document on the Dutch page. On the English page it returns undefined. I use the following code:

```
async asyncData({ $prismic, params }) {
    const result = await $prismic.api.getByUID('page', params.uid)
    return {document: result}
  }

```

Am I doing something wrong? Thanks already!

---

<div class="post-metadata">

**Author:** ![Levi](https://dub1.discourse-cdn.com/flex013/user_avatar/community.prismic.io/levi/32/24_2.png) [@Levi](https://community.prismic.io/u/Levi)\
**Post date:** [September 2, 2020, 8:20am UTC](https://community.prismic.io/t/cant-retrieve-documents-from-alternative-locale/1714/3 "2020-09-02T08:20:49Z")

</div>

Hi @hedzer. I think all you need to do is to add the language query option and this should work:

```auto
async asyncData({ $prismic, params }) {
  const result = await $prismic.api.getByUID('page', params.uid, { lang : 'en-gb' })
  return {document: result}
}

```

You don’t need to add the language query option to retrieve documents in your main locale (Dutch) but you do need to include it to retrieve documents in any other locale.

---

<div class="post-metadata">

**Author:** ![hedzer](https://avatars.discourse-cdn.com/v4/letter/h/77aa72/32.png) [@hedzer](https://community.prismic.io/u/hedzer)\
**Post date:** [September 3, 2020, 12:10pm UTC](https://community.prismic.io/t/cant-retrieve-documents-from-alternative-locale/1714/5 "2020-09-03T12:10:22Z")

</div>

That was the problem, thank you very much Levi!

---

<div class="post-metadata">

**Author:** ![Levi](https://dub1.discourse-cdn.com/flex013/user_avatar/community.prismic.io/levi/32/24_2.png) [@Levi](https://community.prismic.io/u/Levi)\
**Post date:** [September 3, 2020, 1:23pm UTC](https://community.prismic.io/t/cant-retrieve-documents-from-alternative-locale/1714/6 "2020-09-03T13:23:06Z")

</div>

@hedzer You are very welcome 🙂

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/flex013/user_avatar/community.prismic.io/system/32/1746_2.png) [@system](https://community.prismic.io/u/system)\
**Post date:** [September 24, 2020, 12:52pm UTC](https://community.prismic.io/t/cant-retrieve-documents-from-alternative-locale/1714/7 "2020-09-24T12:52:59Z")

</div>

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/flex013/user_avatar/community.prismic.io/system/32/1746_2.png) [@system](https://community.prismic.io/u/system)\
**Post date:** [December 9, 2021, 5:21pm UTC](https://community.prismic.io/t/cant-retrieve-documents-from-alternative-locale/1714/8 "2021-12-09T17:21:13Z")

</div>


