Prolific messages API

The messages API from Prolific — 4 operation(s) for messages.

Operations 5

GET /api/v1/messages/ Retrieve messages #
POST /api/v1/messages/ Send a message #
POST /api/v1/messages/bulk/ Send a message to multiple participants #
POST /api/v1/messages/participant-group/ Send a message to a participant group #
GET /api/v1/messages/unread/ Retrieve unread messages #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/prolific-messages-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

prolific-messages-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Reference aiTaskBuilder Messages API
  version: 1.0.0
servers:
- url: https://api.prolific.com
  description: Production
tags:
- name: messages
paths:
  /api/v1/messages/:
    get:
      operationId: get-messages
      summary: Retrieve messages
      description: Get messages between you and another user or your messages with all users.
      tags:
      - messages
      parameters:
      - name: user_id
        in: query
        description: Another user ID, must be provided if no created_after date is provided.
        required: false
        schema:
          type: string
      - name: created_after
        in: query
        description: Only fetch messages created after timestamp. Datetime in ISO8601 format. Must be provided if no user_id is provided. You can only fetch up to the last 30 days of messages.
        required: false
        schema:
          type: string
      - name: excluded_sender_ids
        in: query
        description: 'A comma-separated list of sender IDs whose messages should be excluded from the response. Maximum 10 IDs.


          e.g. `excluded_sender_ids=abc,def`.

          '
        required: false
        schema:
          type: string
      - name: Authorization
        in: header
        description: 'The Prolific API uses API token to authenticate requests. You can create an API token directly from your settings.


          Your API token does not have an expiry date and carries full permission, so be sure to keep them secure.


          If your token is leaked, delete it and create a new one directly in the app.


          In your requests add `Authorization` header with the value `Token <your token>`.'
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Messages
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Messages'
        '400':
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorDetail'
    post:
      operationId: send-message
      summary: Send a message
      description: Send a message to a participant or another researcher
      tags:
      - messages
      parameters:
      - name: Authorization
        in: header
        description: 'The Prolific API uses API token to authenticate requests. You can create an API token directly from your settings.


          Your API token does not have an expiry date and carries full permission, so be sure to keep them secure.


          If your token is leaked, delete it and create a new one directly in the app.


          In your requests add `Authorization` header with the value `Token <your token>`.'
        required: true
        schema:
          type: string
      responses:
        '204':
          description: The message has been sent
          content:
            application/json:
              schema:
                type: object
                properties: {}
        '400':
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorDetail'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SendMessage'
  /api/v1/messages/bulk/:
    post:
      operationId: bulk-message-participants
      summary: Send a message to multiple participants
      description: Send a message to multiple participants.
      tags:
      - messages
      parameters:
      - name: Authorization
        in: header
        description: 'The Prolific API uses API token to authenticate requests. You can create an API token directly from your settings.


          Your API token does not have an expiry date and carries full permission, so be sure to keep them secure.


          If your token is leaked, delete it and create a new one directly in the app.


          In your requests add `Authorization` header with the value `Token <your token>`.'
        required: true
        schema:
          type: string
      responses:
        '204':
          description: The message has been sent
          content:
            application/json:
              schema:
                type: object
                properties: {}
        '400':
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorDetail'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SendBulkMessage'
  /api/v1/messages/participant-group/:
    post:
      operationId: send-message-to-participant-group
      summary: Send a message to a participant group
      description: Send a message to a participant group.
      tags:
      - messages
      parameters:
      - name: Authorization
        in: header
        description: 'The Prolific API uses API token to authenticate requests. You can create an API token directly from your settings.


          Your API token does not have an expiry date and carries full permission, so be sure to keep them secure.


          If your token is leaked, delete it and create a new one directly in the app.


          In your requests add `Authorization` header with the value `Token <your token>`.'
        required: true
        schema:
          type: string
      responses:
        '204':
          description: The message has been sent
          content:
            application/json:
              schema:
                type: object
                properties: {}
        '400':
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorDetail'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/MessageParticipantGroup'
  /api/v1/messages/unread/:
    get:
      operationId: get-unread-messages
      summary: Retrieve unread messages
      description: 'Get all unread messages.

        The messages you have sent are never returned, only messages you have received and not read.

        It does not mark those messages as read.'
      tags:
      - messages
      parameters:
      - name: Authorization
        in: header
        description: 'The Prolific API uses API token to authenticate requests. You can create an API token directly from your settings.


          Your API token does not have an expiry date and carries full permission, so be sure to keep them secure.


          If your token is leaked, delete it and create a new one directly in the app.


          In your requests add `Authorization` header with the value `Token <your token>`.'
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Messages
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Messages'
        '400':
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorDetail'
components:
  schemas:
    MessageDataCategory:
      type: string
      enum:
      - payment-timing
      - payment-issues
      - technical-issues
      - feedback
      - rejections
      - other
      description: Participants can self-categorise their message before sending it.
      title: MessageDataCategory
    MessageParticipantGroup:
      type: object
      properties:
        participant_group_id:
          type: string
          description: A participant group ID
        body:
          type: string
          description: Message Body. Text is sanitised for safe storage and display.
        study_id:
          type: string
          description: A study ID
      required:
      - participant_group_id
      - body
      title: MessageParticipantGroup
    Message:
      type: object
      properties:
        id:
          type: string
          description: Unique ID of the message
        sender_id:
          type: string
          description: Id of the user who sent the message
        body:
          type: string
          description: Body of the message.
        sent_at:
          type: string
          format: date-time
          description: Date time when message was sent
        type:
          type: string
          description: Will only me message for now
        channel_id:
          type: string
          description: The channel ID, for linking back to a thread in the Prolific app.
        data:
          $ref: '#/components/schemas/MessageData'
          description: Metadata for a message
      required:
      - id
      - sender_id
      - body
      - sent_at
      - channel_id
      title: Message
    SendMessage:
      type: object
      properties:
        recipient_id:
          type: string
          description: Recipient user's id
        body:
          type: string
          description: Message Body. Text is sanitised for safe storage and display.
        study_id:
          type: string
          description: This study is the reason for this message
      required:
      - recipient_id
      - body
      - study_id
      title: SendMessage
    ErrorDetail:
      type: object
      properties:
        status:
          type: integer
          description: Status code as in the http standards
        error_code:
          type: integer
          description: Internal error code
        title:
          type: string
          description: Error title
        detail:
          $ref: '#/components/schemas/ErrorDetailDetail'
          description: Error detail
        additional_information:
          type: string
          description: Optional extra information
        traceback:
          type: string
          description: Optional debug information
        interactive:
          type: boolean
      required:
      - status
      - error_code
      - title
      - detail
      title: ErrorDetail
    ErrorDetailDetail:
      oneOf:
      - type: string
      - type: array
        items:
          type: string
      - $ref: '#/components/schemas/ErrorDetailDetail2'
      description: Error detail
      title: ErrorDetailDetail
    ErrorDetailDetail2:
      type: object
      properties:
        any_field:
          type: array
          items:
            type: string
          description: Name of the field with a validation error and as a value an array with the error descriptions
      description: All fields with validation errors
      title: ErrorDetailDetail2
    SendBulkMessage:
      type: object
      properties:
        ids:
          type: array
          items:
            type: string
          description: A list of participant ID's
        body:
          type: string
          description: Message Body. Text is sanitised for safe storage and display.
        study_id:
          type: string
          description: A study ID
      required:
      - ids
      - body
      - study_id
      title: SendBulkMessage
    MessageData:
      type: object
      properties:
        study_id:
          type: string
          description: What study the message relates to. In case this is not automatically filled for the participant, they can choose which study their message relates to.
        category:
          $ref: '#/components/schemas/MessageDataCategory'
          description: Participants can self-categorise their message before sending it.
      description: Metadata for a message
      title: MessageData
    Messages:
      type: object
      properties:
        results:
          type: array
          items:
            $ref: '#/components/schemas/Message'
      title: Messages
  securitySchemes:
    token:
      type: apiKey
      in: header
      name: Authorization
      description: 'The Prolific API uses API token to authenticate requests. You can create an API token directly from your settings.


        Your API token does not have an expiry date and carries full permission, so be sure to keep them secure.


        If your token is leaked, delete it and create a new one directly in the app.


        In your requests add `Authorization` header with the value `Token <your token>`.'