Prolific Filters API

Demographic and screening requirements and eligibility counts.

Documentation

Specifications

Other Resources

OpenAPI Specification

prolific-research-filters-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: Prolific Bonuses Filters API
  description: 'The Prolific API is a versioned REST interface for the Prolific online research participant recruitment platform. Researchers use it to programmatically create and publish studies, review and approve submissions, manage participant groups, projects and workspaces, apply demographic filters and requirements, pay bonuses, message participants, and subscribe to event webhooks (hooks). The API is served from https://api.prolific.com/api/v1 and follows a standard REST pattern: a collection endpoint (.../resource/) for GET (list) and POST (create), and an element endpoint (.../resource/{id}/) for GET, PATCH/PUT, and DELETE. All requests are authenticated with an API token supplied in the Authorization header as "Token <your token>".'
  version: v1
  contact:
    name: Prolific
    url: https://docs.prolific.com/api-reference
  license:
    name: Proprietary
    url: https://www.prolific.com/terms
servers:
- url: https://api.prolific.com/api/v1
  description: Prolific API v1
security:
- tokenAuth: []
tags:
- name: Filters
  description: Demographic and screening requirements and eligibility counts.
paths:
  /filters/:
    get:
      operationId: listFilters
      tags:
      - Filters
      summary: List all filters
      description: List all filters (requirements) that can be applied to your filter sets or studies.
      responses:
        '200':
          description: A list of filters.
          content:
            application/json:
              schema:
                type: object
        '401':
          $ref: '#/components/responses/Unauthorized'
  /filters/{filter_id}/distribution/:
    parameters:
    - name: filter_id
      in: path
      required: true
      schema:
        type: string
    get:
      operationId: getFilterDistribution
      tags:
      - Filters
      summary: Get filter distribution
      responses:
        '200':
          description: The distribution of participants across the filter's values.
          content:
            application/json:
              schema:
                type: object
        '401':
          $ref: '#/components/responses/Unauthorized'
  /participant-counts/:
    post:
      operationId: countParticipants
      tags:
      - Filters
      summary: Count participants
      description: Count how many eligible participants match a set of filters.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                filters:
                  type: array
                  items:
                    type: object
      responses:
        '200':
          description: The count of eligible participants.
          content:
            application/json:
              schema:
                type: object
        '401':
          $ref: '#/components/responses/Unauthorized'
components:
  schemas:
    Error:
      type: object
      properties:
        error:
          type: object
          properties:
            detail:
              type: string
            error_code:
              type: integer
  responses:
    Unauthorized:
      description: Authentication credentials were missing or invalid.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    tokenAuth:
      type: apiKey
      in: header
      name: Authorization
      description: API token supplied as "Token <your token>".