Setup android internet permission


#1

Hi,

I am trying to build a native android app and need to ask for the permission to use internet on installation.

I’ve read that I can set permissions within the app.json, but not the internet permission? Or do I have to create an android manifest xml?

Thanks very much!
Hauke


#2

Hi,

Have you looked through this list?

https://docs.expo.io/versions/latest/guides/configuration.html#permissions

If the one you want isn’t there, then you might need to detach and manipulate the project’s permissions yourself.


#3

Yes I’ve been looking through this list, but internet is not on there. I
can’t believe I am the first one running into the problem of not being able
to use the internet connection in a standalone app - that’s such a basic
feature, isnt it?


#4

Are you having some kind of issue though? Are you getting an issue in runtime with internet access?


#5

Yes, right at the start I am getting a json through ajax. This fails
completely.


#6

hey, I believe android allows the internet permission by default, but I may be wrong.

would you mind posting your code in a snack?


#7

I’ve made a snack: https://snack.expo.io/@haukebr/dronequestions

On that simulator it works perfectly fine on iOS but not android. The Server call is in line 66. Do you see any errors?


#8

I think it may be a certificate issue? Fetching over http is working fine