Versions Compared

Key

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

openspecimen/rest/ng//collection-protocol-registrations?cpId={collection-protocol-Id}

or

openspecimen/rest/ng/collection-protocol-registrations?cpId={collectionProtocolId}&registrationDate={registraitonDate}&name={paritcipantName}&query={searchString}&ppid={participantProtocolId}&uid={participantUniqueIdentifier}&participantId={masterPatientIndex}&empi={masterPatientIndex}&dob={dateOfBirth}&specimen={specimenLabel}&startAt={startAt }&max={maxResults }&includeStats={true/false}&exactMatch={true/false}

Use this resource to get participant registration details for a given protocol. This API returns all the matching participant registration details based on the searchString,  if searchString not specified then it returns all the registrations for a given collection protocol.

Use HTTP GET method to call this API by passing the below request parameters.

 

Below are the attributes which need to be sent in the request body:

Parameter
Details
collectionProtocolId[mandatory]The collection protocol identifier for which the participant registrations to be searched.
searchStringThe value with which you want to search the participant registration. The given value will be matched with PPID, firstName, lastName
registraitonDateParticipant registration date
paritcipantNameThis parameter will be used to match on the basis of firstName and lastName of the participant
participantProtocolIdMatched with the protocol participant Id
participantUniqueIdentifierMatched with the unique identifier of the patient
masterPatientIndexMatched with Medical record number, participant unique identifier and master patient index
masterPatientIndexMatched with master patient index
dateOfBirthMatched with participants date of birth
specimenDetailsMatched with specimen label and barcode
startAt start index of the results
maxResults Maximum number of records to fetch. By default it will be 1000
includeStatsTo specify whether to include statistics like visits count, collected specimen or pending counts etc
exactMatchFlag to specify whether to perform exact match or not.

 

http[s]:<host>:<port>/openspecimen/rest/ng/collection-protocols

or

http[s]:<host>:<port>/openspecimen/rest/ng/collection-protocols?start={start}&max={maxResults}&searchString={searchString}&countReq={true/false}


Use this URL to get collection protocols in openSpecimen application.

Result:

The response of this request will contains the details of the collection protocols.

Below is the example of the get all collection protocols:

URLhttp://<host>:<port>/openspecimen/rest/ng/collection-protocol-registrations?cpId=1&ppid=LS11&includeStats=true
MethodGET
Requestapplication/json

Response

Code Block
languagejs
themeEclipse
linenumberstrue
[
  {   
    "participant":{
      "id":13,
      "firstName":"tim",
      "lastName":null,
      "empi":null,
      "uid":null
    }, 
    "cprId":13,
    "registrationDate":1444622400000,
    "ppid":"LS11",
    "cpShortTitle":"test protocol",
    "scgCount":1,
    "specimenCount":3
  }
]

 

 

Error Cases :

code
Applies to
Status Message
200All resourcesCollection protocols registration got successfully
401All requestsAuthorization failed, user doesn’t have authority
500All requestsInternal server error, encountered server error while performing operations