# \[Solved\] Help in getting an Object from a response

**URL:** <https://community.thunkable.com/t/solved-help-in-getting-an-object-from-a-response/2465512>\
**Category:** Web API's\
**Tags:** image, help, webapi\
**Created:** [June 14, 2023, 4:32am UTC](https://community.thunkable.com/t/solved-help-in-getting-an-object-from-a-response/2465512 "2023-06-14T04:32:36Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![pacecode](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/pacecode/32/209017_2.png) [@pacecode](https://community.thunkable.com/u/pacecode)\
**Post date:** [June 14, 2023, 4:32am UTC](https://community.thunkable.com/t/solved-help-in-getting-an-object-from-a-response/2465512/1 "2023-06-14T04:32:36Z")

</div>

I am not able to get “image\_url” from this response:

```auto
{
  "correlation_id": "ID",
  "error": false,
  "response": {
    "image_url": "https://example/images/000000.png"
  }
}

```

Code:  
 ![rtyrtyrty](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/0/5/05523ebd7b9f11f5d03ba5b11829eb4066f53768.jpeg)

---

<div class="post-metadata">

**Author:** ![tatiang](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/tatiang/32/55482_2.png) [@tatiang](https://community.thunkable.com/u/tatiang)\
**Post date:** [June 14, 2023, 4:47am UTC](https://community.thunkable.com/t/solved-help-in-getting-an-object-from-a-response/2465512/2 "2023-06-14T04:47:46Z")

</div>

How do you know you’re not getting that value? Have you tried assigning the result of those blocks to a label’s text?

I can’t see the rest of your blocks but what you posted above looks correct for that JSON response. I formatted the JSON using the \</\> button in the toolbar for you because otherwise the smart quotes can invalidate the JSON when checking it at sites like [https://codebeautify.org/jsonviewer](https://codebeautify.org/jsonviewer). At that site, the JSON tree shows the path to the “image\_url” property to be object → response → image\_url which is how you have the blocks set up.

 ![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/3/2/32f350661915bd3f80190386b701654bd3cbd564.png)

---

<div class="post-metadata">

**Author:** ![pacecode](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/pacecode/32/209017_2.png) [@pacecode](https://community.thunkable.com/u/pacecode)\
**Post date:** [June 14, 2023, 5:37am UTC](https://community.thunkable.com/t/solved-help-in-getting-an-object-from-a-response/2465512/3 "2023-06-14T05:37:31Z")

</div>

In my project, the image component which had an assigned value of image\_url was not showing any image.  
Whole Block:  
 ![fghfghfghfgh](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/2/0/207e2627a0a80732bb61f3317a119d8d1b0ec79b.jpeg)

---

<div class="post-metadata">

**Author:** ![tatiang](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/tatiang/32/55482_2.png) [@tatiang](https://community.thunkable.com/u/tatiang)\
**Post date:** [June 14, 2023, 5:58am UTC](https://community.thunkable.com/t/solved-help-in-getting-an-object-from-a-response/2465512/4 "2023-06-14T05:58:51Z")

</div>

But that could be for several reasons. So:

1. What value do you get when you assign those blocks to a label? It can actually be better to use a text input because you can copy and paste from it.

2. What happens when you browse to the value in the label in Chrome or another browser (not in Thunkable Live)?

---

<div class="post-metadata">

**Author:** ![pacecode](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/pacecode/32/209017_2.png) [@pacecode](https://community.thunkable.com/u/pacecode)\
**Post date:** [June 14, 2023, 9:26am UTC](https://community.thunkable.com/t/solved-help-in-getting-an-object-from-a-response/2465512/5 "2023-06-14T09:26:55Z")

</div>

Thanks! Actually the image loaded very late.

---

<div class="post-metadata">

**Author:** ![pacecode](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/pacecode/32/209017_2.png) [@pacecode](https://community.thunkable.com/u/pacecode)\
**Post date:** [June 22, 2023, 10:13am UTC](https://community.thunkable.com/t/solved-help-in-getting-an-object-from-a-response/2465512/6 "2023-06-22T10:13:28Z")

</div>

Can you help me with this one also?  
How do I get the name object in 1st Book detail?

```auto
[
  {
    "book_id": 53152636,
    "name": "Mexican Gothic",
    "author": "Silvia Moreno-Garci",
    "votes": 85626,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1607462569l/53152636._SY475_.jpg",
    "url": "https://www.goodreads.com/book/show/53152636-mexican-gothic?from_choice=true"
  },
  {
    "book_id": 48838041,
    "name": "If It Bleeds",
    "author": "Stephen Kin",
    "votes": 47552,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1598366651l/48838041._SY475_.jpg",
    "url": "https://www.goodreads.com/book/show/48838041-if-it-bleeds?from_choice=true"
  },
  {
    "book_id": 44077284,
    "name": "The Southern Book Club's Guide to Slaying Vampires",
    "author": "Grady Hendri",
    "votes": 41455,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1573175023l/44077284.jpg",
    "url": "https://www.goodreads.com/book/show/44077284-the-southern-book-club-s-guide-to-slaying-vampires?from_choice=true"
  },
  {
    "book_id": 49789629,
    "name": "The Year of the Witching",
    "author": "Alexis Henderso",
    "votes": 22173,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1576699031l/49789629.jpg",
    "url": "https://www.goodreads.com/book/show/49789629-the-year-of-the-witching?from_choice=true"
  },
  {
    "book_id": 52180399,
    "name": "The Only Good Indians",
    "author": "Stephen Graham Jone",
    "votes": 17021,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1601545259l/52180399._SY475_.jpg",
    "url": "https://www.goodreads.com/book/show/52180399-the-only-good-indians?from_choice=true"
  },
  {
    "book_id": 52454426,
    "name": "Devolution",
    "author": "Max Brook",
    "votes": 10152,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1566875204l/52454426._SX318_SY475_.jpg",
    "url": "https://www.goodreads.com/book/show/52454426-devolution?from_choice=true"
  },
  {
    "book_id": 50892288,
    "name": "The Hollow Places",
    "author": "T. Kingfishe",
    "votes": 8801,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1600022295l/50892288.jpg",
    "url": "https://www.goodreads.com/book/show/50892288-the-hollow-places?from_choice=true"
  },
  {
    "book_id": 50496875,
    "name": "Plain Bad Heroines",
    "author": "Emily M. Danfort",
    "votes": 8717,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1584977118l/50496875.jpg",
    "url": "https://www.goodreads.com/book/show/50496875-plain-bad-heroines?from_choice=true"
  },
  {
    "book_id": 44564972,
    "name": "Malorie",
    "author": "Josh Malerma",
    "votes": 7216,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1585099052l/44564972.jpg",
    "url": "https://www.goodreads.com/book/show/44564972-malorie?from_choice=true"
  },
  {
    "book_id": 49090884,
    "name": "Tender is the Flesh",
    "author": "Agustina Bazterric",
    "votes": 6275,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1594563107l/49090884.jpg",
    "url": "https://www.goodreads.com/book/show/49090884-tender-is-the-flesh?from_choice=true"
  },
  {
    "book_id": 52594581,
    "name": "The Hollow Ones",
    "author": "Guillermo del Tor",
    "votes": 2429,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1571698404l/52594581.jpg",
    "url": "https://www.goodreads.com/book/show/52594581-the-hollow-ones?from_choice=true"
  },
  {
    "book_id": 52703177,
    "name": "The Bright Lands",
    "author": "John Fra",
    "votes": 2282,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1574745711l/52703177.jpg",
    "url": "https://www.goodreads.com/book/show/52703177-the-bright-lands?from_choice=true"
  },
  {
    "book_id": 51166519,
    "name": "Lakewood",
    "author": "Megan Gidding",
    "votes": 2215,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1579612241l/51166519._SX318_SY475_.jpg",
    "url": "https://www.goodreads.com/book/show/51166519-lakewood?from_choice=true"
  },
  {
    "book_id": 52581895,
    "name": "Survivor Song",
    "author": "Paul Trembla",
    "votes": 2096,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1575564155l/52581895.jpg",
    "url": "https://www.goodreads.com/book/show/52581895-survivor-song?from_choice=true"
  },
  {
    "book_id": 49247242,
    "name": "Ring Shout",
    "author": "P. Djèlí Clar",
    "votes": 1305,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1580134382l/49247242.jpg",
    "url": "https://www.goodreads.com/book/show/49247242-ring-shout?from_choice=true"
  },
  {
    "book_id": 49295297,
    "name": "The Loop",
    "author": "Jeremy Robert Johnso",
    "votes": 1114,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1599399820l/49295297.jpg",
    "url": "https://www.goodreads.com/book/show/49295297-the-loop?from_choice=true"
  },
  {
    "book_id": 50607901,
    "name": "The Ghost Tree",
    "author": "Christina Henr",
    "votes": 672,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1586544909l/50607901.jpg",
    "url": "https://www.goodreads.com/book/show/50607901-the-ghost-tree?from_choice=true"
  },
  {
    "book_id": 53869658,
    "name": "Secret Santa",
    "author": "Andrew Shaffe",
    "votes": 427,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1598985296l/53869658.jpg",
    "url": "https://www.goodreads.com/book/show/53869658-secret-santa?from_choice=true"
  },
  {
    "book_id": 52622380,
    "name": "World Departed",
    "author": "Sarah Lyons Flemin",
    "votes": 383,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1584923508l/52622380._SY475_.jpg",
    "url": "https://www.goodreads.com/book/show/52622380-world-departed?from_choice=true"
  },
  {
    "book_id": 55456522,
    "name": "Houndings of Hell",
    "author": "Hunter Holme",
    "votes": 161,
    "cover": "https://i.gr-assets.com/images/S/compressed.photo.goodreads.com/books/1601089713l/55456522._SY475_.jpg",
    "url": "https://www.goodreads.com/book/show/55456522-houndings-of-hell?from_choice=true"
  }
]

```

---

<div class="post-metadata">

**Author:** ![tatiang](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/tatiang/32/55482_2.png) [@tatiang](https://community.thunkable.com/u/tatiang)\
**Post date:** [June 22, 2023, 3:24pm UTC](https://community.thunkable.com/t/solved-help-in-getting-an-object-from-a-response/2465512/7 "2023-06-22T15:24:47Z")

</div>

I have a tutorial that explains how to parse JSON. I think you’ll find it helpful.

> [@API JSON Tutorial (Video)](https://community.thunkable.com/t/api-json-tutorial-video/1140575):
>
> Using APIs in Thunkable and understanding how to parse JSON to get certain data from the API response is both a popular and a difficult aspect of using Thunkable. It’s not so much difficult because of Thunkable but because every API url format is different, every API documentation is different, every JSON response is different, etc. In this video, I spend a lot of time talking you through some best practices. It’s not a quick tutorial because if you rush through setting up an API in Thunkable, …

---

<div class="post-metadata">

**Author:** ![matt\_conroy](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/matt_conroy/32/150843_2.png) [@matt\_conroy](https://community.thunkable.com/u/matt_conroy)\
**Post date:** [June 22, 2023, 4:17pm UTC](https://community.thunkable.com/t/solved-help-in-getting-an-object-from-a-response/2465512/8 "2023-06-22T16:17:54Z")

</div>


