Skip to content

SonaGetStudyInfoByExperimentID

Description

This function returns all information pertaining to a study based on its experiment_id.

Input Parameters

Below are the following input parameters for use with the SonaGetStudyInfoByExperimentID API function.

Parameter Description / Possible Values
api_key Use API key generated for Sona admin user
experiment_id The experiment_id of the study. In the case of a multi-part study, each part has a different experiment_id, but most data fields are the same for each part.

Output Parameters

Will return APIStudyInfo class and display data in an array.

Error Codes

Below are the possible error messages encountered and their respective descriptions.

Error Type Error Code Description
Authentication Failed -1 through -7 Standard authentication errors
Invalid experiment_id -8 experiment_id entered is invalid
Experiment_id not found -9 experiment_id entered is not found

Sample Input

Request URL

https://myschool.sona-systems.com/services/SonaAPI.svc/SonaGetStudyInfoByExperimentID?api_key=YOUR_API_KEY&experiment_id=144

URL components

Component Value
Scheme https
Host myschool.sona-systems.com
Service path /services/SonaAPI.svc
Function SonaGetStudyInfoByExperimentID

Query parameters

api_key = YOUR_API_KEY
experiment_id = 144

Sample Output

<SonaGetStudyInfoByExperimentIDResponse
  xmlns="https://www.sona-systems.com/"
  xmlns:a="http://schemas.datacontract.org/2004/07/emsdotnet.sonasystems"
  xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
  <SonaGetStudyInfoByExperimentIDResult>
    <a:Errors i:nil="true" />
    <a:Result>
      <a:APIStudyInfo>
        <a:active>1</a:active>
        <a:age_maximum>99.0</a:age_maximum>
        <a:age_minimum>0.0</a:age_minimum>
        <a:auto_credit_enable>1</a:auto_credit_enable>
        <a:cancel_limit>24</a:cancel_limit>
        <a:course_restrictions />
        <a:creation_date>2011-01-01T00:00:00</a:creation_date>
        <a:credits>2.00</a:credits>
        <a:double_signup_flag>0</a:double_signup_flag>
        <a:duration>30</a:duration>
        <a:exp_pay_managed>0</a:exp_pay_managed>
        <a:exp_signup_email>2</a:exp_signup_email>
        <a:experiment_id>144</a:experiment_id>
        <a:experiment_url />
        <a:experimenter_timeslot>0</a:experimenter_timeslot>
        <a:has_multipart>1</a:has_multipart>
        <a:has_prereqs>0</a:has_prereqs>
        <a:has_rests>0</a:has_rests>
        <a:irb_code>12345678901</a:irb_code>
        <a:irb_expiration_date>2018-06-17T00:00:00</a:irb_expiration_date>
        <a:is_neg_req>0</a:is_neg_req>
        <a:last_activity>2017-09-04T12:25:41</a:last_activity>
        <a:last_timeslot>2017-08-30T10:30:00</a:last_timeslot>
        <a:long_desc>This is a study</a:long_desc>
        <a:multipart_exact>0</a:multipart_exact>
        <a:multipart_max_days>-1</a:multipart_max_days>
        <a:multipart_min_days>-1</a:multipart_min_days>
        <a:multipart_number>1</a:multipart_number>
        <a:neg_req_any>1</a:neg_req_any>
        <a:parent_experiment_id>0</a:parent_experiment_id>
        <a:payment />
        <a:payment_numeric>0.00</a:payment_numeric>
        <a:pi_id>9263</a:pi_id>
        <a:preparation>None</a:preparation>
        <a:prereq_any>0</a:prereq_any>
        <a:previously_approved>1</a:previously_approved>
        <a:private_comments>comments go here</a:private_comments>
        <a:restrictions>None</a:restrictions>
        <a:short_desc>This is a study</a:short_desc>
        <a:show_participants>0</a:show_participants>
        <a:signup_limit>24</a:signup_limit>
        <a:signup_password />
        <a:study_alternative>0</a:study_alternative>
        <a:study_name>This is a study on Studies</a:study_name>
        <a:survey_anon_flag>0</a:survey_anon_flag>
        <a:survey_flag>0</a:survey_flag>
        <a:total_credits>8.00</a:total_credits>
        <a:total_parts>4</a:total_parts>
        <a:total_payment />
        <a:total_payment_numeric>0.00</a:total_payment_numeric>
        <a:type>C</a:type>
        <a:usage_limit>10</a:usage_limit>
        <a:valid>1</a:valid>
        <a:web_flag>0</a:web_flag>
      </a:APIStudyInfo>
    </a:Result>
  </SonaGetStudyInfoByExperimentIDResult>
</SonaGetStudyInfoByExperimentIDResponse>