NIH | National Cancer Institute | NCI Wiki  

Error rendering macro 'rw-search'

null

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 27 Next »

Links

Overview

Using the API, developers can allow an application to connect to caDSR and search the database. The API is available on the download center.

The caDSR HTTP API (XML-HTTP API) and CDE Browser provide access to, and a means of linking to, caDSR metadata through a standard internet browser.

caDSR HTTP API results are displayed in XML format and can be displayed in an internet browser or by means of an XSLT stylesheet. The caDSR 4.0 Technical Guide describes the caDSR XML-HTTP API and provides a catalog of the caDSR operations and search criteria.

A few simple examples of caDSR operations are provided below. The attached MS Word documents for the examples show sample results and the "http" statements used to produce the results, and provide information about how to interpret the results.

Examples

Example 1

Find a Data Element where Public Id = 2178693 and Version=2.1 and display the basic metadata attributes.

Either the CDE Browser or the caDSR HTTP API can be used to satisfy this query and results from both are shown below.

Example 1 Results Displayed in the CDE Browser

This method can be used to retrieve Data Elements only when you know both the Public ID and Version number.  (If you have trouble with the following link in Firefox, cut and paste it into IE.)

https://cdebrowser.nci.nih.gov/CDEBrowser/search?dataElementDetails=9/&cdeId=2178693&version=2.1&PageId=DataElementsGroup&queryDE=yes&FirstTimer=yes

Or alternatively

http://freestyle.nci.nih.gov/freestyle/do/cdebrowser?publicId=2178693&version=2.1

Sample CDE Browser Output from Example 1

Example 1 Results Displayed in XML

The URL for the results from the caDSR 4.0 HTTP API is:

http://cadsrapi.nci.nih.gov/cadsrapi40/GetXML?query=DataElement[@publicId=2178693][@version=2.1]

Example 2

Find a Data Element with Public Id = 2178693, display the basic metadata attributes, version is not known.

Since the version is not known, this query can only be handled via a caDSR HTTP API query.

The URL for the results from the caDSR 4.0 HTTP API is:

http://cadsrapi.nci.nih.gov/cadsrapi40/GetXML?query=DataElement[publicId=2178693]

Sample caDSR HTTP API XML Output from Example 2

Example 3

Find a Data Element with Public Id = 2178693, display all the metadata associated with the Data Element's related components, not just the basic attributes.

This is handled in the caDSR HTTP API using a parameter that produces expanded ("heavy") XML.

The URL for the results from the caDSR 4.0 HTTP API is:

http://cadsrapi.nci.nih.gov/cadsrapi40/GetXML?query=DataElement&DataElement[@publicId=2178693]&returnHeavyXML=true

Sample caDSR HTTP API XML Output from Example 3 with "Heavy" XML

Example 4

Find all the Data Elements associated with the Data Element Concept with Public Id = 2178546, display the basic metadata of the Data Element Concept and its Data Elements.

The URL for the results from the caDSR 4.0 HTTP API is:

http://cadsrapi.nci.nih.gov/cadsrapi40/GetXML?query=DataElement&DataElementConcept[@publicId=2178546]

Example 5

Find only Data Elements associated with VERSION 2.1 of Data Element Concept with Public Id = 2178546.

The URL for the results from the caDSR 4.0 HTTP API is:

http://cadsrapi.nci.nih.gov/cadsrapi40/GetXML?query=DataElement&DataElementConcept[@publicId=2178546][@version=2.1]

Sample caDSR HTTP API XML Output from Example 4 and 5

Example 6

Find a Form where Public Id = 2392775 and Version=1.0 and display the basic metadata attributes.

Either the Form Builder or the caDSR HTTP API can be used to satisfy this query and results from both are shown below.

Example 1 Results Displayed in the Form Builder

This method can be used to retrieve Forms only when you know both the Public ID and Version number.  (If you have trouble with the following link in Firefox, cut and paste it into IE.)

https://formbuilder.nci.nih.gov/FormBuilder/formDetailsAction.do?method=getFormDetails&formIdSeq=FF04F699-FE6A-56AA-E034-0003BA3F9857

Sample Form builder Output from Example 1

  • No labels