post

suspend fun post(path: String, body: String?): KoryHttpResponse

Sends a POST request with a string body.

Return

A KoryHttpResponse with status and body.

Parameters

path

The URL path (appended to the base URL).

body

The request body as a string.

Throws

if the response status is not 2xx.

if the request times out.

if a network error occurs.