---
title: "fetchFile"
sidebar_label: "fetchFile"
description: "Kotlin binding reference: fetchFile."
---

<!-- Generated by tools/api_reference/generate_api_docs.py. Do not edit. -->

//[clika-runtime](../../../index.md)/[io.clika.runtime](../index.md)/[Http](index.md)/[fetchFile](fetchFile.md)

# fetchFile

[common]\
fun [fetchFile](fetchFile.md)(url: [String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html), destPath: [String](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html), options: [DownloadOptions](../DownloadOptions/index.md) = DEFAULTS): [HttpResponse](../HttpResponse/index.md)

GET [url](fetchFile.md) into [destPath](fetchFile.md) and answer the response facts (its body streamed to the file).