# Web Api strange problem - solution

**URL:** <https://community.thunkable.com/t/web-api-strange-problem-solution/590466>\
**Category:** Questions about Thunkable X\
**Created:** [May 25, 2020, 5:13pm UTC](https://community.thunkable.com/t/web-api-strange-problem-solution/590466 "2020-05-25T17:13:22Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jonathanvalgarlh4ow](https://avatars.discourse-cdn.com/v4/letter/j/ecc23a/32.png) [@jonathanvalgarlh4ow](https://community.thunkable.com/u/jonathanvalgarlh4ow)\
**Post date:** [May 25, 2020, 5:13pm UTC](https://community.thunkable.com/t/web-api-strange-problem-solution/590466/1 "2020-05-25T17:13:22Z")

</div>

Hi,

Since yesterday i started suffering problems in Web Api component. I think that the code is ok, however, it is just working the second time you execute it… The first time it says in the smartphone “undefined” when you read the “response” and the “status” blocks. When you click again “button 5” everything works smoothly.

 ![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/a/b/ab9f2c867035325ecc8ff2563e1f531136aecae4.png)

To solve this i had to do a fake calling to the web api block and then do the good one.

![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/9/5/95534cd55dc9a0d6f3bad958c448cad911074e2d.png)

Does anyone know why is this happening??

Regards.

---

<div class="post-metadata">

**Author:** ![jonathanvalgarlh4ow](https://avatars.discourse-cdn.com/v4/letter/j/ecc23a/32.png) [@jonathanvalgarlh4ow](https://community.thunkable.com/u/jonathanvalgarlh4ow)\
**Post date:** [May 25, 2020, 7:33pm UTC](https://community.thunkable.com/t/web-api-strange-problem-solution/590466/2 "2020-05-25T19:33:27Z")

</div>

If i don´t use that “fake calling”, In the device (android phone) when i try to get the response it says “undefined”. However, in the live test it appears inside of response the next thing, with a 404 status code.

![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/d/4/d465b1aa8b05a6e24923161c78116b45b60c3bdd.png)

This just appears the first time, by the second time i click the button, everything goes fine.

---

<div class="post-metadata">

**Author:** ![ioannis](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/ioannis/32/146956_2.png) [@ioannis](https://community.thunkable.com/u/ioannis)\
**Post date:** [November 8, 2024, 11:29am UTC](https://community.thunkable.com/t/web-api-strange-problem-solution/590466/3 "2024-11-08T11:29:01Z")

</div>


