Viewing version 1.5.4+1. Open the latest package page.

appcheck

1.5.4+1

Flutter plugin that allows you to check if an app is installed/enabled, launch an app and get the list of installed apps.

Download archive

Readme

AppCheck

Pub

A Flutter plugin that allows you to check if an app is installed/enabled, launch an app and get the list of installed apps.

Installation

First, add appcheck as a dependency in your pubspec.yaml file.

Methods available

  • checkAvailability(String uri)
  • isAppInstalled(String uri)
  • getInstalledApps() (only for Android)
  • isAppEnabled(String uri) (only for Android)
  • launchApp(String uri)

Permissions

Before using the plugin, you need to add declarations in your configuration files.

Android

If you want to use the getInstalledApps() function, you need the QUERY_ALL_PACKAGES permission.

<uses-permission android:name="android.permission.QUERY_ALL_PACKAGES" />

If you only want to check certain apps and you know the packageName, add them via queries in AndroidManifest.xml.

<queries>
   <package android:name="com.google.android.apps.maps"/>
</queries>

iOS

Make sure your Info.plist file includes the necessary URL schemes under LSApplicationQueriesSchemes to check and launch other apps:

<key>LSApplicationQueriesSchemes</key>
<array>
    <string>scheme1</string>
    <string>scheme2</string>
    <!-- Add more schemes as needed -->
</array>

Example:

<key>LSApplicationQueriesSchemes</key>
<array>
    <string>fb</string>
    <string>twitter</string>
    <string>instagram</string>
    <string>whatsapp</string>
    <string>youtube</string>
    <string>comgooglemaps</string>
    <string>http</string>
    <string>https</string>
    <string>mailto</string>
    <!-- Add more schemes as needed -->
</array>

Check out Example.

Screenshots

Changelog

1.5.4

  • Support for Swift Package Manager on iOS.
  • Misc. updates to example app.

1.5.3

  • Added null check for appInfo.

1.5.2

  • You need to now make an instance of the class to use the methods, instead of using static methods. Checkout the example in the README for more info.

1.3.0 - 1.5.0

  • Minor code cleanup and dependency updates.
  • Fixes for iOS app launches and README instructions.

1.0.6

  • Lowered dart sdk constraint to >=2.12.0 from 2.17.0

1.0.5

  • Remove QUERY_ALL_PACKAGES permission due to playstore policies (check README for more info)

1.0.4

  • Fixed some lint warnings
  • Updated Dart SDK min version to 2.17

1.0.3

  • Fixed system app logic for Android
  • Fixed opening URLs on earlier iOS versions

1.0.0 - 1.0.2

  • Rewritten in Kotlin and with Null-Safety.

Installing

export PUB_HOSTED_URL=https://pub.mirror.p-hatan.com
flutter pub add 'appcheck:1.5.4+1'
pubspec.yaml
name: appcheck
description: Flutter plugin that allows you to check if an app is installed/enabled, launch an app and get the list of installed apps.
version: 1.5.4+1
homepage: https://github.com/Yash-Garg/appcheck

environment:
  sdk: ">=2.12.0 <4.0.0"
  flutter: ">=3.0.0"

dependencies:
  flutter:
    sdk: flutter

dev_dependencies:
  flutter_test:
    sdk: flutter
  flutter_lints: ^3.0.2

flutter:
  plugin:
    platforms:
      android:
        package: dev.yashgarg.appcheck
        pluginClass: AppcheckPlugin
      ios:
        pluginClass: AppcheckPlugin

Version history

VersionPublishedArchiveSHA-256
1.0.0Cached · Upstream SHA-256 matchedDownload65c93155…b43f56
1.0.1Cached · Upstream SHA-256 matchedDownload60a6bbaa…4d8c8c
1.0.2Cached · Upstream SHA-256 matchedDownload2aadcea0…791cf1
1.0.3Cached · Upstream SHA-256 matchedDownloade1a83a01…76f3b8
1.0.4Cached · Upstream SHA-256 matchedDownloaddc8b398c…41fa8d
1.0.5Cached · Upstream SHA-256 matchedDownloadf4e0527f…992630
1.0.6Cached · Upstream SHA-256 matchedDownloada9e5852e…63678f
1.1.0Cached · Upstream SHA-256 matchedDownload2682c9c2…386520
1.2.0Cached · Upstream SHA-256 matchedDownload1d87f7f6…4beae7
1.3.0Cached · Upstream SHA-256 matchedDownloadbdcd9af5…9eb16d
1.5.0Cached · Upstream SHA-256 matchedDownload6a80ae2e…3f378e
1.5.1Cached · Upstream SHA-256 matchedDownload0214f271…f50bde
1.5.2Cached · Upstream SHA-256 matchedDownload0fcbe15b…4a1909
1.5.3Cached · Upstream SHA-256 matchedDownload531ae963…8df09e
1.5.4Cached · Upstream SHA-256 matchedDownload9f0a9fc9…a1d5ba
1.5.4+1Cached · Upstream SHA-256 matchedDownload6971b1ae…3c2f17
1.6.0Cached · Upstream SHA-256 matchedDownloadaa5877ae…d2e7c0
1.7.0Cached · Upstream SHA-256 matchedDownload63abf1ba…beca1d
1.8.0Cached · Upstream SHA-256 matchedDownloade23f3034…7017ae
1.8.1Cached · Upstream SHA-256 matchedDownload79b13730…a5f854

Dependencies

flutter { "sdk": "flutter" }