Skip to content

Commit 077c1e4

Browse files
ivo.liondovivo.liondov
authored andcommitted
Update instructions to use latest SDK for Android and also maven central repository
1 parent 3db7b24 commit 077c1e4

3 files changed

Lines changed: 9 additions & 28 deletions

File tree

README.md

Lines changed: 4 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -7,29 +7,16 @@ This page provides all the steps for integrating Approov into your app. Addition
77
To follow this guide you should have received an onboarding email for a trial or paid Approov account.
88

99
## ADDING APPROOV SERVICE DEPENDENCY
10-
The Approov integration is available via [`jitpack`](https://jitpack.io). This allows inclusion into the project by simply specifying a dependency in the `gradle` files for the app.
11-
12-
Firstly, `jitpack` needs to be added to the end the `repositories` section in the `build.gradle` file at the top root level of the project:
10+
The Approov integration is available via [`maven`](https://mvnrepository.com/repos/central). This allows inclusion into the project by simply specifying a dependency in the `gradle` files for the app.
11+
The `Maven` repository is already present in the gradle.build file so the only import you need to make is the actual service layer itself:
1312

1413
```
15-
allprojects {
16-
repositories {
17-
...
18-
maven { url 'https://jitpack.io' }
19-
}
20-
}
14+
implementation("io.approov:service.httpsurlconn:3.3.0")
2115
```
2216

23-
Secondly, add the dependency in your app's `build.gradle`:
24-
25-
```
26-
dependencies {
27-
implementation 'com.github.approov:approov-service-httpsurlconn:3.2.2'
28-
}
29-
```
3017
Make sure you do a Gradle sync (by selecting `Sync Now` in the banner at the top of the modified `.gradle` file) after making these changes.
3118

32-
This package is actually an open source wrapper layer that allows you to easily use Approov with `HttpsUrlConnection`. This has a further dependency to the closed source [Approov SDK](https://github.com/approov/approov-android-sdk).
19+
This package is actually an open source wrapper layer that allows you to easily use Approov with `HttpsUrlConnection`. This has a further dependency to the closed source [Approov SDK](https://central.sonatype.com/artifact/io.approov/approov-android-sdk).
3320

3421
## MANIFEST CHANGES
3522
The following app permissions need to be available in the manifest to use Approov:

SHAPES-EXAMPLE.md

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -38,22 +38,14 @@ The subsequent steps of this guide show you how to provide better protection, ei
3838

3939
## ADD THE APPROOV DEPENDENCY
4040

41-
The Approov integration is available via [`jitpack`](https://jitpack.io). This allows inclusion into the project by simply specifying a dependency in the `gradle` files for the app. Firstly, `jitpack` needs to be added as follows to the end the `repositories` section in the `build.gradle` file at the top level of the project:
41+
The Approov integration is available via [`jitpack`](https://jitpack.io). This allows inclusion into the project by simply specifying a dependency in the `gradle` files for the app. The `Maven` repository is already present in the gradle.build file so the only import you need to make is the actual service layer itself.
4242

43-
```
44-
maven { url 'https://jitpack.io' }
45-
```
46-
47-
![Project Build Gradle](readme-images/root-gradle.png)
48-
49-
The `approov-service-httpsurlconn` dependency needs to be added as follows to the `app/build.gradle:36` at the app level:
43+
The `approov-service-httpsurlconn` dependency needs to be added as follows to the `app/build.gradle` at the app level:
5044

5145
![App Build Gradle](readme-images/app-gradle.png)
5246

53-
Note that in this case the dependency has been added with the tag `main-SNAPSHOT`. However, for your projects we recommend you add a dependency to a specific version:
54-
5547
```
56-
implementation 'com.github.approov:approov-service-httpsurlconn:3.2.2'
48+
implementation("io.approov:service.httpsurlconn:3.3.0")
5749
```
5850

5951
Make sure you do a Gradle sync (by selecting `Sync Now` in the banner at the top of the modified `.gradle` file) after making these changes.

shapes-app/build.gradle

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ buildscript {
55
repositories {
66
google()
77
jcenter()
8+
mavenCentral()
89
}
910
dependencies {
1011
classpath 'com.android.tools.build:gradle:7.1.1'
@@ -17,5 +18,6 @@ allprojects {
1718
repositories {
1819
google()
1920
jcenter()
21+
mavenCentral()
2022
}
2123
}

0 commit comments

Comments
 (0)