General
- All requests are
GET
requests unless otherwise stated. - All requests, except /linesummary/:centre/:colonyId, can be paginated using the query parameters
start
andresultsize
start
– offsetresultsize
– max number of results to retrieve- Both parameters need to be > 0 or are otherwise ignored
- By default, pagination is defaulted to offset 0 and resultsize 100000
Requests
/centre/zip?centre=:shortName
Returns a list of ZIP files in summary view
- Takes additional parameters as query string:
centre
– The centre short name, e.gTcp
updatedSinceDate
– The day when file has been crawled. The endpoint point will fetch all files with a date >= updatedSinceDate. The default value is null. If this value is passed unless resultsize is selected all the values would be returned. If its null default pagination would be 100
- Example: https://api.mousephenotype.org/tracker/centre/zip?centre=Kmpc&start=0&resultsize=50
/centre/zip/issues?centre=:shortName
Returns a list of ZIP files with failures/warnings in summary view for greater than or equal to given updatedSinceDate
of the file which is the date when file has been crawled( Pagination is not effective for this endpoint as required data is controlled by date)
- Takes additional parameters as query string:
centre
– The centre short name, e.gTcp
updatedSinceDate
– The day when file has been crawled. The endpoint point will fetch all files with a date >= updatedSinceDate. The default value is one month before current date .ignoreWarnings
– If set astrue
it will exclude zip files that only contain xml files with validation warnings.validationIssues
– If set astrue
will return the zip files that contain xml files with validation issues.xmlErrors
– If set astrue
will return the zip files that contain xml files with xml errors.zipErrors
– If set astrue
will return the zip files having zip errors.
- Filtering will be performed if any of the
validationIssues
,xmlErrors
,ignoreWarnings
orzipErrors
flags is set astrue
. If none of them is passed as an argument it will return everything.false
values will not effect the result. - Example: https://api.mousephenotype.org/tracker/centre/zip/issues?centre=Kmpc&updatedSinceDate=2019-10-01&ignoreWarnings=true
/centre/xml?centre=:shortName
Returns a list of XML files in summary view
- Takes additional parameters as query string:
centre
– The centre short name, e.gTcp
status
– A valid status as defined by /xml/meta/statusphase
– A valid phase as defined by /xml/meta/phase
- Example: https://api.mousephenotype.org/tracker/centre/xml?centre=Tcp&status=done&start=10&resultsize=50
/centre/xml/issues?centre=:shortName
Returns a list of XMLs with failures/warnings in summary view for greater than or equal to given updatedSinceDate
of the file which is the date when file has been crawled (Pagination is not effective for this endpoint as required data is controlled by date)
- Takes additional parameters as query string:
centre
– The centre short name, e.gTcp
updatedSinceDate
– The day when file has been crawled. The endpoint point will fetch all files with a date >= updatedSinceDate. The default value is one month before current date .ignoreWarnings
– If set astrue
it will exclude zip files that only contain xml files with validation warnings.validationIssues
– If set astrue
will return the zip files that contain xml files with validation issues.xmlErrors
– If set astrue
will return the zip files that contain xml files with xml errors.
- Filtering will be performed if any of the
validationIssues
,xmlErrors
orignoreWarnings
flags is set astrue
. If none of them is passed as an argument it will return everything.false
values will not effect the result. - Example: https://api.mousephenotype.org/tracker/centre/xml/issues?centre=Kmpc&updatedSinceDate=2019-10-01&ignoreWarnings=true
/xml/:idOrFilename
Returns all instances of an XMl file with the given filename or one result with the given id – :idOrFilename
– The id or filename of the XML file
- Takes additional parameters as query string:
detail
– eitherfull
orsummary
, default:full
- Example: https://api.mousephenotype.org/tracker/xml/784972
/zip/:zipIdOrFilename
Returns all XML files within the given ZIP file in summary view – :zipIdOrFilename
– The id or filename of a ZIP file
- Example: https://api.mousephenotype.org/tracker/zip/Kmpc.2019-06-21.1.impc.zip?validationIssues=true
/issues/zip/:zipIdOrFilename
Returns all XML files with failures and warnings within the given ZIP file in summary view – :zipIdOrFilename
– The id or filename of a ZIP file
- Takes additional parameters as query string:
ignoreWarnings
– If set astrue
it will exclude zip files that only contain xml files with validation warnings.validationIssues
– If set astrue
will return the zip files that contain xml files with validation issues.xmlErrors
– If set astrue
will return the zip files that contain xml files with xml errors.
- Filtering will be performed if any of the
validationIssues
,xmlErrors
orignoreWarnings
flags is set astrue
. If none of them is passed as an argument it will return everything.false
values will not effect the result. - Example: https://api.mousephenotype.org/tracker/issues/zip/Kmpc.2019-06-21.1.impc.zip?validationIssues=true
/zip/:zipIdOrFilename/:xmlIdOrFilename
Returns the contents of an XML file with the given id or filename – :zipIdOrFilename
– The id or filename of a ZIP file – :xmlIdOrFilename
– The id or filename of an XML file contained in the ZIP file
- Takes additional parameters as query string:
detail
– eitherfull
orsummary
, default:full
- Example: https://api.mousephenotype.org/tracker/zip/Tcp.2020-09-16.1.impc.zip/Tcp.2020-09-16.718.experiment.impc.xml
/linesummary/:centre/:colonyId
Returns all specimens and line procedures for a given colony for a specific centre
– :centre
– Phenotyping centre ILAR code – :colonyId
– The colony for which to retrieve data for
- Takes additional parameters as query string:
onlyActive
– True or false.onlyInvalid
– True or false.
- No filtering will be performed if both
onlyActive
andonlyInvalid
are used and are both set totrue
. - Example: https://api.mousephenotype.org/tracker/linesummary/Gmc/GSF-HEPD0550_6_G09-1-1?onlyActive=true
/trackerexperiment
/:id
trackerexperiment
/:idGetter for experiment procedures in the interface. Returns a single instance of the identified object.
– :id
– The identifier for the object, the unique id for the object to return
- Example
experimentprocedures
: https://api.mousephenotype.org/tracker/trackerexperiment
/255068
/trackerexperiment
/multiple
(POST)
trackerexperiment
/multipleReturns list of experimen procedures for multiple identifiers. Provide a list of IDs in JSON format – e.g. [ 2550682, 2550681, 2550680,] in the body of the call. With content type of the request as application/json. Note that there is a maximum of 10,000 IDs that can be submitted per request.
- Example : https://api.mousephenotype.org/tracker/trackerexperiment/multiple
Body: [2550682,2550681,2550680,2550679,2550678,2550677,2550676,2550675,2550674]
/trackerspecimen/:id
Getter for experiment procedures in the interface. Returns a single instance of the identified object.
– :id
– The identifier for the object, the unique id for the object to return
/trackerspecimen
/multiple
(POST)
/trackerspecimen
/multipleReturns list of experimen procedures for multiple identifiers. Provide a list of IDs in JSON format – e.g. [ 2550682, 2550681, 2550680,] in the body of the call. With content type of the request as application/json. Note that there is a maximum of 10,000 IDs that can be submitted per request.
- Example : https://api.mousephenotype.org/tracker/trackerspecimen/multiple
Body: [2550682,2550681,2550680,2550679,2550678,2550677,2550676,2550675,2550674]
/item/:itemType/:id
Getter for procedures in the interface. Returns a single instance of the identified object.
– :itemType
– An object type from: experimentprocedures, specimens and lineprocedures. – :id
– The identifier for the object, the unique id for the object to return
- Example
experimentprocedures
: https://api.mousephenotype.org/tracker/item/experimentprocedures/2550682 - Example
specimens
: https://api.mousephenotype.org/tracker/item/specimens/4016251 - Example
lineprocedures
: https://api.mousephenotype.org/tracker/item/lineprocedures/146318
/item/:itemType/multiple
(POST)
Returns list of procedures for multiple identifiers. Provide the proceduretype in the URL, and a list of IDs in JSON format – e.g. [ 2550682, 2550681, 2550680,] in the body of the call. With content type of the request as application/json. Note that there is a maximum of 10,000 IDs that can be submitted per request.
:itemType
– An object type from: experimentprocedures, specimens and lineprocedures.- Example
experimentprocedures
: https://api.mousephenotype.org/tracker/item/experimentprocedures/multiple
Body: [2550682,2550681,2550680,2550679,2550678,2550677,2550676,2550675,2550674]
/search/:itemType
Returns data for given :itemType
and given parameters.
For pagination both :start
and :resultsize
parameters should be passed.
:itemType
– An object type from: experimentprocedures, specimens and lineprocedures.- Takes additional parameters as query string:
:showdetails
– if passed astrue
will return the object’s content in place of identifier. However, this enforces the use of pagination, as outlined at the top of this document. If the pagination fields are omitted default values of0
for:start
and100
for:resultsize
are used.
lineprocedures
:
- Takes parameters as query string:
:centre
– The centre short name, e.g Tcp:colonyId
– The colony id for which to retrieve line procedures for:createdDateFrom
– Date when the file crawled.:createdDateTo
– Date when the file crawled.:status
– A valid status as defined by /pcv/meta/status
specimens
:
- Takes parameters as query string:
centre
– The centre short name, e.g Tcp (Mandatory)
- Additional parameters are :
createdDateFrom
– Date when the file crawled.createdDateTo
– Date when the file crawled.status
– A valid status as defined by /pcv/meta/statusspecimenId
– The specimen for which to retrieve data forpipeline
– The pipeline mapped with procedure
experimentprocedures
:
- Takes parameters as query string:
centre
– The centre short name, e.g Tcp (Mandatory)
- Additional parameters are :
createdDateFrom
– Date when the file crawled.createdDateTo
– Date when the file crawled.status
– A valid status as defined by /pcv/meta/statusspecimenId
– The specimen for which to retrieve data forpipeline
– The pipeline mapped with the procedureprocedure
– The procedure key
Note: createdDateFrom , createdDateTo
and start, resultsize
should be passed together otherwise they will not be added as criteria
- Example
experimentprocedures
: https://api.mousephenotype.org/tracker/search/experimentprocedures?centre=Ucd&specimenId=BL1601-407&status=active - https://api.mousephenotype.org/tracker/search/experimentprocedures?centre=Ucd&specimenId=BL1601-407&status=active&showdetails=true
- Example
specimens
: - https://api.mousephenotype.org/tracker/search/specimens?centre=Ucd&createdDateFrom=2020-07-09&createdDateTo=2020-08-15&start=0&resultsize=30
- https://api.mousephenotype.org/tracker/search/specimens?centre=Ucd&createdDateFrom=2020-07-09&createdDateTo=2020-08-15&start=0&resultsize=30&showdetails=true
- Example
lineprocedures
: - https://api.mousephenotype.org/tracker/search/lineprocedures?colonyId=CR10764
- https://api.mousephenotype.org/tracker/search/lineprocedures?colonyId=CR10764&showdetails=true
/activeanimal/:colony/:procedure
result to show which animals in provided colony have an active experiment or status code for provided procedure
– :colony
– The colony name- :
– The identifier for the object, the unique id for the object to returnprocedure
/xml/meta/status
Returns a lookup of the xml statuses:
Status |
pending |
running |
done |
cancelled |
failed |
/pcv/meta/status
Returns a lookup of the pcv statuses:
Status |
failed |
valid |
active |
pending |
duplicate |
status_coded |
failed_overviews |
/xml/meta/phase
Returns a lookup of the xml phases:
Phase |
download |
zip_name |
zip_md5 |
unzip |
xml_name |
xsd |
upload |
data |
context |
overview |
qc |
Data structures
Datatype : logs[]
- Example Link: http://api.mousephenotype.org/tracker/zip/Ucd.2019-02-13.2.impc.zip/Ucd.2019-02-13.1.specimen.impc.xml
- Example Structure :
"logs": [
{
"line": 3,
"column": 27,
"message": "cvc-complex-type.2.4.b: The content of element 'centre' is not complete. One of '{\"https://www.mousephenotype.org/dcc/exportlibrary/datastructure/core/specimen\":mouse, \"https://www.mousephenotype.org/dcc/exportlibrary/datastructure/core/specimen\":embryo}' is expected.",
"fatality": "Error"
}
]
Datatype : experimentProcedures[]
- Example Link: https://api.mousephenotype.org/tracker/xml/784972
- Example Structure :
"experimentProcedures": [
18159310,
18159309,
18159308,
18159307,
18159306,
18159305,
18159304
]
Datatype : specimens[]
- Example Link: http://api.mousephenotype.org/tracker/zip/Ucd.2019-04-01.2.impc.zip/Ucd.2019-04-01.1.specimen.impc.xml
- Example Structure :
"specimens": [
2428822,
2428821,
2428820,
2428819,
2428818,
2428817,
2428816
]
Datatype : lineProcedures[]
- Example Link: http://api.mousephenotype.org/tracker/zip/BCM.2019-05-14.2739.impc.zip/BCM.2019-05-14.2739.experiment.impc.xml
- Example Structure :
"lineProcedures": [
119679,
119678,
119677,
119676,
119675,
119674,
119673,
119672,
119671,
119670,
119669,
119668,
119667
]
Datatype : validationLogs[]
- Example Link: No real time case present
- Example Structure :
"validationLogs": [
{
"message": "'Message for failure",
"parameterType": "Parameter Type",
"parameterKey": "Parameter Key",
"fatality": "Warning/Error"
},
]
Endpoint :/trackerexperiment/:id
- Example Link: https://api.mousephenotype.org/tracker/
trackerexperiment
/2550682 - Example Structure :
{
"id": 2550682,
"xmlId": 265805,
"experimentName": "141357065",
"pipeline": "MGP_001",
"procedure": "IMPC_BWT_001",
"specimen": "1340291",
"phenotypingCentre": "WTSI",
"sequenceId": "10",
"statusId": 1,
"status": "valid",
"ageAtExperiment": "15.86 weeks",
"created": 1442940122,
"createdDate": "2015-09-22T16:42:02",
"logs": [],
"dateOfExperiment": "2013-03-13T00:00:00"
}
Endpoint : /item/:itemType/:id
itemType – experimentprocedures
- Example Link: https://api.mousephenotype.org/tracker/item/experimentprocedures/2550682
- Example Structure :
{
"id": 4016251,
"specimen": "CR10639-191",
"isBaseline": true,
"zygosity": "WILD_TYPE",
"sex": "MALE",
"type": "mouse",
"phenotypingCentre": "UCD",
"pipeline": "UCD_001",
"colony": "CR10639",
"dateOfBirth": "2020-07-06T23:00:00",
"xmlId": 777058,
"statusId": 2,
"status": "active",
"created": 1597435098000,
"createdDate": "2020-08-14T19:58:18",
"strain": "C57BL/6NCrl",
"project": "DTCC",
"logs": []
}
Endpoint : /trackerspecimen/:id
- Example Link: https://api.mousephenotype.org/tracker/trackerspecimen/4016251
- Example Structure :
[
{
"id": 18085293,
"xmlId": 784232,
"experimentName": "XRY_BL1601-407_2013-02-15",
"pipeline": "UCD_001",
"procedure": "IMPC_XRY_001",
"specimen": "BL1601-407",
"phenotypingCentre": "UCD",
"sequenceId": null,
"statusId": 2,
"status": "active",
"ageAtExperiment": "14.14 weeks",
"created": 1599938892,
"createdDate": "2020-09-12T20:28:12",
"logs": [],
"dateOfExperiment": "2013-02-15T00:00:00"
},
{
"id": 18017521,
"xmlId": 782865,
"experimentName": "EYE_BL1601-407_2013-02-22",
"pipeline": "UCD_001",
"procedure": "IMPC_EYE_002",
"specimen": "BL1601-407",
"phenotypingCentre": "UCD",
"sequenceId": null,
"statusId": 2,
"status": "active",
"ageAtExperiment": "15.14 weeks",
"created": 1599736394,
"createdDate": "2020-09-10T12:13:14",
"logs": [],
"dateOfExperiment": "2013-02-22T00:00:00"
}
]
Endpoint : /item/:itemType/:id
itemType – specimens
- Example Link: https://api.mousephenotype.org/tracker/item/specimens/4016251
- Example Structure :
{
"id": 4016251,
"specimen": "CR10639-191",
"isBaseline": true,
"zygosity": "WILD_TYPE",
"sex": "MALE",
"type": "mouse",
"phenotypingCentre": "UCD",
"pipeline": "UCD_001",
"colony": "CR10639",
"dateOfBirth": "2020-07-06T23:00:00",
"xmlId": 777058,
"statusId": 2,
"status": "active",
"created": 1597435098000,
"createdDate": "2020-08-14T19:58:18",
"strain": "C57BL/6NCrl",
"project": "DTCC",
"logs": []
}
Endpoint : /activeanimal/:colony/:procedure:
- Example Link: https://api.mousephenotype.org/tracker/activeanimal/TCPR1500_AEKU/IMPC_OWT_001
- Example Structure :
[
{
"id": 598832760,
"specimenId": "AEKU_92_910592",
"gender": "MALE",
"status": "active",
"zygosity": "HOMOZYGOUS"
},
{
"id": 598832764,
"specimenId": "AEKU_98_910698",
"gender": "FEMALE",
"status": "active",
"zygosity": "HOMOZYGOUS"
}
]
---