Fragment
annotation class Fragment(val value: String = KTORGEN_DEFAULT_NAME, val encoded: Boolean = false)(source)
Add a hash mark # introduces the optional fragment near the end of the URL.
Applied to parameter, is obtained of it; else in function is required.
Generated code:
httpClient.request {
this.url {
// Only ONE fragment per URL is allowed
this.fragment = "some_anchor"
this.encodedFragment = "some_encoded_anchor"
}
}Content copied to clipboard