All Products
Search
Document Center

Installation

Last Updated: Jul 11, 2019

Environment requirements

JDK V6 or later is installed.

Install the SDK

Add a Maven repository and dependencies.

  • Add a Maven repository.
<repositories>
      <repository>
        <id>sonatype-nexus-staging</id>
        <name>Sonatype Nexus Staging</name>
        <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
        <releases>
            <enabled>true</enabled>
        </releases>
        <snapshots>
            <enabled>true</enabled>
        </snapshots>
      </repository>
    </repositories>
  • Add JAR package dependencies.
<dependency>
    <groupId>com.aliyun</groupId>
    <artifactId>aliyun-java-sdk-core</artifactId>
    <version>4.3.3</version>
  </dependency>
  <dependency>
    <groupId>com.aliyun</groupId>
    <artifactId>aliyun-java-sdk-vod</artifactId>
    <version>2.15.1</version>
  </dependency>
  <dependency>
    <groupId>com.google.code.gson</groupId>
    <artifactId>gson</artifactId>
    <version>2.8.2</version>
  </dependency>

Note:

  • The version of aliyun-java-sdk-core must be V4.3.3 or later.
  • For more information about the version of aliyun-java-sdk-vod, see Server SDK version history. The firstversion number on the page is the latest one.