One Bot Client
interface OneBotClient
Core OneBot V12 client abstraction.
It exposes a typed event stream and generic action invocation.
Inheritors
Properties
Functions
Link copied to clipboard
abstract suspend fun <T> call(action: String, params: JsonObject, serializer: KSerializer<T>): ApiResponse<T>
Calls a OneBot action and decodes the data field with serializer.
Link copied to clipboard
Calls delete_message.
Link copied to clipboard
Calls get_self_info.
Link copied to clipboard
fun OneBotClient.listenEventsAnnotated(listener: Any, scope: CoroutineScope, onHandlerError: (Throwable, OneBotEvent) -> Unit = { error, _ -> throw error }): Job
Subscribes to OneBotClient.events and dispatches each event to methods annotated with Event.
Link copied to clipboard
Calls send_message.
Link copied to clipboard
Creates a full OneBotV12Api wrapper from an existing OneBotClient.