Versions Compared

Key

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

http[data-colorid=wv0oro8av7]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=wv0oro8av7]{color:#ffac31}[data-colorid=ux6p1szj7g]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=ux6p1szj7g]{color:#ffac31}[data-colorid=yuxvsupvy1]{color:#4488aa} html[data-color-mode=dark] [data-colorid=yuxvsupvy1]{color:#5599bb}[data-colorid=xhaml9rtxp]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=xhaml9rtxp]{color:#ffac31}[data-colorid=snxvnvep6j]{color:#4488aa} html[data-color-mode=dark] [data-colorid=snxvnvep6j]{color:#5599bb}[data-colorid=e9gsh69wrd]{color:#4488aa} html[data-color-mode=dark] [data-colorid=e9gsh69wrd]{color:#5599bb}[data-colorid=wpiwre5oqd]{color:#770088} html[data-color-mode=dark] [data-colorid=wpiwre5oqd]{color:#ee77ff}[data-colorid=fuuewf1gt3]{color:#4488aa} html[data-color-mode=dark] [data-colorid=fuuewf1gt3]{color:#5599bb}[data-colorid=fwamnevdda]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=fwamnevdda]{color:#ffac31}[data-colorid=xq0cikkdld]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=xq0cikkdld]{color:#ffac31}[data-colorid=igj03iaox4]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=igj03iaox4]{color:#ffac31}[data-colorid=araytvacou]{color:#4488aa} html[data-color-mode=dark] [data-colorid=araytvacou]{color:#5599bb}[data-colorid=kdqnn9la87]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=kdqnn9la87]{color:#ffac31}[data-colorid=ai85hbduok]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=ai85hbduok]{color:#ffac31}[data-colorid=qzwc7wlam6]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=qzwc7wlam6]{color:#ffac31}[data-colorid=bajtz0cpg0]{color:#4488aa} html[data-color-mode=dark] [data-colorid=bajtz0cpg0]{color:#5599bb}[data-colorid=r87vqpmbtf]{color:#4488aa} html[data-color-mode=dark] [data-colorid=r87vqpmbtf]{color:#5599bb}[data-colorid=n39a7y8pzw]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=n39a7y8pzw]{color:#ffac31}[data-colorid=p5r3csbwxo]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=p5r3csbwxo]{color:#ffac31}[data-colorid=otx1zmm5lt]{color:#4488aa} html[data-color-mode=dark] [data-colorid=otx1zmm5lt]{color:#5599bb}[data-colorid=d37fl8mqnj]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=d37fl8mqnj]{color:#ffac31}[data-colorid=dj9njegu30]{color:#4488aa} html[data-color-mode=dark] [data-colorid=dj9njegu30]{color:#5599bb}[data-colorid=q8rzjye6ur]{color:#4488aa} html[data-color-mode=dark] [data-colorid=q8rzjye6ur]{color:#5599bb}[data-colorid=vf4jsgmx6q]{color:#4488aa} html[data-color-mode=dark] [data-colorid=vf4jsgmx6q]{color:#5599bb}[data-colorid=amgg92vwrs]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=amgg92vwrs]{color:#ffac31}[data-colorid=zx9voohlfa]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=zx9voohlfa]{color:#ffac31}[data-colorid=qxlutn7uqe]{color:#4488aa} html[data-color-mode=dark] [data-colorid=qxlutn7uqe]{color:#5599bb}[data-colorid=epkynyfl9s]{color:#ce7b00} html[data-color-mode=dark] [data-colorid=epkynyfl9s]{color:#ffac31}catissuecores]:<host>:<port>/openspecimen/rest/ng/sites

Use this resource to create new Site site in the caTissue applicationopenSpecimen application. Use HTTP POST method to call this API by passing the below details in JSONformatJSON format.

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

Parameter
Details
nameName of the physical location.coordinatorCollection
instituteNameName of the institute which site is belongs to
coordinators

Collection of user info object. UserInfo User Info contains Login Name and Domain Name

type

Function of the site. It could be collection, storing, experimentation or it could be unspecified

{ Collection Sitecollection site,Repositoryrepository,Laboratorylaboratory,Not Specified not specified }

activityStatus

Defines the status of a Site site record

{active, closed, pending, disabled}

streetName of street to which the site belongs.
cityName of city to which the site belongs.
state [optional]Name of the state to which the site belongs 
countryName of the country to which the site belongs
zipCodeZip Code of location
faxNumber [optional]Fax number of the site
phoneNumber [optional]Phone number of the site
addressAddress of the site

 

http[s]:<host>:<port>/catissuecoreopenspecimen/rest/ng/sites

Use this URL to add site in caTissue openSpecimen application. 

Result:

The response of this request will contains the details of the created site.

...

 

{

name"DD1"
coordinatorCollection
[{ 
      loginName"admin@admin.com"
domainName"catissue"
}]
id6
type"sitesType"
emailAddress:"admin@admin.com"
activityStatus"Active"
emailAddressnull
street"SB Road"
city"Pune412312"
state"MH"
country"India"
zipCode"412312"
faxNumber"123321"
phoneNumber"213434324"
URLhttp://<host>:<port>/catissuecoreopenspecimen/rest/ng/sites
MethodPOST
Requestapplication/json
json{

"name" : "Pune",

"coordinatorCollection" : [ { "loginName" : "admin@admin.com", "domainName" :"catissue"}],

"type" : "Collection Site",

"emailAddress" : "admin@admin.com",

"activityStatus" : "Active",

"street" : "SB Road",

"city" : "Pune",

"state" : "Maharashtra",

"country" : "India" ,

"zipCode" : "412312",

"faxNumber" : "123321",

"phoneNumber" : "213434324"

}

Response

Code Block
languagejs
themeEclipse
linenumberstrue
{
    "name": "Arkansas Hospital",
    "instituteName": "A1 - For Demo Users",
    "type": "Collection Site",
    "activityStatus": "Active",
    "coordinators":
    [
        {
            "loginName": "aalfortish",
            "domain": "openspecimen"
        },
        {
            "loginName": "vinod",
            "domain": "openspecimen"
        }
    ],
    "address": "Arkansas"
}

Response

Code Block
languagejs
themeEclipse
linenumberstrue
{
    "id": 4,
    "name": "Arkansas Hospital",
    "instituteName": "A1 - For Demo Users",
    "type": "Collection Site",
    "activityStatus": "Active",
    "cpCount": 0,
    "coordinators":
    [
        {
            "id": 107,
            "firstName": "Alexandra",
            "lastName": "Alfortish",
            "loginName": "aalfortish",
            "domain": "openspecimen",
            "emailAddress": "aalfortish@lcrc.info",
            "admin": false,
            "cpCount": 0,
            "creationDate": 1438021800000
        },
        {
            "id": 14,
            "firstName": "Vinod",
            "lastName": "Gaikwad",
            "loginName": "vinod",
            "domain": "openspecimen",
            "emailAddress": "vinod.gaikwad@domain.com",
            "admin": false,
            "cpCount": 0,
            "creationDate": null
        }
    ],
    "address": "Arkansas",
}

 

Error Cases :

code
Applies to
Status Message
200All resourcesSite has been created successfully
400All requestsInvalid parameters, e.g  duplicate Site Name, blank Site Name, blank Site Type etc
401All requestsAuthorization failed, User user doesn't have Authority
500All requestsInternal server error, Encountered server error while performing operations