The SVG download service returns annotations associated with the specified SectionImage as scalable vector graphics (SVG). Examples of annotations that can be retrieved include hot spots and drawings of Structure boundaries on AtlasImages. Add the “groups=” parameter and specify one or more GraphicGroupLabel.id delimited by commas to filter the types of SVG returned.
http://api.brain-map.org/api/v2/svg_download/[SectionImage.id]?groups=[#, #, #...]
Find Atlases that have AtlasImages annotated with Structure boundaries, and the relevant GraphicGroupLabel.ids:
http://api.brain-map.org/api/v2/data/query.xml?criteria= model::Atlas,
rma::include,graphic_group_labels[name$il'Atlas*'],
rma::options[only$eq'atlases.id,atlases.name,graphic_group_labels.id']
Download a list of AtlasImages from the “Mouse, P56 Coronal” Atlas (id=1) that have Structure boundary annotations (GraphicGroupLabel.id=28):
http://api.brain-map.org/api/v2/data/query.csv?criteria= model::AtlasImage,
rma::criteria,atlas_data_set(atlases[id$eq1]),graphic_objects(graphic_group_label[id$eq28]),
rma::options[tabular$eq'sub_images.id'][order$eq'sub_images.id'] &num_rows=all&start_row=0
Download the structure boundary annotations (GraphicGroupLabel.id=28) for an AtlasImage (id=100960033) as a file (.svg):
http://api.brain-map.org/api/v2/svg_download/100960033?groups=28
Display SVG in most browsers:
http://api.brain-map.org/api/v2/svg/100960033?groups=28
SVG as either a downloaded file or displayed in the browser.
Explore how brain atlases are created and organized through ontologies. Learn about anatomical structure hierarchies and classification systems.

A set of high resolution digital reference atlases have been created to provide neuroanatomical context to in situ hybridization, microarray, RNA-sequencing and axonal projection data.
From the API, you can:
The following Atlases are available through the API (click on Atlas ID to launch the interactive atlas viewer):
The sections for each Atlas come from a single AtlasDataSet (child class of SectionDataSet) and single Specimen. Typically, only a subset of AtlasImages (child class of SectionImage) is used for the reference atlas. An “annotated” image is identified by the SubImage “annotated” attribute and the corresponding image type. Please note that multiple line example RMA queries on this page use the “+” character to represent spaces for browser compatibility.
Examples:
http://api.brain-map.org/api/v2/data/query.xml?criteria=model::AtlasImage,
rma::criteria,
[annotated$eqtrue],
atlas_data_set(atlases[id$eq1]),
alternate_images[image_type$eq'Atlas+-+Adult+Mouse'],
rma::options[order$eq'sub_images.section_number'][num_rows$eqall]
http://api.brain-map.org/api/v2/data/query.xml?criteria=model::AtlasImage,
rma::criteria,
[annotated$eqtrue],
atlas_data_set(atlases[id$eq138322605]),
alternate_images[image_type$eq'Atlas+-+Developing+Human'],
rma::options[order$eq'sub_images.section_number'][num_rows$eqall]

Once the annotated images have been identified, the image ID can be used to download the colorized and labeled images using the Image Download Service and the vector graphics using the SVG Download Service.
Examples:
http://api.brain-map.org/api/v2/atlas_image_download/100960248?downsample=4&annotation=true
http://api.brain-map.org/api/v2/svg/112360908?groups=31,113753815,113753816,141667008&downsample=8
http://api.brain-map.org/api/v2/svg_download/112360908?groups=31,113753815,113753816,141667008&downsample=8
In the API, a Structure represents a neuroanatomical region of interest. Structures are grouped into Ontologies and organized in a hierarchy or StructureGraph. With the exception of the “root” structure, each Structure has one parent and denotes a “part-of” relationship. Structures are assigned a color to visually emphasize their hierarchical position in the brain. See the Structure model page for listing of attributes and associations.
Major structural ontologies used in the Allen Brain Atlas Data Portal:
From the API, Structure and Ontology information can be downloaded in various formats.
Examples:
http://api.brain-map.org/api/v2/data/query.csv?criteria=model::Structure, rma::criteria,[ontology_id$eq7], rma::options[order$eq%27structures.graph_order%27][num_rows$eqall]
http://api.brain-map.org/api/v2/structure_graph_download/1.json
http://api.brain-map.org/api/v2/structure_graph_download/16.jsonMaster image-to-image synchronization for comparing brain atlas data. Navigate corresponding sections across multiple datasets simultaneously.

