Guides
Integration
The SDK supports multiple integration methods. Choose the one that best suits your project needs.
Version & Compatibility
- The
compdfkit-toolsversion must be consistent withcompdfkitandcompdfkit-ui.- Please select appropriate
minSdk/compileSdk/targetSdkand AGP versions according to the SDK release notes.- If R8/ProGuard obfuscation is enabled, refer to the obfuscation configuration included with the SDK.
Gradle Integration
- Open the settings.gradle file in your project root directory and add the
mavenCentralrepository:
diff
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
google()
+ mavenCentral()
}
}- Open the build.gradle file in your application module directory:

Edit and add the ComPDFKit_Tools module dependency:
groovy
def compdfVersion = "2.6.0" // Must match compdfkit / compdfkit-ui version
dependencies {
implementation "com.compdf:compdfkit-tools:${compdfVersion}"
// Or depend on core and UI modules separately (versions must match):
// implementation "com.compdf:compdfkit:${compdfVersion}"
// implementation "com.compdf:compdfkit-ui:${compdfVersion}"
}Manual Integration
- Copy ComPDFKit-Tools.aar to the libs directory of the app module.

- Add the following code to the build.gradle file under the app directory:
groovy
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar', '*.aar'])
}Make sure to also depend on ComPDFKit.aar and ComPDFKit-UI.aar via manual integration to ensure proper operation.
Source Code Integration
You can obtain the ComPDFKit_Tools module source code from the SDK installation package or the GitHub sample project.
- Download or extract the SDK source code.
- In Android Studio, import the module via File → New → Import Module.

- Add the following to
app/build.gradle:
groovy
dependencies {
implementation project(path: ':ComPDFKit_Tools')
}Source code integration allows you to directly modify the Tools module code for deeper customization.