> For the complete documentation index, see [llms.txt](https://docs.humdata.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.humdata.org/build/hdx-apis/file-download-endpoint.md).

# File download endpoint

## Introduction

The File URL endpoint allows you to download data from HDX directly in a programmatic way, without needing to use the HDX website. Leveraging additional endpoints like the HDX metadata endpoints further lets you access data without using the HDX UI. This approach is well suited for batch processing, scheduled pipelines, and integration with external tools that consume complete data resources directly. (For large data handling or filtering, use the Tabular Data Endpoints, link [here](https://docs.humdata.org/build/hdx-apis/tabular-data-endpoints)).

The HDX File URL endpoint is powered by the CKAN core API and relies on resource metadata to identify downloadable files.

The following documentation is intended for analysts and technical audiences who want to retrieve data files in a reproducible way, troubleshoot common issues, and integrate HDX data into automated workflows and tools.

## Building a File URL query

The file URL query is reproducible, granted you know the dataset ID and resource ID along with the format type.

<div align="left"><figure><img src="/files/6GGgYdzBH7l6j2nx8k93" alt="" width="563"><figcaption></figcaption></figure></div>

See sample URL below. Replace the `dataset_id`, `resource_id`, `resource_name`, and `format` with your desired dataset.&#x20;

`https://data.humdata.org/dataset/<DATASET_ID>/resource/<RESOURCE_ID>/download/<RESOURCE_NAME>.`

## Feedback and support

We are always adding new data and features into the HDX API endpoints. If you would like to request either a new feature or think a critical dataset is missing, please let us know!

Report bugs and request features by emailing [hdx@un.org](mailto:undefined).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.humdata.org/build/hdx-apis/file-download-endpoint.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