The following set of image synchronization services uses the image alignment results from the Informatics Data Processing Pipeline. Note: all locations on SectionImages are reported in pixel coordinates and all locations in 3-D ReferenceSpaces are reported in microns.
For a specified Atlas, find the closest annotated SectionImage and (x,y) location as defined by a seed SectionImage and seed (x,y) location.
http://api.brain-map.org/api/v2/image_to_atlas/[SectionImage.id].[xml|json]?x=[#]&y=[#]&z=[#]&atlas_id=[#]
For a seed location in SectionImage 68173101, locate the closest image and (x,y) position within the P56 coronal Atlas:
http://api.brain-map.org/api/v2/image_to_atlas/68173101.xml?x=6208&y=2368&atlas_id=1
XML or JSON document containing the following:
For a list of target SectionDataSets, find the closest SectionImage and (x,y) location as defined by a seed SectionImage and seed (x,y) pixel location.
http://api.brain-map.org/api/v2/image_to_image/[SectionImage.id].[xml|json]?x=[#]&y=[#]§ion_data_set_ids=[#,#,#...]
For seed location in SectionImage 68173101, locate the closest 3-D position in each input SectionDataSet.
http://api.brain-map.org/api/v2/image_to_image/68173101.xml?x=6208&y=2368§ion_data_set_ids=67810540,69782969
XML or JSON document containing the following for each SectionDataSet in the section_data_set_ids:
For a list of target SectionImages, find the closest (x,y) location as defined by a seed SectionImage and seed (x,y) location.
http://api.brain-map.org/api/v2/image_to_image_2d/[SectionImage.id].[xml|json]?x=[#]&y=[#]§ion_image_ids=[#,#,#...]
For a seed location in SectionImage 68173101, locate the closest 2-D position in each input SectionImage:
http://api.brain-map.org/api/v2/image_to_image_2d/68173101.xml?x=6208&y=2368§ion_image_ids=68173103,68173105,68173107
XML or JSON document containing the following for each SectionImage in the section_image_ids:
For a list of target SectionDataSets, find the closest SectionImage and (x,y) location as defined by a (x,y,z) location in a specified ReferenceSpace.
http://api.brain-map.org/api/v2/reference_to_image/[ReferenceSpace.id].[xml|json]?x=[#]&y=[#]&z=[#]§ion_data_set_ids=[#,#,#...]
For a 3-D seed location in the P56 ReferenceSpace, locate the closest image and (x,y) location for each input SectionDataSet.
http://api.brain-map.org/api/v2/reference_to_image/10.xml?x=6085&y=3670&z=4883§ion_data_set_ids=68545324,67810540
XML or JSON document containing the following for each SectionDataSet in the section_data_set_ids:
For a specified SectionImage and (x,y) location, return the (x,y,z) location in the ReferenceSpace of the associated SectionDataSet.
http://api.brain-map.org/api/v2/image_to_reference/[SectionImage.id].[xml|json]?x=[#]&y=[#]
For a location in SectionImage 68173101, return the (x,y,z) position in the associated ReferenceSpace.
http://api.brain-map.org/api/v2/image_to_reference/68173101.xml?x=6208&y=2368
RMA query to return the associated ReferenceSpace:
http://api.brain-map.org/api/v2/data/query.xml?criteria=
model::SubImage, rma::criteria,[id$eq68173101],
rma::include,data_set,
rma::options[only$eq'data_sets.id,data_sets.reference_space_id,sub_images.id']
XML or JSON document containing the (x,y,z) location in the associated ReferenceSpace.
For a list of target structures, find the closest SectionImage and (x,y) location as defined by the centroid of each Structure.
http://api.brain-map.org/api/v2/structure_to_image/[SectionDataSet.id].[xml|json]?structure_ids=[#,#,#...]
For each Structure in the input list, locate the closest image and (x,y) location in SectionDataSet 68545324:
http://api.brain-map.org/api/v2/structure_to_image/68545324.xml?structure_ids=315,698,1089,703,477,803,512,549,1097,313,771,354
XML or JSON document containing the following for each Structure in the structure_ids:
Learn to download 3-D expression grid data as NRRD files. Access voxel-level gene expression values for computational brain analysis.

Download 3-D expression grid data packaged into a compressed archive file (.zip).
http://api.brain-map.org/grid_data/download/[SectionDataSet.id]&include=[images]
Download the 200um density volume for the Mouse Brain Atlas SectionDataSet 69816930:
http://api.brain-map.org/grid_data/download/69816930
Download the 200um energy and intensity volumes for Mouse Brain Atlas SectionDataSet 69816930:
http://api.brain-map.org/grid_data/download/183282970?include=energy,intensity
Download the energy volume for the Mouse Brain Atlas’ coronal Adora2a experiment.
First, search for relevant experiments’ IDs (SectionDataSets):
http://api.brain-map.org/api/v2/data/query.xml?criteria= model::SectionDataSet, rma::criteria,[failed$eq'false'],products[abbreviation$eq'Mouse'],plane_of_section[name$eq'coronal'],genes[acronym$eq'Adora2a']
Then, download the energy volume for each of the experiments’ IDs:
http://api.brain-map.org/grid_data/download/72109410?include=energy
Zip file (.zip) containing a folder filled with the default files (data_set.xml, energy.mhd, energy.raw) or the requested data volumes.

Download 3-D projection grid data packaged into a compressed .nrrd image.
http://api.brain-map.org/grid_data/download_file/[SectionDataSet.id]&image=[image]&resolution=[resolution]
Download the 100um density volume for the Mouse Connectivity Atlas SectionDataSet 181777177:
http://api.brain-map.org/grid_data/download_file/181777177
Download the 25um injection_fraction volume for Mouse Connectivity Atlas SectionDataSet 181777177:
http://api.brain-map.org/grid_data/download_file/181777177?image=injection_fraction&resolution=25
The response will be a single 32-big floating point Nrrd image named for the requested image type and resolution. If no image is specified, the density volume is returned. If no resolution is specified, 100um resolution is assumed.