JsonHttpClient
A @actions/http-client
based Http client that uses kotlinx serialization Json parsing and adds Accept
(always) and Content-Type
(*Json methods) headers.
Functions
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open suspend fun patch(url: String, data: ReadableStream, headers: HeaderProvider): JsonHttpResponse
Link copied to clipboard
inline suspend fun <T> patchJson(url: String, data: T, headers: HeaderProvider = HeaderProvider { }): JsonHttpResponse
inline suspend fun <T> patchJson(url: String, data: Flow<T>, headers: HeaderProvider = HeaderProvider { }): JsonHttpResponse
Link copied to clipboard
Link copied to clipboard
inline suspend fun <T> postJson(url: String, data: T, headers: HeaderProvider = HeaderProvider { }): JsonHttpResponse
inline suspend fun <T> postJson(url: String, data: Flow<T>, headers: HeaderProvider = HeaderProvider { }): JsonHttpResponse
Link copied to clipboard
Link copied to clipboard
inline suspend fun <T> putJson(url: String, data: T, headers: HeaderProvider = HeaderProvider { }): JsonHttpResponse
inline suspend fun <T> putJson(url: String, data: Flow<T>, headers: HeaderProvider = HeaderProvider { }): JsonHttpResponse
Link copied to clipboard
open suspend fun request(verb: String, url: String, data: Flow<String>, headers: HeaderProvider): JsonHttpResponse
open suspend fun request(verb: String, url: String, data: Flow<Buffer>, headers: HeaderProvider): JsonHttpResponse
open suspend override fun request(verb: String, url: String, data: String, headers: HeaderProvider): JsonHttpResponse
open suspend override fun request(verb: String, url: String, data: ReadableStream, headers: HeaderProvider): JsonHttpResponse
Link copied to clipboard
inline suspend fun <T> requestJson(verb: String, url: String, data: T, headers: HeaderProvider = HeaderProvider {}): JsonHttpResponse
inline suspend fun <T> requestJson(verb: String, url: String, data: Flow<T>, headers: HeaderProvider = HeaderProvider {}): JsonHttpResponse