# Downloading a WellKnownFile

**URL:** <https://community.brain-map.org/t/downloading-a-wellknownfile/2881>\
**Category:** Allen Brain Atlas API\
**Created:** [January 9, 2024, 4:34am UTC](https://community.brain-map.org/t/downloading-a-wellknownfile/2881 "2024-01-09T04:34:19Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ray.sanchez](https://yyz1.discourse-cdn.com/flex027/user_avatar/community.brain-map.org/ray.sanchez/32/679_2.png) [@ray.sanchez](https://community.brain-map.org/u/ray.sanchez)\
**Post date:** [January 9, 2024, 4:34am UTC](https://community.brain-map.org/t/downloading-a-wellknownfile/2881/1 "2024-01-09T04:34:19Z")

</div>

- [Prototype](https://community.brain-map.org/t/downloading-a-wellknownfile/2881#prototype-1)
- [Example](https://community.brain-map.org/t/downloading-a-wellknownfile/2881#example-2)
- [Parameters](https://community.brain-map.org/t/downloading-a-wellknownfile/2881#parameters-3)
- [Returns](https://community.brain-map.org/t/downloading-a-wellknownfile/2881#returns-4)

The WellKnownFile Download Service returns files. Examples include Agilent output files from the Human Brain Microarray product and RNA Sequencing output files from the Developing Human Developing Human Transcriptome product.

## Prototype

`http://api.brain-map.org/api/v2/well_known_file_download/[WellKnownFile.id]`

## Example

Download the Human Brain Microarray Atlas “raw” Agilent output files associated with Donor H0351.2001 and the DG Structure.

First, search for all WellKnownFiles associated with Donor H0351.2001 and the Structure DG:

```auto
http://api.brain-map.org/api/v2/data/query.xml?criteria= model::Sample,
rma::criteria,microarray_data_set(products[abbreviation$eq'HumanMA'],specimen(donor[name$eq'H0351.2001'])),structure[acronym$eq'DG'],
rma::include,microarray_slides(well_known_files)

```

Next, iterate through the WellKnownFile elements, building URLs by appending the WellKnownFile.download\_link value to “[http://api.brain-map.org](http://api.brain-map.org)”:

`http://api.brain-map.org/api/v2/well_known_file_download/3486`

## Parameters

filename String WellKnownFile.id identifying the file to download.

## Returns

The file represented by the specified WellKnownFile.id. Several file formats may be returned by this service.
