getCookies

suspend fun getCookies(link: String, userAgent: String = webJs.defaultUserAgent, headers: Map<String, String> = emptyMap(), timeout: Long = 1000): String?

Get the cookies of the link after being loaded in a Webview

Return

The cookies of the link

Parameters

link

Link to be loaded in the webview

userAgent

Optional user agent to be used while loading the link

headers

Optional additional headers

timeout

Time to wait after onPageFinished is called before getting the cookies