commonMain.builder.user.GroupDMCreateBuilder.kt Maven / Gradle / Ivy
package dev.kord.rest.builder.user
import dev.kord.common.annotation.KordDsl
import dev.kord.common.entity.Snowflake
import dev.kord.rest.builder.RequestBuilder
import dev.kord.rest.json.request.GroupDMCreateRequest
@KordDsl
public class GroupDMCreateBuilder : RequestBuilder {
public val tokens: MutableList = mutableListOf()
public val nicknames: MutableMap = mutableMapOf()
override fun toRequest(): GroupDMCreateRequest = GroupDMCreateRequest(
tokens.toList(),
nicknames.mapKeys { it.value }
)
}