Skip Headers
Oracle® Health Sciences ClearTrial Cloud Service Web Services API User Guide
Release 5.1

Part Number E39879-02
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Feedback page
Contact Us

Go to previous page
Previous
View PDF

9 Track API

The ClearTrial Track Web Services API is a bi-directional API that permits reading and writing of data in and out of the ClearTrial Track application.

The format for Track URLs is: /cleartrial-ws/actuals/{baselinePlanId}/{resourceName}

Where the {baselinePlanId} is the ID of the plan that was chosen as the baseline for the study and {resourceName} is one of the supported Track resources as described in Chapter 7, Plan Resources API.

For example, to obtain ClearTrial Track data and update it, use the Unix command line tool curl:

curl --user myLogin:myPassword --header"customerCode: myCustomerCode" --header"Accept: application/json" --get https://api.cleartrial.com/cleartrial-ws/actuals/10802/sites

To enter or update Track data for the resource in the previous example, assuming that the data is present in a file called postContent, issue the following command:

cat postContent | curl --user myLogin:myPassword --header"customerCode: myCustomerCode" --header"Content-Type: application/json" --post302 https://api.cleartrial.com/cleartrial-ws/actuals/10802/sites 

To use an XML format, use the headers Accept: application/xml and ContentType: application/xml in the GET and POST requests, respectively. Upon a successful POST, the updated resource representation is echoed back to the ClearTrial Track Web Services API user. The general format of the interaction with the Track API is to GET the current state of the resource, update the representation with the actuals, and POST the updated representation back to the server.

Stale Data Resolution

As you use the ClearTrial Track API to obtain and update track data for a particular resource, the GET method returns may become obsolete or stale because another user has updated the track data for the same resource through the web interface.

If this happens, the ClearTrial Track API rejects the POST request and returns an HTTP Conflict 409 error code with an appropriate error message.

The server detects this situation because every POST request echoes the lockToken element that was sent to it in the preceding GET request for the resource. If the lockToken is missing, or if there is a mismatch between what was returned in the GET and what is being sent in the POST, the update fails and the server generates a Conflict 409 error code.

To proceed with the update, issue a fresh GET and obtain a new lockToken to get the latest view of the track data that you can update as needed.

Data Validation

The ClearTrial Track API performs data validation of all update requests. For each of the numerous validations, the ClearTrial Track API returns an error message detailing the errors. The categories of error messages include:

  • Field cannot be empty

  • Value of the field has to be in a particular range

  • Date is invalid

Sites Track Data

Gets and posts data pertaining to the number of sites completed in each location per week.

Method: GET/POST

URL: /cleartrial-ws/actuals/{baselinePlanId}/sites

Sample output/input:

{
 "actualSites": {
   "lockToken": 1304370420148,
   "planId": 10802,
   "location": [
      {
       "locationId": 100,
       "locationName":"USA",
       "periods": [
          {
             "date":"01-Apr-2010",
             "plannedValue":3,
             "actualValue": 0
            },
            {
              …
            },
            {
            … 
          },
        ]
      },
      {
       "locationId": 123,
       "locationName":"Japan",
         …
      }
      …
    ],
   "url":"/cleartrial-ws/actuals/10802/sites"
  }
}

Subjects Track Data

Gets and posts data pertaining to the number of subjects enrolled in each location per week.

Method: GET/POST

URL: /cleartrial-ws/actuals/{baselinePlanId}/subjects

Sample output/input:

{
 "actualSubjects": {
   "lockToken": 1304370420148,
   "planId": 10802,
   "location": [
      {
       "locationId": 100,
       "locationName":"USA",
       "periods": [
             {
             "date":"01-Apr-2010",
             "plannedValue":3,
             "actualValue": 0
             },
             {
              …
            },
            {
            …  
          }
        ]
      },
      {
       "locationId": 123,
       "locationName":"Japan",
         …
      }
      …
    ],
   "url":"/cleartrial-ws/actuals/10802/subjects"
  }
}

Monitoring Track Data

Gets and posts data pertaining to the number of CRF pages completed in each location per week.

