setJsonBody

abstract fun setJsonBody(body: String)

将请求体设置为一个 JSON 字符串,并自动将 Content-Type 设置为 application/json

Parameters

body

包含有效 JSON 的字符串。