Skip to content

Latest commit

 

History

History

rest

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 

Kord REST Client

A low-level implementation of discord's rest api.

Example usage

suspend fun main(args: Array<String>) {
    val token = args.firstOrNull() ?: error("token required")

    val rest = RestClient(KtorRequestHandler(token))

    val username = rest.user.getCurrentUser().username
    println("using $username's token")
}

Installation

See the root README for more information.

Gradle (Kotlin)

dependencies {
    implementation("dev.kord:kord-rest:{version}")
}

Gradle (Groovy)

dependencies {
    implementation("dev.kord:kord-rest:{version}")
}

Maven

<dependency>
    <groupId>dev.kord</groupId>
    <artifactId>kord-rest-jvm</artifactId>
    <version>{version}</version>
</dependency>