The SimpleTrials Application Program Interface (API) is an option which customers may enable for their workspace, to allow authorized 3rd party applications, tools or scripts to access their SimpleTrials workspace data.
Prerequisites
- The API is available to Premium Plus clients only. If you need to upgrade your subscription to Premium Plus, that can be done directly on the Administration - Subscription & Settings page.
- An Administrator user to SimpleTrials must Enable the API via the Subscription & Settings page, and retrieve the API credentials (customer ID and key).
- To confirm access to the API, we recommend an API tool such as the free Talend plugin for Google Chrome.
Enable the API
- An Admin user logs into SimpleTrials and navigates to the Administration - Subscription & Settings page.
- Click the "Enable API" button.
- Once the API is enabled, the "API Enabled" label below will display a View credentials link.
- Click "View credentials" and copy the Customer ID and Customer API Key values. You will need these two values for making requests to the API.
Making a Request
- Using an API tool, script, or a normal browser tab, you can construct a SimpleTrials API request. You will need:
- The base API URL
- If your SimpleTrials workspace is on "app.simpletrials.com" (the US-based server), your URL is:
- https://app.simpletrials.com/api/v1/
- If using "eu.simpletrials.com" (the EU-based server), your URL is:
- https://eu.simpletrials.com/api/v1/
- Required Parameters
- customer_key - the Customer API Key value displayed in SimpleTrials
- customer_id - the Customer ID number displayed in SimpleTrials
- Additional Parameters
- limit - the page size; default is 1000 records per page, maximum is 1000
- offset - the first record in the response. Default is 0 (first record). For example if the first page of data is:
limit=1000 and offset=0
then the second page would be:
limit=1000 and offset=1000 - See the request details below for additional required and optional parameters.
- Response
- The response is a JSON formatted data structure.
- The response includes the following metadata parameters
- count: number of records included in the response
- limit: page size given in the request (or default)
- offset: offset given in the request (or default)
- total: the total number of records, which may exceed the count of records returned in the current request
- The response also includes a root attribute associated to the request, e.g. "studies" which has an array of data records as the value.
- Rate limiting of requests
- Please note that API requests are rate limited, meaning that a maximum number of requests are allowed each second. If making programmatic requests, please avoid parallel requests or bursts of requests, so as to not exceed the rate limit. If the limit is exceeded, additional requests may be blocked for a limited time.
Comments
0 comments
Article is closed for comments.