Api works on local but not in production (Django Rest + Flutter)

Viewed 17

This is my first question in stackoverflow. I have always found answers searching but this time...

I have 2 json generated by Django Rest Framework, both of them have just strings...

The only thing i do is changing the local server urls for the production urls in my Flutter code.

While using local urls, i can display the data from both of them correctly inside a Flutter App.

While using production urls, only one is shown in the App and the other won't. Both jsons are rendered correctly in their production urls, i compared them with the local jsons urls and there is no difference at all.

Well, it is not really a question because i don't really know what to ask... just hoping some ideas... thanks.

1 Answers

make sure the AndroidManifest.xml includes the internet permission if not, add this between <Manifest> and <Application>

<uses-permission android:name="android.permission.INTERNET" /><uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
Related