Could not find com.android.tools.build:gradle:3.1.0

i am getting this error while trying to update the gradle recently.

build.gradle :

apply plugin: 'com.android.application'

buildscript {
    repositories {
        mavenCentral()
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:3.1.0'
    }
}

gradle.wrapper.properties

distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-4.4-all.zip

i cant identify why the dependency line referencing to a external repo. Central Repository: com/android/tools/build/gradle. where there is no (3.1.0)such a folder is found.

error:

issue arises while trying to build an .apk (‘cordova build android’) after below changes are made.

  • In build.gradle file —> changed to classpath ‘com.android.tools.build:gradle:2.2.3’ to classpath ‘com.android.tools.build:gradle:3.1.0’
  • In gradle.wrapper.properties file —> changed distributionUrl=https://services.gradle.org/distributions/gradle-3.3-all.zip to …/gradle-4.4-all.zip

Any solution to this issue ?

sorry not yet solved. and still using the older version

Did you solve it? I I have the same problem