Instant apps min sdk version - android

I have a project that has min sdk 16 and I would like to add support to instant apps. Is it possible to add that feature to mine project? I also detect that I can't create a new project with option "Include Instant App support" to sdk < 23:
So I suppose that also not possible to add that feature to the existing project with min sdk < 23.
I will be very grateful if the answer will contain a link to the information.

The Android App Links feature was introduced in Android 6.0 and lets
users tap on a web link to open your app (if it is already installed).
Instant apps leverage the same app links feature to create HTTPS URLs
that launch activities in your instant app.
Courtesy goes to philo's Answer
There's no required minimum. 15 is fine. But FYI, your app won't run
on 15. The Instant Apps runtime itself isn't compatible that far back.
At the moment, that only goes back to 23 (but we're working on that).

According to the Android Instant Apps: Android Instant Apps supports the latest Android devices from Android 6.0 (API level 23) through Android O, across more than 40 countries. We'll be rolling out to more devices and countries soon, including expanding support to Android 5.0 (API level 21) devices shortly.
FYI : https://developer.android.com/topic/instant-apps/faqs.html

This page teaches you how to build and run a very simple instant app using Android Studio.
Android Instant App

With reference SO answer and android documentation Currently it has been fixed with android studio 3.1 Canary 5

Related

can I build against newer android SDKs without excluding owners of older phones?

so I'm using QT to develop an app for Android, and according to Sophos Mobile Security this app is "Built for outdated Android versions: this app doesn't support recent android security features. the app was built for an older version of android"
in qt creator I have android-25 set as the android build sdk (which I wouldn't consider old after all, it's 7.1.1 nougat)
how can I make this warning go away? Is there a way to build my app for a newer version of android without excluding users from using it? (I have 7.1.1, and at least I want to use my app)
thank you for your response in advance.
EDIT:
seems like there are (at least?) 3 spots where I can set an SDK version:
minimum required sdk, as seen on the screenshot here: Qt for android: change the application icon
target SDK version, as seen on the screenshot above
this was the only one I was aware an hour ago: projects->build->build android apk->android build sdk
what they govern, how to set them? should they be the same or different?
Android suggests you use the latest sdk version for targetSdkVersion and for build-tools version (they have to match). In fact, Google Play now requires you to target at least SDK 26. This will not prevent older devices from running app. Actually it will be more problematic for newer devices, as you are stating that app has been fully tested and can run on newer devices, and does not need backward compatibility. See https://developer.android.com/distribute/best-practices/develop/target-sdk for more details.
As for minSdkVersion, that is what will determine the earliest devices supported, and you should try to keep it as low as you can, and as 95-99% of your users.

Instant App, What's the actual minimum sdk

As per the android developers site, minimum sdk for Instant app is 21, ie 5.0.
link
The site clearly states : Android Instant Apps are available on the majority of devices running Android 5.0 (API level 21) and higher.
But when we create a new project as per the guideline given in this link
which states that we need to have minimum sdk of 23, to get instant app support.
And does not allow me to create a support for 5.0.
as shown in below image which I tried :
That requirement exists only in the setup wizard, and it is a bug. If you change the value to something lower after creating the project, you'll see that it builds fine and can run on API 21 and 22 devices.
The documentation is correct about supported Android versions, but note that even that doesn't dictate any particular minSdkVersion. You can build an instant app with a minSdkVersion lower than 21. It just won't run on anything before 21, since the Instant Apps Runtime itself is restricted to 21+.
For that reason, this check was always a bug, even when we didn't support devices before 23. I was told it was fixed in 3.0, though I didn't verify. I checked tonight and confirmed that the check is still present in 3.0. Could be fixed in a more recent version. But if not, we need to fix that. I'll follow up.
That requirement might be due to android run-time permission support Requesting Permissions at Run Time as official document mention
Note: Beginning with Android 6.0 (API level 23), users can revoke permissions from any app at any time, even if the app targets a lower API level. You should test your app to verify that it behaves properly when it's missing a needed permission, regardless of what API level your app targets.
Currently it has been fixed with android studio 3.1 Canary 5
For instance app minimum API 23: Android 6.0 (Marshmallow).
Please follow this link https://developer.android.com/topic/instant-apps/getting-started/first-instant-app.html

Android Studio Robotium Recorder Plugin Compatibility issue

I have Android API Levels 15,19,20,21 and Android Studio 1.0.1.
Robotium Recorder needs API 15 or higher version. Information about Robotium API support
I follow that guide from Robotium's page
and also I tried many things like those (all following steps were tested separately from each other);
I created emulators that's API level 15 and 19, Than I tried to start Robotium,It did not work.
I connected my Android phone which is API level 19,that did not work again.
I started Android Studio with administrator permission everytime.
I downloaded robotium.jar here It did not work.
I tried every method in my mind.
My minimum sdk version and target sdk version is also 19.
But when I clicked "New Robotium Test" button, immediately appears warning text that is "Please install a compatible Android API level (15 or higher)"
There is a screenshot about problem. Any advice?
You probably have two Android SDK:s installed in your computer. If you go to settings (on the left side of "New Robotium Test") you can change the SDK to be used by Robotium Recorder.
http://robotium.com/pages/user-guide-android-studio

Which android sdk packages are required to be installed and which are not required ? Are all versions of android API required to be installed?

I just installed the android apk and adt plugin for eclipse. Further in the sdk manager , I've installed all the tools , Android 4.4.2(API 19) , Android 2.1(API 7) as well as the android support library and google USB driver. Now what i want to know about is , are these packages enough to start development or am i still missing everything ?
Further what i want to know is, if i want my app to be compatible with all android versions , do i need to install all versions of Android API ??
This should be enough.
No, you just need the newest SDK, set the build target to that API version and all lower versions will be supported. For keeping backwards-compatibility, you'll also have to make sure to use APIs that are supported on the lowest SDK version you want to support
Short answer: You only have to install the ones you want to develop for.
My advice in to install at least the 5 most common ones to be able to test your app against these version.
You probably want your app to be also available for users which didn't yet update to Android 4.4.2.

Which Android platform SDK do I need?

I would like to test and distribute my phonegap app. It already runs for iPhone.
At first I installed the newest SDK (4.0.3) but this one does not run on my phone. So... i guess I have to install more.
What do I need to install in the Android SDK Manager?
All SDKs? Do I need the Sample/Arm/GoogleAPI/Sources too?
Generally I install all the SDK versions as it is good to be able to test on the various emulators to make sure you app works in all versions of Android. You should always build your application with the latest SDK but in your AndroidManifest.xml file you should have a android:minSdkVersion set to the lowest Android level you want your app to run on. For now I recommend 7 (Android 2.1) as 97% of the phones are running 2.1 or above.
As you can see in the platform versions chart here it is recommended to use Android 2.1 or 2.2 SDK to cover almost all the Android devices on the market.
I think you don't need Sample/ARM/Sources, though if you need to use Google proprietary API (for example Google Maps API) you need to use Google API versions of 2.1 or 2.2.
You only need the SDK that matches the API level you intend to build for.
This page: http://developer.android.com/resources/dashboard/platform-versions.html
has a breakdown of what devices are most active in currrent use (accessed market within 2 weeks)
Judging by that, if you target 2.1 you'd be able to install your app on 98.3% of all such devices.
It is generally best to pick the oldest platform that supports all of the features you need. Just stay at or above 1.6, that is when support for multiple screen sizes was introduced.
As I think, the best solution is SDK 2.2. Many devices work with this android version.
On your Android phone go to settings->About Phone and view the Android version. This should be the sdk you will need. Afterwords, you can just change the target android sdk version in your app and it should run on your phone. As for the folders you speak of - they contain some examples, the source code of the sdk and some additional apis to use google services. It is up to you whether you will need them. You will definitely need the platform-tools from the Android SDK manager - they provide you with the adb tool that enables you to upload applications to your device.

Categories

Resources