apk-manifest-parser
v1.1.13
Published
TS library to parse the manifest of an APK file from either client side or node.
Downloads
308
Readme
Manifest Parser
This is a TypeScript project that extracts the packageName, versionCode, and versionName from an Android APK file by retrieving the AndroidManifest.xml file. This project can be used by both client side and node.
Installation and Setup
To install, follow these steps:
- Run
npm i apk-manifest-parser
where you wish to install the package - Import the package where you require it's use
import ManifestParser from 'apk-manifest-parser'
; - Call the
extractApkManifest
function passing in the apk file - this returns a promise so will need to follow up with a.then()
which returns an objectManifestPackageDetails
or the error handler objectApkParseError
.
ALternative options
- If you wish to extract information other than the 3 currently supported, pass in an array of the names you wish to retrieve (i.e.
['packageName', 'customValue']
), these results will be returned in the altOptions array.
Contributing
If you would like to contribute to this project, feel free to create a pull request.
License
This project is licensed under the MIT License.