NIH OTT API
What is an API?
An Application-Programming Interface (API) is a set of programming instructions and standards for accessing a web-based software application or Web tool. An API is a software-to-software interface, not a user interface. With APIs, applications talk to each other without any user intervention.
NIH OTT has released its API to the public so that software developers can design products that leverage NIH data and access it real-time on their site.
What can one do with the API?
You can think of an API as a way for computers to talk to each other. It is not meant for human intervention or use. Typically, it is for a third party site to query the NIH OTT website and retreive for example, records that match a keyword or a set of records updated after a particular date. Please bear in mind that this API is specifically setup to allow retreival of available licensing opportunities.
What information can one retrive using the NIH OTT API?
The following queries can be sent to the API:
search_string=[test] Matches the string [test] against all abstract titles
type=[content-type] Use either 'technology' or 'technology_bundle'
title=[title] Returns a record with an exact title match
created_before=[YYYY-MM-DD] Inclusive. Returns records created before the input date
created_after=[YYYY-MM-DD] Inclusive. Returns records created after the input date
changed_before=[YYYY-MM-DD] Inclusive. Returns records updated before the input date
changed_after=[YYYY-MM-DD] Inclusive. Returns records updated after the input date
limit=[limit] The number of items to return in a single request
sort=[sort field] A field to sort results by, such as created, changed, index number, etc.
sort_order=[ASC|DESC] Choose whether to sort results ascending or descending
page=[page] The page number of results to return
fields=all Show all fields for a record.
fields=[field] The fields parameter can instead be an array of the fields you want returned.
Can you give an example of this?
Here is a simple business case: Suppose a website needs to get all information on all available licensing opportunities that have the word "mouse model" in the title. This can be achieved in two steps.
Step #1. A query string of https://ott.nih.gov/api/content?type=technology&search_string=mouse%20model will return a string similar to this:
...and so on.
The first "item" above (in blue) describes the number of records and the number of pages that match the query.
Step #2. At this point, the following query string will retreive details of record number 8382 (in red above):
will return a string similar to this:
...and so on.
Any third-party developer can use the above tools and examples to connect to the NIH OTT dataset and obtain information on any technology that is available for licensing. If you have any questions or concerns about this initiative, please contact Steven Ferguson, CLP, Special Advisor, NIH OTT.