filePart

inline fun filePart(init: FilePartBuilder.() -> Unit): FilePart(source)

Creates a new FilePart using the DSL builder.

Example:

val filePart = filePart {
file {
name = "example.txt"
uri = "https://example.com/file.txt"
}
}

Return

A new FilePart instance

Parameters

init

The lambda to configure the file part


Creates a new FilePart using the Java-friendly Consumer.

Return

A new FilePart instance

Parameters

init

The consumer to configure the file part