Leave a comment at the end of this page or email contact@krishagni.com
Update Registration
Use this resource to update an existing registration and associated participant details in the OpenSpecimen application. Use HTTP PUT method to call this API by passing the below details in JSON format.
Below are the attributes which need to be sent in the request body:
Parameter | Details | ||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
participant | Details of the participant which is being registered. If the participant already exists then specify the identifier of that participant otherwise specify the complete details, below are the attributes of the participant:
| ||||||||||||||||||||||||||||||||||
cpId | Identifier of the protocol to which the participant is being registered. | ||||||||||||||||||||||||||||||||||
cpTitle | Title of the protocol to which the participant is being registered. | ||||||||||||||||||||||||||||||||||
cpShortTitle | ShortTitle of the protocol to which the participant is being registered. | ||||||||||||||||||||||||||||||||||
ppid [optional if autogeneration set at protocol level] | Protocol Participant Identifier, this is the identifier to uniquely identify the participant with in a protocol. Note: If PPID is set to auto-generated at protocol level, then please leave this attribute blank. | ||||||||||||||||||||||||||||||||||
registrationDate | Date of the registration of participant | ||||||||||||||||||||||||||||||||||
externalSubjectId | External subject id of the participant (optional) |
Note: For the collection protocol attributes, any one is required from the three: cpId/cpTitle/cpShortTitle.
http[s]:<host>:<port>/openspecimen/rest/ng/collection-protocol-registrations/{registration-id}
Use this URL to add participant in OpenSpecimen application.
Result:
The response of this request will contains the details of the registered participant.
Below is the example of the register participant:
URL | openspecimen/rest/ng/collection-protocol-registrations/1 |
Content Type | application/json |
Method | PUT |
json | { "participant":{ "id":2 }, "id":1 "cpId":3, "ppid":"ASCI123", "activityStatus":"Active", "registrationDate":"2014-04-21", "externalSubjectId": "TEST_001" } |
Response | { "id":1, "participant":{ "id":2 }, "cpId":3, "ppid":"ASCI123", "activityStatus":"Active", "registrationDate":"1398105000000", "externalSubjectId": "TEST_001" } |
Error Cases :
code | Applies to | Status Message |
---|---|---|
200 | All resources | Registered updated successfully |
400 | All requests | Invalid parameters, e.g duplicate UID, duplicate PPID etc |
401 | All requests | Authorization failed, User doesn’t have Authority to register Participant for the given collection protocol |
404 | All requets | Requested registration not found |
500 | All requests | Internal server error, Encountered server error while performing operations |
Leave a comment at the end of this page or email contact@krishagni.com