Troubleshooting with Web API, welcomed help

Hi there,

I just got the Web API element and I’m currently doing a test with the Air Pollution API of OpenWeatherMap. I already saw the several tutorials by Thunkable on Youtube.
I made this, and the desired value doesn’t show up so I must have screwed something up.

Can anyone help me? Thanks

Link of the project : Thunkable

1 Like

You are not testing for errors as if you are confident it has to work.

I changed the Web API block to test for errors and other issues and display it.

See the code and what is displayed.

1 Like

Oh thank you very much !
I get it, there is just one thing, according to this documentation : Air Pollution - OpenWeatherMap my URL is good and when I enter this same final URL on my browser the request is displayed correctly

I’m going to try other API function

1 Like

Alright, it seems to work like if I want the longitude coordinate for example with 50 here with this block


but I would like the main.aqi (list:main:aqi) circled in red below and I tried but without making it

1 Like

No.

You have two problems in your project.

  • In the Web API block setup, you need to delete the query parameter that you added which is london,uk.
  • The second problem is how to reference the value inside the response block. It should be
1 Like

It works now, thank you have been very helpful and clear :grinning: ,
now I understand well how to deal with this Web API component.

Kind regards

1 Like