Skip to content

Latest commit

 

History

History
31 lines (25 loc) · 996 Bytes

README.md

File metadata and controls

31 lines (25 loc) · 996 Bytes

ktproto - Kotlin Library for MTProto Protocol

⚠️ ALL OF THIS IS WORK IN PROGRESS ⚠️

ktproto is a Kotlin library designed to simplify working with Telegram's MTProto protocol. This library provides the tools you need to establish connections, perform authentication, and interact with the Telegram API using the MTProto protocol.

Features

Usage

@OngoingConnection
private suspend fun main(): Unit = weakCoroutineScope {
    val transport = openKtorSocketTransport(
        hostname = "149.154.167.51",
        port = 443
    )
    val client = plainMTProtoClient(
        transport = transport,
        scope = this
    )
    repeat(10) {
        createAuthorizationKey(client, keys)
    }
    // Sending encrypted requests are not supported ATM
}