Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Panel

Table of Contents
maxLevel1

What's New

The following APIs were published in February 2021:

Purpose of this Guide

This guide documents the NBIA REST Search APIs released since NBIA at TCIA version 7.5 in April 2020. 

The National Biomedical Imaging Archive (NBIA) software is the radiology portal for DICOM images at The Cancer Imaging Archive. This document describes the NBIA’s representational state transfer application programming interfaces (REST API). The APIs are designed for use by image analysis and data mining tools to directly query the public and private resources of the TCIA Radiology Portal and retrieve information into their applications. The API complements the existing web interface but eliminates the need for users to visit the TCIA web pages to select and download images and then upload them into their viewing and analysis applications.

The API is a RESTful interface, accessed through web URLs. There is no software that an application needs to download to use the APIs. The application can build its own access routines using only the API documentation provided here. The interface employs predefined query functions (see REST Search APIs) that access databases.

NBIA Search API Base URL, Format, and Return Values

...

REST APIs are provided to access the search and download functions used in the TCIA radiology portal.

The NBIA Search REST APIs, described on this page, allow you to perform basic queries on and download data for image analysis from public collections. 

The NBIA Search with Authentication REST APIs, described in the NBIA Search with Authentication REST API Guide, allow you to use the same APIs described on this page to query and download data from restricted collections.

The NBIA Advanced REST APIs, described in the NBIA Advanced REST API Guide, provide advanced features geared towards developers seeking to integrate searching and downloading TCIA data into their own web and desktop applications.    

Run APIs Live on the Cloud

You can find examples for using the NBIA APIs with Python in these Jupyter Notebooks. They are set up so that you can run them in Google Colab without the need to configure your own development environment. 

NBIA Search REST API URL and Format

A call includes a base URL followed by the API and query parameters, in that order. The base URL to access

...

public data is https://services.cancerimagingarchive.net/nbia-api/services/v1.

...

Access to any NBIA Search API requires an authentication token. You must contact the TCIA Help Desk to receive the client_id and client_secret needed to generate a token.

If you want to access restricted collections, the TCIA Help Desk must give your user account permission to access them. 

You access a resource by sending an HTTPS request to the NBIA Search API server. The server replies with a response that either contains the data you requested or a status indicator. 

An NBIA Search API query takes the following structure:

Code Block
<Token><BaseURL><Resource><QueryEndpoint>?<QueryParameters>

For example, the API shown below requests all Body Part Values and Counts for the PT modality.

...

Note
titleBase URL for NLST Data

To access National Lung Screening Trial (NLST) data, use the following base URL instead: https://nlst.cancerimagingarchive.net/nbia-api/services/

For example, in the following URL:

https://services.cancerimagingarchive.net/nbia-api/services/v1/getSeries?Collection=RIDER%20Pilot&PatientID=1.3.6.1.4.1.9328.50.1.0001&StudyInstanceUID=1.3.6.1.4.1.9328.50.1.2&format=csv

...

  • /v1/.
  • The API endpoint is getSeries.
  • The four query parameters are provided as follows: Collection=RIDER Pilot&PatientID=1.3.6.1.4.1.9328.50.1.0001&StudyInstanceUID=1.3.6.1.4.1.9328.50.1.2&format=csv
  • Data can be obtained in the following formats: CSV, HTML, XML, and JSON.  JSON is the default return format if no format parameter is specified
Note
  • The order in which the query parameters are provided does not matter.  
  • NBIA Search REST APIs can only access public data.  If you want to use these APIs to access restricted collections, see NBIA Search with Authentication REST API Guide.


Excerpt

Image Download APIs

Use the APIs in the following table to download images from TCIA. 

Query Name

Return Values

Output Format

Query Parameters

Usage

getImage

An object that represents a set of images in a ZIP file based on SeriesInstanceUID.

The naming scheme for the NewFileNames parameter changes from sequential numbers to acquisition number - instance number (in correct order).

API example and return values for getImage

ZIP

SeriesInstanceUID (R)

NewFileNames (O) - Accepted values are Yes and No.

Used for bulk transfer of all images in a series.

getImageWithMD5Hash

All images in the series and MD5 hash values

API example and return values for getImageWithMD5Hash

ZIPSeriesInstanceUID (R)Used for bulk transfer of images with the ability to check MD5Hash.

getSingleImage

A single DICOM Object that is identified by its SeriesInstanceUID and SOPInstanceUID. This API will always be used following the getSOPInstanceUIDs.

API example and return values for getSingleImage

Raw DICOM Object

SeriesInstanceUID (R)

SOPInstanceUID (R)

Used to retrieve a single image.

Image Metadata APIs

Use the APIs in the following table to explore the metadata of objects in the TCIA database. Queries return a file in one of these data formats: CSV, HTML, XML, and JSON. JSON is the default return format if no format parameter is specified.

Query Name

Return Values

Query Parameters

getBodyPartValues

Set of all body part names filtered by query keys

API example and return values for getBodyPartValues

Collection (O)

Modality (O)

getCollectionValues

Set of all collection names

API example and return values for getCollectionValues

None

getContentsByName

Return the contents of your cart. To get the name of the cart contents, you must add data to your cart in the TCIA Radiology Portal, and then select Share My Cart. An example of the URL that appears is https://nbia.cancerimagingarchive.net/nbia-search/?saved-cart=nbia-54241629300063058. The cart name is what follows the equal sign, so in this example, the cart name is nbia-54241629300063058.

API example and return values for getContentsByName

name (R)

DateReleased (O)

getManufacturerValues

Set of all manufacturer names filtered by query keys

API example and return values for getManufacturerValues

Collection (O)

BodyPartExamined (O)

Modality (O)

getModalityValues

Set of all modality values (CT, MR, ...) filtered by query keys

API example and return values for getModalityValues

Collection (O)

BodyPartExamined (O)

NewPatientsInCollection

Set of patients, in a specified collection, since a specified date

API example and return values for NewPatientsInCollection

Collection (R)

Date (R)

NewStudiesInPatientCollection 

Set of new studies for given patient and collection since a specified date

API example and return values for NewStudiesInPatientCollection

Collection (R)

Date (R)

PatientID (R)

getPatient

Set of patient objects filtered by query keys

API example and return values for getPatient

Collection (O)

getPatientByCollectionAndModality

Returns a list of PatientIDs, given a specific Collection Name and Modality

API example and return values for getPatientByCollectionAndModality

Collection (R)

Modality (R)

getPatientStudy

Set of patient/study objects filtered by query keys

API example and return values for getPatientStudy

Collection (R)

PatientID (O)

StudyInstanceUID (O)

getSeries

Set of series objects filtered by query keys

API example and return values for getSeries

SeriesInstanceUID (O) 

StudyInstanceUID (O)

Modality (O)

ProtocolName (O)

SeriesDate (O)

SeriesDescription (O)