Method: GET/POST

URL: /cleartrial-ws/actuals/{baselinePlanId}/crfs

Sample output/input:

{
 "actualCrfs": {
   "lockToken": 1304370420148,
   "planId": 10802,
   "location": [
      {
       "locationId": 100,
       "locationName":"USA",
       "periods": [
          {
             "date":"01-Apr-2010",
             "plannedValue":3,
             "actualValue": 0
            },
            {
              …
            },
            {
            …
          }
        ]
      },
      {
       "locationId": 123,
       "locationName":"Japan",
         …
      }
      …
    ],
   "url":"/cleartrial-ws/actuals/10802/crfs"
  }

Units Track Data

Gets and posts data pertaining to the units in Track.

Method: GET/POST

URL: /cleartrial-ws/actuals/{baselinePlanId}/units

Sample output/input:

{
  "actualUnits": {
    "lockToken": 1370450129065,
    "planId": 47323,
    "serviceProvider": [
      {
        "id": 10104,
        "name": "Cleartrial Operations",
        "majorTask": [
          {
            "id": 2,
            "name": "Project Initiated",
            "isTrackedAsPercentage": true,
            "location": [
              {
          "locationId": 0,
          "locationName": "All Locations",
          "periods": [
            {
            "startDate": "01-Oct-2012",
            "endDate": "31-Oct-2012",
             "plannedValue": 0.14285714285714293,
             "actualValue": null
               },
                       {
                ...
                },
                 {
                "id": 32,
                "name": "Study Setup",
                "isTrackedAsPercentage": true,
                 "location": [
                   {
                    "locationId": 0,
                    "locationName": "All Locations",
                     "periods": [
                       {
                     "startDate": "01-Oct-2012",
                     "endDate": "31-Oct-2012",
                     "plannedValue": 0.14285714285714293,
                      "actualValue": null
                    },
                    {
                     ...
                   },
                   {
                    "id": 31,
                    "name": "Study Setup Per-Location",
                    "isTrackedAsPercentage": true,
                    "location": [
                  {
                   "locationId": 157,
                   "locationName": "Australia",
                   "periods": [
                  {
                "startDate": "01-Oct-2012",
                "endDate": "31-Oct-2012",
                "plannedValue": 0.1333333333333333,
                "actualValue": null
                },
               {
               ...
              },
            {
            "id": 3,
            "name": "A Written Protocol",
            "isTrackedAsPercentage": true,
            "location": [
              {
                "locationId": 0,
                "locationName": "All Locations",
                "periods": [
                  {
                    "startDate": "01-Oct-2012",
                    "endDate": "31-Oct-2012",
                    "plannedValue": 0.9333333333333332,
                    "actualValue": null
                  },
                  {
                    "startDate": "01-Nov-2012",
                    "endDate": "30-Nov-2012",
                    "plannedValue": 0.06666666666666667,
                    "actualValue": null
                  }
                ]
              }
            ]
          },
          {
            "id": 4,
            "name": "Unique CRF Page Developed",
            "isTrackedAsPercentage": true,
            "location": [
              {
                "locationId": 0,
                "locationName": "All Locations"
              }
            ]
          },
          {
            "id": 5,
            "name": "CRF Book Printed",
            "isTrackedAsPercentage": false,
            "location": [
              {
                "locationId": 0,
                "locationName": "All Locations"
              }
            ]
          },
          {
            "id": 61,
            "name": "Meetings - Kickoff",
            "isTrackedAsPercentage": false,
            "location": [
              {
                "locationId": 0,
                "locationName": "All Locations",
                "periods": [
                  {
                    "startDate": "01-Oct-2012",
                    "endDate": "31-Oct-2012",
                    "plannedValue": 1.0,
                    "actualValue": null
                  }
                ]
              }
            ]
          },
          {
            "id": 50,
            "name": "Meetings - Investigator",
            "isTrackedAsPercentage": false,
            "location": [
              {
                "locationId": 0,
                "locationName": "All Locations",
                "periods": [
                  {
                    "startDate": "01-Apr-2013",
                    "endDate": "30-Apr-2013",
                    "plannedValue": 1.0,
                    "actualValue": null
                  }
                ]
              }
            ]
          },
          {
            "id": 33,
            "name": "Meetings - Face to Face",
            "isTrackedAsPercentage": false,
            "location": [
              {
                "locationId": 0,
                "locationName": "All Locations",
                "periods": [
                  {
                    "startDate": "01-Apr-2013",
                    "endDate": "30-Apr-2013",
                    "plannedValue": 1.0,
                    "actualValue": null
                  }
                ]
              }
            ]
          },
          {
            "id": 62,
            "name": "Meetings - Teleconference",
            "isTrackedAsPercentage": false,
            "location": [
              {
                "locationId": 0,
                "locationName": "All Locations",
                "periods": [
                  {
                    "startDate": "01-Oct-2012",
                    "endDate": "31-Oct-2012",
                    "plannedValue": 4.0,
                    "actualValue": null
                  },
                  {
                   ...
                  }

Fees Track Data

Gets and posts data pertaining to the fees in Track.

Method: GET/POST

URL: /cleartrial-ws/actuals/{baselinePlanId}/fees

Sample output/input:

{
  "actualFees": {
    "lockToken": 1370451444843,
    "planId": 47323,
    "serviceProvider": [
      {
        "id": 10104,
        "name": "Cleartrial Operations",
        "trackingLevel": "Globally",
        "majorTask": [
          {
            "id": 0,
            "name": "All Major Tasks",
            "location": [
              {
                "locationId": 0,
                "locationName": "All Locations",
                "periods": [
                  {
                    "startDate": "01-Oct-2012",
                    "endDate": "31-Oct-2012",
                    "plannedValue": 20501.20641137218,
                    "actualValue": null
                  },
                  {
                    "startDate": "01-Nov-2012",
                    "endDate": "30-Nov-2012",
                    "plannedValue": 14306.048742060317,
                    "actualValue": null
                  },
                  {
                     ...
                  },
                  {
                    "startDate": "01-Apr-2014",
                    "endDate": "30-Apr-2014",
                    "plannedValue": 9455.021795460874,
                    "actualValue": null
                  }
                ]
              }
            ]
          }
        ]
      },
      {
        "id": 19003,
        "name": "!! 1",
        "trackingLevel": "Pay for work completed upon milestone achieved"
      }
    ],
    "url": "/cleartrial-ws/actuals/47323/fees"
  }
}

Costs Track Data

Gets and posts data pertaining to the costs in Track.

Method: GET/POST

URL: /cleartrial-ws/actuals/{baselinePlanId}/costs

Sample output/input:

{
  "actualCosts": {
    "lockToken": 1370451755956,
    "planId": 47323,
    "serviceProvider": [
      {
        "id": 19003,
        "name": "!! 1",
        "cost": [
          {
            "id": 1,
            "name": "Advertising (additional)",
            "earnedValueTrackingLevel": "Auto-tracked (set EV to AC)",
            "location": [
              {
                "locationId": 0,
                "locationName": "All Locations"
              }
            ]
          },
          {
            "id": 27,
            "name": "Call Center ",
            "earnedValueTrackingLevel": "Auto-tracked (set EV to AC)",
            "location": [
              {
                "locationId": 0,
                "locationName": "All Locations"
              }
            ]
          },
          {
            "id": 38,
            "name": "Clinical Trial Insurance",
            "earnedValueTrackingLevel": "Auto-tracked (set EV to AC)",
            "location": [
              {
                "locationId": 157,
                "locationName": "Australia",
                "periods": [
                  {
                    "startDate": "01-Oct-2012",
                    "endDate": "31-Oct-2012",
                    "plannedValue": 0.0,
                    "earnedValue": null,
                    "actualValue": null
                  },
                  {
                   ...
                  },
                  {
                "locationId": 158,
                "locationName": "New Zealand"
              }
            ]
          }
        ]
      }
    ],
    "url": "/cleartrial-ws/actuals/47323/costs"
  }
}