Hello,
I'm trying to make an Android App to access WorkDocs Site, It's a user level application, not administrative application.
I created my WorkDocs site and my application, so I got the application_id.
Using GET request with application_id, I obtained the access token
GET https://auth.amazonworkdocs.com/oauth?app_id=my-app-id&auth_type=ImplicitGrant&redirect_uri=https://myapp.com/callback
And then, I'm trying to do something.
The error occurs when workdocsClient is created.
val credentialsProvider = AnonymousCredentialsProvider.create()
val workDocsClient = WorkDocsClient.builder()
.region(region)
.credentialsProvider(credentialsProvider)
.build() <-- ERROR
val request = DescribeFolderContentsRequest.builder()
.folderId(folderId)
.authenticationToken(accessToken)
.build()
val result = workDocsClient.describeFolderContents(request)
for (folder in result.folders()) {
System.out.printf("Folder name=%s, Id=%s \n", folder.name(), folder.id())
}
java.lang.VerifyError: Verifier rejected class software.amazon.awssdk.http.apache.ApacheHttpClient: void software.amazon.awssdk.http.apache.ApacheHttpClient.$r8$lambda$~~~~~
build.gradle dependecy is below:
dependencies {
implementation 'androidx.core:core-ktx:1.7.0'
implementation 'androidx.appcompat:appcompat:1.6.1'
implementation 'com.google.android.material:material:1.9.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.5'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
implementation platform('software.amazon.awssdk:bom:2.20.76')
implementation 'software.amazon.awssdk:workdocs'
coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:1.1.5'
}
Please let me know how I can resolve this error or what I should check.
Thank you for your interest and reading.