-
-
Notifications
You must be signed in to change notification settings - Fork 1
Home
Damian Staszewski edited this page Jun 18, 2020
·
9 revisions
To access the APIs you'll need your own set of credentials which consist of a Developer ID (devId) and an Authentication Key (authKey). To getting those credentials, you need filling form on this link: https://fs12.formsite.com/HiRez/form48/secure_index.html
<repositories>
<repository>
<id>jcenter</id>
<url>https://jcenter.bintray.com</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>com.github.stachu540</groupId>
<!--for all games-->
<artifactId>HiRezAPI-all</artifactId>
<!--for paladins-->
<!--<artifactId>HiRezAPI-paladins</artifactId>-->
<!--for smite-->
<!--<artifactId>HiRezAPI-smite</artifactId>-->
<!--for realm royale-->
<!--<artifactId>HiRezAPI-realm</artifactId>-->
<version>${version}</version>
</dependency>
</dependencies>
repositories {
jcenter()
}
dependencies {
// for all games
compile "com.github.stachu540:HiRezAPI-all:$version"
// for paladins
// compile "com.github.stachu540:HiRezAPI-paladins:$version"
// for smite
// compile "com.github.stachu540:HiRezAPI-smite:$version"
// for realm royale
// compile "com.github.stachu540:HiRezAPI-realm:$version"
}
repositories {
jcenter()
}
dependencies {
// for all games
compile("com.github.stachu540:HiRezAPI-all:$version")
// for paladins
// compile("com.github.stachu540:HiRezAPI-paladins:$version")
// for smite
// compile("com.github.stachu540:HiRezAPI-smite:$version")
// for realm royale
// compile("com.github.stachu540:HiRezAPI-realm:$version")
}
Each classes below have #create()
method to initialize instance:
- For Smite is
SmiteGame
- For Paladins is
Paladins
- For Realm Royale is
RealmRoyale
Example:
// JAVA
Paladins.create(config -> config
.setDevId("1004")
.setAuthKey("23DF3C7E9BD14D84BF892AD206B6755C")
// setUserAgent("User Agent") - Default is "HiRezAPI <version> [Rev. <commit_hash>]"
// setSessionStorage(FileSessionStorage("session.txt")) - default is Cached while java process is in active
// setDefaultLanguage(Language.Polish) - Default is English
)
// Kotlin
SmiteGame.create {
it.devId = "1004"
it.authKey = "23DF3C7E9BD14D84BF892AD206B6755C"
// it.userAgent = "User Agent" - Default is "HiRezAPI <version> [Rev. <commit_hash>]"
// it.setSessionStorage = FileSessionStorage("session.txt") - default is Cached while java process is in active
// it.defaultLanguage = Language.Polish - Default is English
)
To Create your own Session Storage use SessionStorage
interface