openspecimen/rest/ng/collection-protocols/{id}
or
openspecimen/rest/ng/collection-protocols/?title={title}
or
openspecimen/rest/ng/collection-protocols/shortTitle?query={shortTitlesearch string}
Use this resource to get collection protocol. This API returns the collection protocol present in the openSpecimen application of given id, title and short title.
Below are the attributes which need to be sent in the URL:
Parameter | Details |
---|---|
id | Collection protocol id to fetch the collection protocol |
title | Collection protocol title to fetch the collection protocol |
shortTitlequery | Collection protocol shortTitle to fetch the collection protocol |
http[s]:<host>:<port>/openspecimen/rest/ng/collection-protocols/{id}
or
http[s]:<host>:<port>/openspecimen/rest/ng/collection-protocols/title={title}
or
http[s]:<host>:<port>/openspecimen/rest/ng/collection-protocols/shortTitle={shortTitle}
Use this URL to get collection protocol by an id in openSpecimen application
Result:
The response of this request will contains the details of the collection protocol.
Below is the example of the get collection protocol:
URL |
or
or
|
Method | GET |
Request | application/json |
Response | { id: 1 title: "skinCancerStudy" shortTitle: "SCS_collection protocol" collection protocolType: "Parent" startDate: null endDate: "1995-10-01" activityStatus: "Active" labelFormat: null derivedLabelFormat: null aliquotLabelFormat: null ppIdFormat: " " } |
Error Cases :
code | Applies to | Status Message |
---|---|---|
200 | All resources | Collection protocol got successfully |
401 | All requests | Authorization failed, user doesn’t have authority |
500 | All requests | Internal server error, encountered server error while performing operations |