# Retrieve a submission GET https://api.prolific.com/api/v1/submissions/{id}/ Returns the detailed information of a submission, including the study id, participant id, status and start timestamp Reference: https://beta-docs.prolific.com/api-reference/submissions/get-submission ## OpenAPI Specification ```yaml openapi: 3.1.1 info: title: Retrieve a submission version: endpoint_submissions.GetSubmission paths: /api/v1/submissions/{id}/: get: operationId: get-submission summary: Retrieve a submission description: |- Returns the detailed information of a submission, including the study id, participant id, status and start timestamp tags: - - subpackage_submissions parameters: - name: id in: path description: |- Submission id. This is the ID we pass to the survey platform using %SESSION_ID% required: true schema: type: string - name: Authorization in: header description: Header authentication of the form `undefined ` required: true schema: type: string responses: '200': description: Found content: application/json: schema: $ref: '#/components/schemas/SubmissionDetail' '400': description: Error content: {} components: schemas: SubmissionDetailStatus: type: string enum: - value: ACTIVE - value: APPROVED - value: PARTIALLY APPROVED - value: AWAITING REVIEW - value: REJECTED - value: RESERVED - value: RETURNED - value: TIMED-OUT - value: SCREENED OUT - value: UNKNOWN SubmissionDetail: type: object properties: id: type: string description: The id of the submission completed_at: type: - string - 'null' description: The time the submission was completed at. entered_code: type: - string - 'null' description: The completion code used by the participant to complete the study. participant: type: string description: Participant id. started_at: type: string description: The date and time that the user started the submission (UTC) status: $ref: '#/components/schemas/SubmissionDetailStatus' description: The current status of the submission study_id: type: string description: Study id. parent_study_id: type: - string - 'null' description: >- ID of the study's parent, if any. (This applies to representative sample and quota studies.) bonus_payments: type: array items: type: number format: double description: >- Bonus payments that have been paid on the submission. Returned in pence / cents. return_requested: type: - string - 'null' format: date-time description: The date and time when a return request for the submission was made. required: - id - started_at - status - study_id ``` ## SDK Code Examples ```python import requests url = "https://api.prolific.com/api/v1/submissions/id/" headers = {"Authorization": ""} response = requests.get(url, headers=headers) print(response.json()) ``` ```javascript const url = 'https://api.prolific.com/api/v1/submissions/id/'; const options = {method: 'GET', headers: {Authorization: ''}}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api.prolific.com/api/v1/submissions/id/" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("Authorization", "") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api.prolific.com/api/v1/submissions/id/") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["Authorization"] = '' response = http.request(request) puts response.read_body ``` ```java HttpResponse response = Unirest.get("https://api.prolific.com/api/v1/submissions/id/") .header("Authorization", "") .asString(); ``` ```php request('GET', 'https://api.prolific.com/api/v1/submissions/id/', [ 'headers' => [ 'Authorization' => '', ], ]); echo $response->getBody(); ``` ```csharp var client = new RestClient("https://api.prolific.com/api/v1/submissions/id/"); var request = new RestRequest(Method.GET); request.AddHeader("Authorization", ""); IRestResponse response = client.Execute(request); ``` ```swift import Foundation let headers = ["Authorization": ""] let request = NSMutableURLRequest(url: NSURL(string: "https://api.prolific.com/api/v1/submissions/id/")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ```