Hello Thunkable,
I am connecting web api to my app. it works fine in livetest window but it throw me a error NETWORK REQUEST FAILED while test/install app on my android phone.
pls reply asap …
Welcome to the Community!
Can you share the blocks you used to call the web api?
In particular, the URLs you are using. Of course, you should hide any API keys.
Check!
Hmmm, I am not able to access that resource.
Server/Hosting permissions are NOT my long suit. In fact, they are all but a complete mystery to me. But my experience using the Firebase Emulator and thunkable has been that Thunkable Web can access local host resource, while apps cannot. This makes me wonder if perhaps the machine you are using the web Live Test on has permissons to https://youngmanbeta.com/testandroid, but https://youngmanbeta.com/testandroid is not a public site.
Again, I apologize, I don’t really understand how permissons work. Hopefully some of the other power thunkers can help you.
You are right.
https://youngmanbeta.com
requires authentication and therefore you need more input in the URL if the site permits.
Bro its a api URL so i think you check it on postman via get method .
api work on browser livetest and also in iphone but it not on Android
Because … you make spell error in url its a “testAndroid” not testandroid …
pls send request again
correct url : https://youngmanbeta.com/testAndroid
Thanks for the updated URL. I get the WORKING message on my android brower, but Thunkable Live Test on Android fails. I also verified the updated URL works on Web and iOS (images not shown). Unfortunately, I don’t have much more to add to the discussion.
I would recommend you reach out to Thunkable using the Chatbot on the Project Design page AND log an issue in GitHub.
Sorry, had one more observation. I tried adding a webviewer to the screen to see if that would be able to access the URL. When I add the webviewer, the web API also starts working.
Obviously this is not a fix, but it may be helpful to add to your GitHub ticket and act as a work around until Thunkable addresses the issue.
One other possibility to try might be to return a JSON message instead of straight text. Again, Thunkable SHOULD still work, but perhaps that change might work on android. Total W.A.G.
Well, to be fair @imponiaamanl6pe, you had testandroid
in your original screenshot:
Also, can tell us a bit more about your app. Is it just supposed to display the word working? From your blocks you also seem to have an “LoginScreen”, is there an authentication part to this too?
Thanks
okay i accept it … but brother am also shared a postman Shot.
after trying with other api it works but it does not work particularly with https://youngmanbeta.com/…
So i found it just because of my SSL cerificate (youngmanbeta.com ). certificate not allow android to connect .
any idea about how resolve it ???
Unfortunately, internet protocols are a mystery to me.
Okay … btw thankyou
I’m sure you have been “googling” the internet for solutions, but here was a promising article https://developer.android.com/training/articles/security-ssl.
Best of luck!
In my case, the Network Request Failed error was fixed on my apache web server:
grep SSLUseStapling /etc/apache2/conf-enabled/common.conf
#SSLUseStapling on → must be set to off, as linux vm does not have external access
SSLUseStapling off
Interestingly, this parameter only impacted Android 13 and above.