BodyPartExamined (O

SeriesNumber (O)

AnnotationsFlag (O)

Collection (O)

PatientID (O)

Manufacturer (O)

ManufacturerModelName (O)

SoftwareVersions (O)

ImageCount (O)

TimeStamp (O)

LicenseName (O)

LicenseURI (O)

CollectionURI (O)

FileSize (O)

DateReleased (O)

StudyDesc (O)

StudyDate (O)

getSeriesMetaData

All of the metadata for a given SeriesInstanceUID

API example and return values for getSeriesMetaData

SeriesInstanceUID (R)

Collection (O)

3rd Party Analysis Data (O)

Data Description URI (O)

Subject ID (O)

Study UID (O)

Study Description (O)

Study Date (O)

Series Description (O)

Manufacturer (O)

Modality (O)

SOP Class UID (O)

Number of Images (O)

File Size (O)

File Location (O)

Series Number (O)

License Name (O)

License URL (O)

Annotation Size (O)

Date Released (O)

SeriesDate (O)

ProtocolName (O)

BodyPartExamined (O)

AnnotationsFlag (O)

ManufacturerModelName (O)

SoftwareVersions (O)

TimeStamp (O)

getSeriesSize

Set of total byte size and object count filtered by query key

API example and return values for getSeriesSize

SeriesInstanceUID (R)

getSOPInstanceUIDs

A list of SOPInstanceUIDs for a given series using the SeriesInstanceUID

API example and return values for getSOPInstanceUIDs

SeriesInstanceUID (R)

getUpdatedSeries

Set of series updated since a specified date

API example and return values for getUpdatedSeries

fromDate (R)

Date Released (O)


Return Values

This section lists and explains the return values of the APIs included in both tables above.

Note

If the value for an attribute is not populated in the specified collection, it will not appear in the returned values.


Table of Content Zone
locationtop

getBodyPartValues

Code Block
titleSample Call
https://services.cancerimagingarchive.net/nbia-api/services/v1/getBodyPartValues


AttributeDICOM TagDescription
BodyPartExamined0018, 0015Standard DICOM definition


Code Block
titleSample Response
"[
{ },
{
BodyPartExamined: ""ABD PEL""
},
{
BodyPartExamined: ""ABD PELV""
},
{
BodyPartExamined: ""ABDOMEN""
},
{
BodyPartExamined: ""ABDOMENPELVIS""
},"

getCollectionValues

Code Block
titleSample Call
https://services.cancerimagingarchive.net/nbia-api/services/v1/getCollectionValues


AttributeDICOM TagDescription
CollectionN/AA label used to name a set of images collected for a specific trial or other reason. Assigned during the process of curating the data.


Code Block
titleSample Response
[
{
Collection: "4D-Lung"
},
{
Collection: "AAPM-RT-MAC"
},
{
Collection: "ACRIN-FLT-Breast"
},
{
Collection: "ACRIN-FMISO-Brain"
},
{
Collection: "ACRIN-NSCLC-FDG-PET"
},

getContentsByName

Code Block
titleSample Call

We can break this down as follows.

...

https://services.cancerimagingarchive.net

...

All APIs return results in JSON format except for the Thumbnail API (JPG), Manifest API (TXT), and Series Metadata API (CSV).

Secure Access to NBIA REST Services

Access to any NBIA Search API requires a token that you must request.

Note

The credentials you pass differ based on whether the collections include public or restricted data. You must contact the TCIA Help Desk for permission to access private collections and receive the client_id and client_secret values required for RESTful access to those collections. 

The NBIA REST API supports secure access to private data in the Client Credentials authorization flow with Spring Security and OAuth2. The Client Credentials authorization flow is also known as "signed fetch" or 2-legged OAuth. The following figure illustrates the typical use case for REST API calls made on the web using 2-legged OAuth. For more information regarding the specific workflow, consult the OAuth2 Specification

     +---------+                                  +---------------+
     |         |                                  |               |
     |         |>--(A)- Client Authentication --->| Authorization |
     | Client  |                                  |     Server    |
     |         |<--(B)---- Access Token ---------<|               |
     |         |                                  |               |
     +---------+                                  +---------------+

Figure 1: Client Credentials Flow

This flow includes the following steps:

  1. The client authenticates with the authorization server and requests an access token from the token endpoint.
  2. The authorization server authenticates the client, and if valid, issues an access token.

This token can then be used on subsequent requests to authorize access to resources. The NBIA Search REST server also supports token expiration and extension by refresh. The time it takes tokens to expire is currently two hours but is configurable.

To access TCIA using an NBIA Search REST API, you must do the following:

Requesting a Token

Access to any NBIA Search API requires an authentication token. You must contact the TCIA Help Desk to receive the client_id and client_secret needed to generate a token. 

A request for a token takes the following structure. Refer to the table below for the correct username and password to pass in the call.

Code Block
username=<username>&password=<password>&client_id=<theClientIDFromHelpDesk>&client_secret=<theClientSecretFromHelpDesk>&grant_type=password" -X POST -k https://services.cancerimagingarchive.net/nbia-api/oauth/token

...

Request a token by interacting with the application in the following way.

  1. The application requests credentials. The credentials you pass are different depending on if you want to access public or restricted data (see above).
  2. The application sends a request to the service using the credentials you provided as a query string for the body. 

    • grant_type=password
    • username
    • password
  3. The service responds with access token details and expiration information.

    • access_token
    • expires_in
    • token_type

    The application makes a request for resources using the returned access token. All APIs listed for accessing public data also support secure access to restricted data with an additional parameter for the access token. 

Example Request for a Token to Access Public Collections

All public collections are accessible through the nbia_guest account without a password. Do the following to request a token to use when accessing public data.

Code Block
# Request for token to access public data
          
$ curl -X -v -d "username=nbia_guest&password=&client_id=theClientIDFromHelpDesk&client_secret=theClientSecretFromHelpDesk&grant_type=password" -X POST -k https://services.cancerimagingarchive.net/nbia-api/oauth/token

Example Request for a Token for a Specific User to Access Private Collections

Most data in TCIA are fully public. However, certain collections require special permissions to access them. To access these collections, you must first register for a TCIA account (be sure to scroll down on this page and click "CLICKING HERE" to accept the terms and conditions) and then contact the TCIA Help Desk for permission to access the restricted data. The TCIA Help Desk will also give you the client_id and client_secret. An example follows that shows how to request NBIA REST services for restricted data.

Code Block
# Request for token for a specific user to access restricted data
          
$ curl -X -v -d  "username=MyUsername&password=MyPassword&client_id=theClientIDFromHelpDesk&client_secret=theClientSecretFromHelpDesk&grant_type=password" -X POST -k https://services.cancerimagingarchive.net/nbia-api/oauth/token

Example of How a Token is Returned/Granted/Given

A successful token request returns a standard access token in JSON format.

Code Block
{"access_token":"f7889076-b3e4-4768-9419-3cd973adda76","token_type":"bearer","refresh_token":"671bb72b-f929-4ef5-a4d7-b52341a6007a","expires_in":7199}

Using the Token in an API Call

Make a note of the access token you received and pass it with the REST service call.

Code Block
# Request for modality values           
$ curl -H "Authorization:Bearer f7889076-b3e4-4768-9419-3cd973adda76" -k "https://services.cancerimagingarchive.net/nbia-api/services/v2/getModalityValues" 

A successful service request returns the value in a defined format. The example of the returned result for the preceding service call is as follows. Note that this result may not represent the full list of modalities in the database and is subject to change.

Code Block
[{"Modality":"CR"},{"Modality":"CT"},{"Modality":"DX"},{"Modality":"HC"},{"Modality":"HISTOPATHOLOGY"},{"Modality":"MR"},{"Modality":"PR"},{"Modality":"PT"},{"Modality":"RTDOSE"},{"Modality":"RTPLAN"},{"Modality":"RTSTRUCT"},{"Modality":"SC"},{"Modality":"SR"},{"Modality":"US"},{"Modality":"XA"} {"Modality":"CTPT"}{"Modality":"FUSION"}{"Modality":"KO"}{"Modality":"MG"}{"Modality":"REG"}{"Modality":"RWV"}{"Modality":"SEG"}]

Example Request for Refreshing the Token

The time it takes tokens to expire is configurable but is currently two hours.

Code Block
# Request for refreshing the token   
$ curl -X -v -d "refresh_token=7c2414a1-1f2f-4c9e-82a0-69fcb9fd18ed&client_id=theClientIDFromHelpDesk&client_secret=theClientSecretFromHelpDesk&grant_type=refresh_token" -X POST -k https://services.cancerimagingarchive.net/nbia-api/oauth/token

In the following result, 119 is the seconds before the token expires.

Code Block
{"access_token":"bbe4aa2c-7235-41ad-9770-31619d3dbd15","token_type":"bearer","refresh_token":"671bb72b-f929-4ef5-a4d7-b52341a6007a","expires_in":119}

Example Request for Logout

Code Block
# Request for logout
$ curl -H "Authorization:Bearer caa278aa-e7a9-45b8-a7ec-2c83d4b03cc0" -k "https://services.cancerimagingarchive.net/nbia-api/logout"

The result:  

Code Block
 You Have Logged Out successfully.

REST Search APIs

The TCIA Radiology Portal’s search uses the following REST APIs.

Collection Description API 

The Collection Description API retrieves collection descriptions.

The API optionally takes one argument:

  • collectionName - The name of the Collection. If omitted, all collections are returned.

Example Collection Description Query 

Table of Content Zone
maxLevel2
locationtop

Body Part Values and Counts API

The Body Part Values and Counts API returns the modality values and body part count for the modality. It optionally takes the following parameters.

  • Collection
  • Modality

Example Body Part Values and Counts Query

Code Block
curl -H "Authorization:Bearer cd2b2895-85d0-49c5-bd75-804f162da942" -k "https://services.cancerimagingarchive.net/nbia-api/services/getBodyPartValuesAndCounts?Modality=PT"

The API returns the body parts and their counts.

Code Block
[
{"criteria":"ABDOMEN","count":"13"},
{"criteria":"CHEST","count":"298"},
{"criteria":"Chest","count":"1"},
{"criteria":"HEADNECK","count":"1"},{
"criteria":"Lung","count":"76"},
{"criteria":"THORAX_1_ROUTINE","count":"1"}
]
HTML Comment
hiddentrue
Code Block
C:\>curl -H "Authorization:Bearer 1724fb17-b3a5-488c-9c6f-877f489e0489" -k "http://services.cancerimagingarchive.net/nbia-api/services/getCollectionDescriptions?collectionName=IDRI"

The API returns the Search Criteria Descriptions.

Code Block
[
{"description":"<p>IDRI is a limited access subset of the LIDC collection. Please view the <a href=\"https://wiki.cancerimagingarchive.net/display/Public/LIDC-IDRI\" target=\"_blank\">LIDC</a> wiki page for more information about these images.</p>",
"id":1345486850,
"collectionDescTimestamp":null,
"collectionName":"IDRI",
"userName":"MyUsername"}
]

Collection Values and Counts API

The Collection Values and Counts API returns the collections and the subject count for the collection.

Example Collection Values and Counts Query

Code Block
curl -H "Authorization:Bearer 8159f96d-d2fc-4af9-aa83-9a29876ef758" -k “https://services.cancerimagingarchive.net/nbia-api/services/getCollectionValuesAndCounts" -d "criteriaType0=CollectionCriteria&value0=CBIS-DDSM"

 The API returns the collections with their counts.

Code Block
[
{"criteria":"IDRI","count":"614"},
{"criteria":"IDRICONDUIT","count":"66"},
{"criteria":"LIDC","count":"397"},
{"criteria":"RIDER Pilot","count":"130"},
{"criteria":"SportInjury","count":"1"},
{"criteria":"Test","count":"3"},
{"criteria":"Test2","count":"3"}
]

Create Saved Cart API

The Create Saved Cart API allows the creation of a saved cart.

The API takes four arguments:

  • list - A repeatable parameter for each series you wish to have in the saved cart
  • name- Name for the saved cart (note that names of saved carts must be unique)
  • description - Description of the saved cart
  • url - URL of the saved cart

Example Create Saved Cart Query

Code Block
curl -H "Authorization:Bearer 5e3d3b2a-2533-4257-ba76-aa498ab8d269" -k "https://services.cancerimagingarchive.net/nbia-api/services/createSharedList" -d "list=88.8.133841977708353813381069288155921822331&list=88.8.326983478845196402838719404831299211067&name=scottslist&description=mydescription&url=testurl"

DICOM Metadata by Series UID API 

The DICOM Metadata by Series UID API provides the functionality in the portal where the DICOM data is retrieved from a series.

The API takes one argument:

  • SeriesUID

The SeriesUID is available from the Drill Down API call.

Example Metadata Query 

Code Block
C:\curl>curl -H "Authorization:Bearer 25bbea7c-4b8d-4f64-9d95-6ad62313c7d6" -k "https://services.cancerimagingarchive.net/nbia-api/services/getDicomTags?SeriesUID=9999.266036705757333804188405684898037929022

The API sends back triples of all DICOM element, name, data in the file.

Code Block
[
{"element":"(0002,0001)","name":"File Meta Information Version","data":"00\\01"},
{"element":"(0002,0002)","name":"Media Storage SOP Class UID","data":"1.2.840.10008.5.1.4.1.1.2"}
...................................

DICOM Tags By Image ID API

The DICOM Tag By Image ID API returns the DICOM tags and values associated with the image.

  • imageID

The values used in this API can be derived by using the results of the imagePkId in the Drill Down to Images API.

Example DICOM Tags By Image ID Query

Code Block
C:\curl>curl -H "Authorization:Bearer d9d01317-34c3-40ac-92dc-9a1287a159e4" -k "https://services.cancerimagingarchive.net/nbia-api/services/getDicomTagsByImageID?imageID=4587520"

The API returns the tags and values.

Code Block
[{"element":"(0002,0001)","name":"File Meta Information Version","data":"00
01"},
{"element":"(0002,0002)","name":"Media Storage SOP Class UID","data":"1.2.840.10008.5.1.4.1.1.128"},
{"element":"(0002,0003)","name":"Media Storage SOP Instance UID","data":"88.8.263250895051952442807371950278727814872"},
{"element":"(0002,0010)...

Drill Down API

The Drill Down API provides the functionality in the search client where the user drills down the studies and series associated with a given patient.

The API takes a list of series to query, using the parameter "list," that repeats for each series you want to retrieve. During the workflow these values come from the series identifiers in the Extended Simple Search with Modality and Body Part Paged Query.

Example Drill Down Query 

Code Block
curl -H "Authorization:Bearer 946bddb4-d076-4fb1-8dff-81fb64d6f921" -k "https://services.cancerimagingarchive.net/nbia-api/services/getStudyDrillDown" -d "list=1376256&list=262144"

The Drill Down API returns JSON with the information to populate the drill down to study screen. There can be multiple studies.

Code Block
[ {"studyId" : "88.8.40100432719994870453539459050137164864",
  "date" : 671515200000,
  "description" : "CT CHEST W/O CONTRAST",
  "id" : 1310720,
  "seriesList" : [ {
    "seriesNumber" : "3",
    "seriesUID" : "88.8.326983478845196402838719404831299211067",
    "numberImages" : 9,
    "modality" : "CT",
    "manufacturer" : null,
    "annotationsFlag" : false,
    "annotationsSize" : 0,
    "patientId" : "Project-3076386612",
    "patientPkId" : "1277952",
    "studyId" : "88.8.40100432719994870453539459050137164864",
    "studyPkId" : 1310720,
    "totalSizeForAllImagesInSeries" : 4739336,
    "project" : "Project",
    "description" : "LUNG",
    "dataProvenanceSiteName" : null,
    "manufacturerModelName" : null,
    "softwareVersion" : null,
    "maxFrameCount" : "0",
    "seriesId" : "88.8.326983478845196402838719404831299211067",
    "seriesPkId" : 1376256,
    "exactSize" : 4739336  } ]} ]

Drill Down Using Series UIDs API

The Drill Down Using Series UIDs API provides the functionality in the portal where the user drills down the studies and series associated with a set of IDs.  In this case, the API takes Series Instance UIDs so the users can access this information outside of the Search Client workflow using any Series Instance UIDs that they are interested in.

The API simply takes a list of Series UIDs to query, using the parameter "list," that repeats for each Series UID you want to retrieve.

Example Drill Down Using Series UIDs Query 

Code Block
curl -H "Authorization:Bearer 5e3e2193-55dc-43b5-b11a-70fee2ccf50f" -k "https://services.cancerimagingarchive.net/nbia-api/services/getStudyDrillDownWithSeriesIds" -d "list=88.8.327219764444138790630242591550292040652&list=88.8.48940758713094405889891485363115655700"

The Drill Down Using Series UIDs API returns JSON with the information to populate the drill down to study screen. You can retrieve multiple studies.

Code Block
[ {"studyId" : "88.8.40100432719994870453539459050137164864",
  "date" : 671515200000,
  "description" : "CT CHEST W/O CONTRAST",
  "id" : 1310720,
  "seriesList" : [ {
    "seriesNumber" : "3",
    "seriesUID" : "88.8.326983478845196402838719404831299211067",
    "numberImages" : 9,
    "modality" : "CT",
    "manufacturer" : null,
    "annotationsFlag" : false,
    "annotationsSize" : 0,
    "patientId" : "Project-3076386612",
    "patientPkId" : "1277952",
    "studyId" : "88.8.40100432719994870453539459050137164864",
    "studyPkId" : 1310720,
    "totalSizeForAllImagesInSeries" : 4739336,
    "project" : "Project",
    "description" : "LUNG",
    "dataProvenanceSiteName" : null,
    "manufacturerModelName" : null,
    "softwareVersion" : null,
    "maxFrameCount" : "0",
    "seriesId" : "88.8.326983478845196402838719404831299211067",
    "seriesPkId" : 1376256,
    "exactSize" : 4739336  } ]} ]

Drill Down to Images API

The Drill Down to Images API allows the developer to drill down to the images in a series and have the information available to create a WADO call that can retrieve the images themselves. This API is used to create the Thumbnails screen in the portal.

The API takes a list of series to query, using the parameter "list," that repeats for each series for which you want to retrieve images.

Example Drill Down to Images Query 

Code Block
curl -H "Authorization:Bearer 946bddb4-d076-4fb1-8dff-81fb64d6f921" -k "https://services.cancerimagingarchive.net/nbia-api/services/getImageDrillDown" -d "list=1376256&list=262144"

 The API returns the information needed to populate the Thumbnails screen.

Code Block
[ {  "imagePkId" : 1409028,
  "contentDate" : null,
  "contentTime" : null,
  "seriesPkId" : 1376256,
  "instanceNumber" : 73,
  "sopInstanceUid" : "88.8.73811183841243046367164226375699603900",
  "seriesInstanceUid" : "88.8.326983478845196402838719404831299211067",
  "studyInstanceUid" : "88.8.40100432719994870453539459050137164864",
  "size" : 526592,
  "fileURI" : "C:\\projects\\NBIA\\nbia-install_6.3\\CTP-server\\CTP\\storage\\0000000000\\000\\000\\006.dcm",
  "project" : null,
  "siteName" : null,
  "frameNum" : 0
}, {
  "imagePkId" : 1409024,
  "contentDate" : null,
  "contentTime" : null,
  "seriesPkId" : 1376256,
  "instanceNumber" : 85,
8<------------------------------------------------------------------------------->8

The information needed to create a WADO call is the following snippet from this code:

Code Block
  "sopInstanceUid" : "88.8.73811183841243046367164226375699603900",
  "seriesInstanceUid" : "88.8.326983478845196402838719404831299211067",
  "studyInstanceUid" : "88.8.40100432719994870453539459050137164864",

Extended Simple Search with Modality and Body Part Paged API

The Extended Simple Search with Modality and Body Part Paged API is used to run queries for the Simple Search in the NBIA client. This API uses a variety of criteria as seen in the NBIA client, as well as the pages of data the client requests. The available criteria types and their components follow.

  • CollectionCriteria
    • value
  • ImageModalityCriteria
    • value
  • AnatomicalSiteCriteria
    • value
  • ManufacturerCriteria
    • value
  • DateRangeCriteria
    • fromDate - Formatted "dd/mm/yyyy"
    • toDate - Formatted "dd/mm/yyyy"
  • PatientCriteria
    • value
  • MinNumberOfStudiesCriteria
    • value
  • SpeciesCriteria
    • The code for the species
  • PhantomCriteria
    • yes for phantoms
  • TimePointCriteria
    • eventType the eventType for the timepoint
    • fromDate - Formatted "dd/mm/yyyy"
    • toDate - Formatted "dd/mm/yyyy"
  • SortField
    • The field to sort on
  • SortDirection
    • ascending or descending
  • Start
    • The page to start on
  • Size 
    • How many items per page

The Extended Simple Search with Modality and Body Part Paged API is used to run queries for the Simple Search in the NBIA client. This API uses a variety of criteria as seen in the NBIA client, as well as the pages of data the client requests. The available criteria types and their components follow.Since the Simple Search API can take an unlimited number of criteria each of the criteria items is appended with a number signifying its order in the query, starting with 0.

Example Extended Simple Search with Modality and Body Part Paged Query

Code Block
curl -H "Authorization:Bearer d2310d88-cefe-491f-82a2-df66d6c087c4" -k "http://localhost:8080/nbia-api/services/getSimpleSearchWithModalityAndBodyPartPaged" -d "criteriaType0=TimePointCriteria&eventType0=DIAGNOSIS&fromDay0=-5&toDay0=10&sortField=subject&sortDirection=descending&start=0&size=9"

The API returns the results of the search.

Code Block
{
   "resultSet":[
      {
         "subjectId":"Test-5910936489",
         "project":"Test",
         "id":819200,
         "modalities":[
            "CT"
         ],
         "bodyParts":[
            "LUNG"
         ],
         "species":[
            "L-877FC"
         ],
         "timepoints":{
            "DIAGNOSIS":[
               1,
               3
            ]
         },
         "totalNumberOfStudies":28,
         "totalNumberOfSeries":61,
         "studyIdentifiers":[
            {
               "seriesIdentifiers":[
                  917526,
                  917527,
                  917528
               ],
               "seriesAndModality":[
                  
               ],
               "studyIdentifier":851979
            },
            {
               "seriesIdentifiers":[
                  917529,
                  917530
               ],
               "seriesAndModality":[
                  
               ],
               "studyIdentifier":851980
            },
            {
               "seriesIdentifiers":[
                  917531,
                  917532
               ],
               "seriesAndModality":[
                  
               ],
               "studyIdentifier":851981
            }
         ]
      }
   ],
   "totalPatients":1,
   "bodyParts":[
      {
         "value":"LUNG",
         "count":1
      }
   ],
   "modalities":[
      {
         "value":"CT",
         "count":1
      }
   ],
   "collections":[
      {
         "value":"Test",
         "count":1
      }
   ],
   "species":[
      {
         "value":"L-877FC",
         "count":1
      }
   ],
   "maxTimepoints":{
      "DIAGNOSIS":3
   },
   "minTimepoints":{
      "DIAGNOSIS":1
   },
   "sort":"subject-descending"
}

Get Licenses API

The Get Licenses API retrieves collection descriptions.

The API takes no arguments.

Example Get Licenses Query

Code Block
curl -H "Authorization:Bearer ff849ffb-7b18-4c7e-83bd-6db2f7dbee9c" -k "https://services.cancerimagingarchive.net/nbia-api/services/getLicenses"
If the API is successful, it returns the licenses.
Code Block
[
{
"longName":"Creative Commons Attribution 3.0 Unported License",
"id":1,
"shortName":"CC BY 3.0",
"licenseURL":"http://creativecommons.org/licenses/by/3.0/",
"licenseText":"https://creativecommons.org/licenses/by/3.0/",
"commercialUse":"YES",
"license":{
"id":1,
"longName":"Creative Commons Attribution 3.0 Unported License",
"shortName":"CC BY 3.0",
"url":"http://creativecommons.org/licenses/by/3.0/",
"commercialUse":"YES",
"licenseText":"https://creativecommons.org/licenses/by/3.0/"
}
},....

Get Updated Series API

This API returns the series that have been updated since a given date.

The API takes one argument:

  • fromDate - the date to get the updates have happened

Example Get Updated Series API Query

Code Block
curl -H "Authorization:Bearer 86d45ad0-2e48-4f10-bbbe-593d7176fe30" -k "http://localhost:8080/nbia-api/services/v2/getUpdatedSeries?fromDate=01/01/2020"

The API returns the updated series.

Code Block
[
   {
      "SeriesInstanceUID":"1.3.6.1.4.1.5962.1.1.0.0.1560173490.85106.1",
      "StudyInstanceUID":"1.3.6.1.4.1.5962.1.1.0.1560173490.85106.1",
      "Modality":"SR",
      "SeriesDate":"2016-01-06 00:00:00.0",
      "SeriesDescription":"PDM Mouse Overview",
      "SeriesNumber":1,
      "Collection":"Project",
      "PatientID":"128783-104-T_VQ4",
      "Manufacturer":"PixelMed",
      "ManufacturerModelName":"XSLT",
      "SoftwareVersions":"0.1",
      "ImageCount":1
   }

Manifest Text API

The Manifest Text API allows the creation of a manifest file that can be used to execute the NBIA Data Retriever.

The API takes two arguments:

  • list - A repeatable parameter of series UIDs for each series you want to download
  • includeAnnotation - If "true" is used, the annotations are returned.

Example Manifest Text Query 

Code Block
curl -H "Authorization:Bearer d98c390f-b53d-4456-beb3-110e63663762" -k "https://services.cancerimagingarchive.net/nbia-api/services/getManifestTextV2" -d "list=1.3.6.1.4.1.9328.50.3.336&includeAnnotation=false"

The API returns text that can be used as a manifest file for the NBIA Data Retriever.

Code Block
downloadServerUrl=https://imaging-devcm.nci.nih.gov/nbia-download/servlet/DownloadServlet
includeAnnotation=false
noOfrRetry=4
databasketId=manifest-1523866570303.tcia
manifestVersion=3.0
ListOfSeriesToDownload=
1.3.6.1.4.1.9328.50.3.336

Manufacturer Values and Counts API

The Manufacturer Values and Counts API returns the modality values plus the manufacturer count for the modality. It optionally takes the following parameters.

  • Collection
  • Modality
  • Body Part Examined

Example Manufacturer Values and Counts Query

Code Block
curl -H "Authorization:Bearer c428d42c-9eed-4f5d-8007-416d46be9b52" -k "https://services.cancerimagingarchive.net/nbia-api/services/getManufacturerValuesAndCountsv1/getContentsByName?Modality=PT"

The API returns the manufacturer and their counts.

Code Block
[
{"criteria":"DeJarnette Research Systems","count":"2"},
{"criteria":"FUJI PHOTO FILM Co., ltd.","count":"4"}
]

Manufacturer Tree API

The Manufacturer Tree API returns the manufacturer and software in a tree structure.

Example Manufacturer Values and Counts Query

Code Block
curl -H "Authorization:Bearer  3ecccd7d-9d72-4424-bd81-757d79cd44aa" -k "https://services.cancerimagingarchive.net/nbia-api/services/getManufacturerTree"

The API returns the manufacturer and their counts.

Code Block
{"data":{"criteria":"root","value":"All Manufactures"},
"children":[{"data":{"criteria":"Manufacturer","value":"CMS, Inc."},
"children":[{"data":{"criteria":"Model","value":"XiO"},
"children":[{"data":{"criteria":"Software Ver.","value":"4.51.00"},
"children":[]},{"data":{"criteria":"Software Ver.","value":"4.51.02"},"children":[]}]}]},
{"data":{"criteria":"Manufacturer","value":"CPS"},
"children":[{"data":{"criteria":"Model","value":"1024"}
8<------------------------------------------------------------------------------->8

Modality Values and Counts API

The Modality Values and Counts API will return the modality values plus the subject count for the modality it takes the following parameters optionally

  • Collection
  • BodyPartExamined

Example Modality Values and Counts Query

name=TCIA_TCGA-PRAD_08-09-2016-v3


AttributeDICOM TagDescription

SeriesInstanceUID

0020, 000EHas been de-identified as part of submission process

StudyInstanceUID

0020, 000DHas been de-identified as part of submission process.

Modality

0008, 0060Standard DICOM definition

ProtocolName

0018, 1030Standard DICOM definition. Has been inspected and cleaned of any PHI.

SeriesDate

0008, 0021Standard DICOM definition

SeriesDescription

0008, 103EStandard DICOM definition. Has been inspected and cleaned of any PHI.

BodyPartExamined

0018, 0015Standard DICOM definition

SeriesNumber

0020, 0011Standard DICOM definition

AnnotationsFlag

N/AIndicates if there are annotations for a collection

Collection

N/AA label used to name a set of images collected for a specific trial or other reason. Assigned during the process of curating the data.

PatientID

0010, 0020Has been de-identified as part of submission process.

Manufacturer

0008, 0070Standard DICOM definition

ManufacturerModelName

0008, 1090Standard DICOM definition

SoftwareVersions

0018, 1020Standard DICOM definition

ImageCount

N/ANumber of images in the specified series

DateReleased

N/AThe date that TCIA published the series

getImage

The license file, which includes the data usage agreement, is included in the returned ZIP file.

Code Block
titleSample Call
https://services.cancerimagingarchive.net/nbia-api/services/v1/getImage?SeriesInstanceUID=1.3.6.1.4.1.9328.50.1.216116555221814778114703363464001196508


AttributeDICOM TagDescription
N/AN/ASet of images in a ZIP file

getImageWithMD5Hash

Code Block
titleSample Call
https://services.cancerimagingarchive.net/nbia-api/services/v1/getImageWithMD5Hash?SeriesInstanceUID=1.3.6.1.4.1.14519.5.2.1.6919.4624.313514201353787659031503464798


Attribute

DICOM Tag

Description

N/AN/ASet of images in a ZIP file

getManufacturerValues

Code Block
titleSample Call
https://services.cancerimagingarchive.net/nbia-api/services/v1/getManufacturerValues


Attribute

DICOM Tag

Description

Manufacturer

0008, 0070

Standard DICOM definition

getModalityValues

Code Block
titleSample Call
https://services.cancerimagingarchive.net/nbia-api/services/v1/getModalityValues


AttributeDICOM TagDescription
Modality0008, 0060Standard DICOM definition

NewPatientsInCollection

Code Block
titleSample Call
Code Block
curl -H "Authorization:Bearer c428d42c-9eed-4f5d-8007-416d46be9b52" -k "https://services.cancerimagingarchive.net/nbia-api/services/getModalityValuesAndCountsv1/NewPatientsInCollection?Collection=LIDC"

The API returns the modalities and their counts

Code Block
[
{"criteria":"CT","count":"397"}
]

Series Metadata API

The Series Metadata API allows returns the metadata needed by the Client for a set of series as CSV.

The API takes one argument:

  • list- Comma separated list of series to return

Example Series Metadata Query

Code Block
curl -H "Authorization:Bearer 1be042c4-2506-4ecc-9c5e-9556506896aa" -k "https://services.cancerimagingarchive.net/nbia-api/services/getSeriesMetadata2" -d "list=9999.293545899757968087866143572947417050996,9999.172212451609088872857235914630319746611"

The API returns ok if successful, and the error if one occurs.

Code Block
"Subject ID","Study UID","Study Description","Study Date","Series ID","Series Description","Number of images","File Size (Bytes)","Collection Name","Modality","Manufacturer"
"LIDC-IDRI-1009708434","9999.80530326108514806420601956698897575003","CT CHEST O CONTR","1999-12-21 00:00:00.0","9999.172212451609088872857235914630319746611","","268","141000690","LIDC-IDRI","CT","GE MEDICAL SYSTEMS"
"LIDC-IDRI-1001617569","9999.217840977308171348409694654150334249839","","1999-12-21 00:00:00.0","9999.293545899757968087866143572947417050996","","46","24199232","LIDC-IDRI","CT","SIEMENS"

Simple Search Criteria Values API

The Simple Search Criteria Values API returns the possible criteria values to the client.

  • This API takes the same parameters as simple search.

Example Simple Search Criteria Values Query

=CBIS-DDSM&Date=2010/08/16


AttributeDICOM TagDescription
PatientID0010, 0020Has been de-identified as part of submission process.
PatientName0010, 0010Has been de-identified as part of submission process.
PatientBirthDate0010,0030Has been de-identified as part of submission process.
PatientSex0010,0040Standard DICOM definition
EthnicGroup0010,2160Standard DICOM definition
CollectionN/AA label used to name a set of images collected for a specific trial or other reason. Assigned during the process of curating the data.
Phantom0010, 0200Indicates whether or not the subject is a quality control phantom.
SpeciesCode0010,2202The taxonomic rank value (e.g., genus, subgenus, species or subspecies) of the Patient.
SpeciesDescription0010,2201The taxonomic rank value (e.g., genus, subgenus, species or subspecies) of the Patient.

NewStudiesInPatientCollection 

Code Block
titleSample Call
https://services.cancerimagingarchive.net/nbia-api/services/v1/NewStudiesInPatientCollection?Collection=CBIS-DDSM&Date=2010/08/16


AttributeDICOM TagDescription

StudyInstanceUID

0020, 000DHas been de-identified as part of submission process.

StudyDate

0008, 0020Has been de-identified as part of submission process. Longitudinal information is preserved.

StudyDescription

0008, 1030Standard DICOM definition. Has been inspected and cleaned of any PHI.

AdmittingDiagnosesDescription

0008, 1080Standard DICOM definition. Has been inspected and cleaned of any PHI.

StudyID

0020, 0010Has been de-identified as part of submission process.

PatientAge

0010, 1010Standard DICOM definition

PatientID

0010, 0020Has been de-identified as part of submission process.

PatientName

0010, 0010Has been de-identified as part of submission process.

PatientBirthDate

0010, 0030Has been de-identified as part of submission process.

PatientSex

0010, 0040Standard DICOM definition

EthnicGroup

0010, 2160Standard DICOM definition

Collection

N/AA label used to name a set of images collected for a specific trial or other reason. Assigned during the process of curating the data.

SeriesCount

N/AComputed number of series

LongitudinalTemporalEventType

0012, 0053The type of event to which Longitudinal Temporal Offset from Event (0012,0052) is relative.

LongitudinalTemportalOffsetFromEvent

0012, 0052An offset in days from a particular event of significance. May be fractional. In the context of a clinical trial, this is often the days since enrollment, or the baseline imaging Study.

getPatient

Code Block
titleSample Call
Code Block
curl -H "Authorization:Bearer 544bc1c7-6ea5-421c-9d10-b88ed7e52bfb" -k "https://services.cancerimagingarchive.net/nbia-api/services/getSimpleSearchCriteriaValues" -d "criteriaType0=CollectionCriteria&value0=TCGA-UCEC"
The API returns the possible criteria values.
/v1/getPatient


AttributeDICOM TagDescription
PatientId0010, 0020Has been de-identified as part of submission process.
PatientName0010, 0010Has been de-identified as part of submission process.
PatientBirthDate0010, 0030Has been de-identified as part of submission process.
PatientSex0010, 0040Standard DICOM definition
EthnicGroup0010, 2160Standard DICOM definition
CollectionN/AA label used to name a set of images collected for a specific trial or other reason. Assigned during the process of curating the data.
Phantom 0010, 0200Indicates whether or not the subject is a quality control phantom.
SpeciesCode0010,2202The taxonomic rank value (e.g., genus, subgenus, species or subspecies) of the Patient.
SpeciesDescription 0010,2201The taxonomic rank value (e.g., genus, subgenus, species or subspecies) of the Patient.

getPatientByCollectionAndModality

Code Block
titleSample Call
https://services.cancerimagingarchive.net/nbia-api/services/v1/getPatientByCollectionAndModality?Collection=VICTRE&Modality=MG


AttributeDICOM TagDescription
PatientId0010, 0020A list of patient IDs for a specified collection and modality

getPatientStudy

Code Block
titleSample Call
Code Block
[
{
"criteria":"Collections",
"values":[
{ "criteria":"CBIS-DDSM", "count":"80" }
,
{ "criteria":"BREAST-DIAGNOSIS", "count":"8" }
,

{ "criteria":"Head-Neck Cetuximab", "count":"3" }
]
},
{
"criteria":"Image Modality",
"values":[
{ "criteria":"PT", "count":"3" }
,
{ "criteria":"CT", "count":"3" }
,
{ "criteria":"MR", "count":"8" }
,

{ "criteria":"MG", "count":"82" }
]
}
]

Species Tax API

The Species Tax API returns the species taxonomy and takes no parameters.

Example Species Tax Query

Code Block
C:\curl>curl -H "Authorization:Bearer 0a6c0a95-1919-4430-888d-5375fca7566f" -k "https://services.cancerimagingarchive.net/nbia-api/services/getSpeciesTax"

The API returns the current species taxonomy.

Code Block
[\{"speciesCode":"L-877FC","speciesDescription":"Rattus norvegicus (common rat)"},\{"speciesCode":"L-85003","speciesDescription":"Human (Homo sapiens)"}]

Species Values And Counts API

The Get Species Values And Counts API returns the values and counts for species and takes the same parameters as simple search.

Example Species Values And Counts Query

Code Block
C:\curl>curl -H "Authorization:Bearer 9227f2ee-5936-4fe9-8268-131e50833527" -k "https://services.cancerimagingarchive.net/nbia-api/services/getSimpleSearchCriteriaValues" -d "criteriaType0=CollectionCriteria&value0=CBIS-DDSM"

The API returns the values and counts for species.

Code Block
[{"criteria":"Collections","values":[

{"criteria":"CBIS-DDSM","count":"80"}
]},

{"criteria":"Species","values":[\{"criteria":"Human","count":"80"}
]},

{"criteria":"Image Modality","values":[\{"criteria":"MG","count":"80"}
]},

{"criteria":"Anatomical Site","values":[\{"criteria":"BREAST","count":"80"}
]},

{"criteria":"Manufacturer","values":[\{"criteria":"","count":"80"}
]}]

Study Drill Down API

The Study Drill Down API provides the functionality in the portal where the user drills down the studies and series associated with a given user.

The API simply takes a list of series to query, using the parameter "list", that is repeated for each series you want to retrieve.

Example Study Drill Down Query

Code Block
curl -H "Authorization:Bearer 946bddb4-d076-4fb1-8dff-81fb64d6f921" -k "https://services.cancerimagingarchive.net/nbia-api/services/getStudyDrillDown" -d "list=1376256&list=262144"

The Study Drill Down API returns JSON with the information to populate the drill down to study screen. You can retrieve multiple studies.

Code Block
[ {"studyId" : "88.8.40100432719994870453539459050137164864",
  "date" : 671515200000,
  "description" : "CT CHEST W/O CONTRAST",
  "id" : 1310720,
  "seriesList" : [ {
    "seriesNumber" : "3",
    "seriesUID" : "88.8.326983478845196402838719404831299211067",
    "numberImages" : 9,
    "modality" : "CT",
    "manufacturer" : null,
    "annotationsFlag" : false,
    "annotationsSize" : 0,
    "patientId" : "Project-3076386612",
    "patientPkId" : "1277952",
    "studyId" : "88.8.40100432719994870453539459050137164864",
    "studyPkId" : 1310720,
    "totalSizeForAllImagesInSeries" : 4739336,
    "project" : "Project",
    "description" : "LUNG",
    "dataProvenanceSiteName" : null,
    "manufacturerModelName" : null,
    "softwareVersion" : null,
    "maxFrameCount" : "0",
    "seriesId" : "88.8.326983478845196402838719404831299211067",
    "seriesPkId" : 1376256,
    "exactSize" : 4739336  } ]} ]

Study Drill Down With Series IDs API

The Study Drill Down API provides the functionality in the portal where the user drills down to the studies and series associated with a given user.

The API takes a list of series to query, using the parameter "list," that is repeated for each series instance UIDs you want to retrieve.

Example Study Drill Down With Series IDs Query 

Code Block
curl -H "Authorization:Bearer 5e3e2193-55dc-43b5-b11a-70fee2ccf50f" -k "https://services.cancerimagingarchive.net/nbia-api/services/getStudyDrillDownWithSeriesIds" -d "list=88.8.327219764444138790630242591550292040652&list=88.8.48940758713094405889891485363115655700"

The Study Drill Down With Series Ids API returns JSON with the information to populate the drill down to study screen. There can be multiple studies.

Code Block
[ {"studyId" : "88.8.40100432719994870453539459050137164864",
  "date" : 671515200000,
  "description" : "CT CHEST W/O CONTRAST",
  "id" : 1310720,
  "seriesList" : [ {
    "seriesNumber" : "3",
    "seriesUID" : "88.8.326983478845196402838719404831299211067",
    "numberImages" : 9,
    "modality" : "CT",
    "manufacturer" : null,
    "annotationsFlag" : false,
    "annotationsSize" : 0,
    "patientId" : "Project-3076386612",
    "patientPkId" : "1277952",
    "studyId" : "88.8.40100432719994870453539459050137164864",
    "studyPkId" : 1310720,
    "totalSizeForAllImagesInSeries" : 4739336,
    "project" : "Project",
    "description" : "LUNG",
    "dataProvenanceSiteName" : null,
    "manufacturerModelName" : null,
    "softwareVersion" : null,
    "maxFrameCount" : "0",
    "seriesId" : "88.8.326983478845196402838719404831299211067",
    "seriesPkId" : 1376256,
    "exactSize" : 4739336  } ]} ]

Thumbnail API  

The Get Thumbnail API returns the DICOM tags and values associated with the image.

  • seriesUID
  • objectUID

Example Thumbnail Query

api/services/v1/getPatientStudy?Collection=VICTRE&Modality=MG


AttributeDICOM TagDescription
StudyInstanceUID0020, 000DHas been de-identified as part of submission process.
StudyDate0008, 0020Has been de-identified as part of submission process. Longitudinal information is preserved.
StudyDescription0008, 1030Standard DICOM definition. Has been inspected and cleaned of any PHI.
AdmittingDiagnosesDescription0008, 1080Standard DICOM definition. Has been inspected and cleaned of any PHI.
StudyID0020, 0010Has been de-identified as part of submission process.
PatientAge0010, 1010Standard DICOM definition
PatientID0010, 0020Has been de-identified as part of submission process.
PatientName0010, 0010Has been de-identified as part of submission process.
PatientBirthDate0010, 0030Has been de-identified (emptied) as part of submission process.
PatientSex0010, 0040Standard DICOM definition
EthnicGroup0010, 2160Standard DICOM definition
CollectionN/AA label used to name a set of images collected for a specific trial or other reason. Assigned during the process of curating the data.
SeriesCountN/AComputed number of series

LongitudinalTemporalEventType

0012, 0053The type of event to which Longitudinal Temporal Offset from Event (0012,0052) is relative.
LongitudinalTemporalOffsetFromEvent0012, 0052An offset in days from a particular event of significance. May be fractional. In the context of a clinical trial, this is often the days since enrollment, or the baseline imaging Study.

getSeries

Code Block
titleSample Call
https://services.cancerimagingarchive.net/nbia-api/services/v1/getSeries?Collection=VICTRE&Modality=MG


AttributeDICOM TagDescription
SeriesInstanceUID0020, 000EHas been de-identified as part of submission process
StudyInstanceUID0020, 000DHas been de-identified as part of submission process
Modality0008, 0060Standard DICOM definition
ProtocolName0018, 1030Standard DICOM definition. Has been inspected and cleaned of any PHI.
SeriesDate0008, 0021Standard DICOM definition
SeriesDescription0008, 103EStandard DICOM definition. Has been inspected and cleaned of any PHI.
BodyPartExamined0018, 0015Entered on a per-collection basis using relevant SNOMED terms
SeriesNumber0020, 0011Standard DICOM definition
AnnotationsFlagN/AIndicates if there are annotations for a collection
CollectionN/AA label used to name a set of images collected for a specific trial or other reason. Assigned during the process of curating the data.
PatientID0010, 0020Has been de-identified as part of submission process
Manufacturer0008, 0070Standard DICOM definition
ManufacturerModelName0008, 1090Standard DICOM definition
SoftwareVersions0018, 1020Standard DICOM definition
ImageCountN/AComputed number of images in this series
TimeStampN/AThe time that TCIA received the data, which is before curation and publishing
LicenseNameN/ALicense that applies to this series
LicenseURIN/AURL of license source
CollectionURIN/AURI of collection
FileSizeN/AFile size
DateReleasedN/A The date that TCIA published the series
StudyDescription0008,1030Institution-generated description or classification of the Study performed
StudyDate0008,0020Date the study started

getSeriesMetaData

Code Block
titleSample Call
https://services.cancerimagingarchive.net/nbia-api/services/v1/getSeriesMetaData?SeriesInstanceUID=1.3.6.1.4.1.14519.5.2.1.6834.5010.322628904903035357840500590726


AttributeDICOM TagDescription

Series UID

0020, 000EStandard DICOM definition

Collection

N/AA label used to name a set of images collected for a specific trial or other reason. Assigned during the process of curating the data.

3rd Party Analysis

N/AData from third-party analysis results

Data Description URI

N/ALocation of the data description

Subject ID

N/AUnique identifier for the subject

Study UID

0020, 000DStandard DICOM definition

Study Description

0008, 1030Institution-generated description or classification of the Study (component) performed

Study Date

0008, 0020Has been de-identified as part of submission process. Longitudinal information is preserved.

Series Description

0020, 0011Standard DICOM definition. Has been inspected and cleaned of any PHI.

Manufacturer

0008, 0070Standard DICOM definition

Modality

0008, 0060Standard DICOM definition

SOP Class UID

N/AUnique identifier of the SOP Class

Number of Images

N/ANumber of images in this series

File Size

N/AFile size in bytes

File Location

N/ALocation of the file in the file system

Series Number

0020,0011Standard DICOM definition

License Name

N/ALicense that applies to this series

License URL

N/AURL of license source

Annotation Size

N/ASize of annotation files in bytes

Date Released

N/AThe date that TCIA published the series

SeriesDate

0008, 0021Standard DICOM definition

ProtocolName

0018,1030Name of the protocol

BodyPartExamined

0018, 0015

Entered on a per-collection basis using relevant SNOMED terms

AnnotationsFlag

N/AIndicates if there are annotations for a collection

ManufacturerModelName

0008, 1090Standard DICOM definition

SoftwareVersions

0018, 1020Standard DICOM definition

TimeStamp

N/AThe time that TCIA received the data, which is before curation and publishing

getSeriesSize

Code Block
titleSample Call
https://services.cancerimagingarchive.net/nbia-api/services/v1/getSeriesSize?SeriesInstanceUID=1.3.6.1.4.1.14519.5.2.1.6834.5010.322628904903035357840500590726


AttributeDICOM TagDescription

TotalSizeInBytes

N/AByte size of the specified series

ObjectCount

N/ANumber of objects in the specified series

getSingleImage

Code Block
titleSample Call
https://services.cancerimagingarchive.net/nbia-api/services/v1/getSingleImage?SeriesInstanceUID=143.284188174537413748743284550513035752067&SOPInstanceUID=143.53599064898089361503082484556513429004


AttributeDICOM TagDescription
N/AN/ASingle image in DICOM format

getSOPInstanceUIDs

Code Block
https://services.cancerimagingarchive.net/nbia-api/services/v1/getSOPInstanceUIDs?SeriesInstanceUID=1.3.6.1.4.1.9590.100.1.2.374115997511889073021386151921807063992


AttributeDICOM TagDescription
SOPInstanceUID0008, 0018Uniquely identifies the SOP Instance

getUpdatedSeries

Code Block
titleSample Call
Code Block
curl -H "Authorization:Bearer f314f9bb-6752-4c5d-9f56-d2d450b7260c" -k "https://services.cancerimagingarchive.net/nbia-api/services/getThumbnail" -d "seriesUID=1.3.6.1.4.1.14519.5.2.1.3023.4024.536949365601910993926257264114&objectUID=1.3.6.1.4.1.14519.5.2.1.3023.4024.822829852603295162591249163632" --output Thumbnail.jpg
The API returns a JPG thumbnail.

Text Search API

The text search API is used to run queries for Text Search in the portal. The text search takes an argument, textValue.

Example Text Search Query 

Code Block
curl -H "Authorization:Bearer 946bddb4-d076-4fb1-8dff-81fb64d6f921" -k "https://services.cancerimagingarchive.net/nbia-api/services/getTextSearch" -d "textValue=lung"

 Note that the returned JSON now includes the "hit" that was found by the Solr search engine.

Code Block[{ "subjectId":"Project-3076386612", "project":"Project", "id":1277952, "totalNumberOfStudies":1, "totalNumberOfSeries":1, "hit":"<em>seriesDesc</em>: <strong>LUNG</strong>", "studyIdentifiers":[{ "seriesIdentifiers":[1376256], "studyIdentifier":1310720 }] }]
v1/getUpdatedSeries?fromDate=28/03/2023


AttributeDICOM TagDescription

SeriesInstanceUID

0020, 000EHas been de-identified as part of submission process

StudyInstanceUID

0020, 000DHas been de-identified as part of submission process

Modality

0008, 0060Standard DICOM definition

ProtocolName

0018, 1030Standard DICOM definition. Has been inspected and cleaned of any PHI.

SeriesDate

0008, 0021Standard DICOM definition

SeriesDescription

0008, 103EStandard DICOM definition. Has been inspected and cleaned of any PHI.

BodyPartExamined

0018, 0015Entered on a per collection basis using relevant SNOMED terms

SeriesNumber

0020, 0011Standard DICOM definition

AnnotationsFlag

N/AIndicates if there are annotations for a collection

Collection

N/AA label used to name a set of images collected for a specific trial or other reason. Assigned during the process of curating the data.

PatientID

0010, 0020Has been de-identified as part of submission process.

Manufacturer

0008, 0070Standard DICOM definition

ManufacturerModelName

0008, 1090Standard DICOM definition

SoftwareVersions

0018, 1020Standard DICOM definition

ImageCount

N/ANumber of images in the specified series

DateReleased

N/AThe date that TCIA published the series