Leave a comment at the end of this page or email contact@krishagni.com
Delete Specimen
DELETE openspecimen/rest/ng/specimens/{specimen_id}
Use this resource to delete an existing specimen in the openspecimen application. Use HTTP DELETE method to call this API by passing the below details:
Below are the parameters which need to be sent with the request:
Parameter | Details |
---|---|
specimen_id | Identifier of the specimen to whom you want to delete from openspecimen |
Result:
The response of this request will contains the identifier of the deleted specimen and the success message.
Below is the example of the delete specimen:
URL | openspecimen/rest/ng/specimens/16 |
Method | DELETE |
content-type | application/json |
Response | { "id": 16, "cpId": 1, "cprId": 1, "eventId": null, "visitId": 1, "visitName": "first visit", "cpShortTitle": "blood", "reqId": null, "sortOrder": null, "label": "b9_1449500581277", "barcode": null, "type": "Whole Blood", "specimenClass": "Fluid", "lineage": "Aliquot", "anatomicSite": "Autonomic nervous system, NOS", "laterality": "Not Applicable", "status": "Collected", "reqLabel": null, "pathology": "Malignant, Pre-Invasive", "initialQty": 20, "availableQty": 20, "available": true, "concentration": 10, "parentId": 1, "parentLabel": "blood1", "storageLocation": { "id": -1, "name": null, "positionX": null, "positionY": null }, "storageType": null, "collectionContainer": null, "activityStatus": "Disabled", "createdOn": 1449500400000, "code": null, "distributed": null, "collectionEvent": null, "receivedEvent": null, "labelFmt": null, "biohazards": [], "comments": null, "closeAfterChildrenCreation": null, "children": [], "pooledSpecimenId": null, "pooledSpecimenLabel": null, "specimensPool": null, "closeParent": null, "poolSpecimen": null, "extensionDetail": null } |
Error Cases :
code | Applies to | Status Message |
---|---|---|
200 | All resources | Specimen has been deleted successfully |
400 | All requests | If any active children found for this Specimen |
401 | All requests | Authorization failed, User doesn’t have privileges to delete this specimen |
404 | All requests | Specimen not found, Specimen with given identifier is not present in the system |
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