Mailchimp Questions API

The Questions API from Mailchimp — 3 operation(s) for questions.

Documentation

Specifications

Schemas & Data

Other Resources

OpenAPI Specification

mailchimp-questions-api-openapi.yml Raw ↑
swagger: '2.0'
info:
  version: 3.0.55
  title: Mailchimp Marketing Abuse Questions API
  contact:
    name: Mailchimp API Support
    email: apihelp@mailchimp.com
  x-permalink: https://github.com/mailchimp/mailchimp-client-lib-codegen/blob/main/spec/marketing.json
  description: '

    The Mailchimp Marketing API provides programmatic access to Mailchimp data

    and functionality, allowing developers to build custom features to do

    things like sync email activity and campaign analytics with their

    database, manage audiences and campaigns, and more.'
host: server.api.mailchimp.com
basePath: /3.0
schemes:
- https
consumes:
- application/json
produces:
- application/json
- application/problem+json
security:
- basicAuth: []
tags:
- name: Questions
paths:
  /reporting/surveys/{survey_id}/questions:
    get:
      summary: Mailchimp List Survey Question Reports
      description: Get reports for survey questions.
      operationId: getReportingSurveysIdQuestions
      parameters:
      - name: fields
        x-title: Fields
        in: query
        description: A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
        required: false
        type: array
        collectionFormat: csv
        items:
          type: string
        example: example_value
      - name: exclude_fields
        x-title: Exclude Fields
        in: query
        description: A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
        required: false
        type: array
        collectionFormat: csv
        items:
          type: string
        example: example_value
      - in: path
        name: survey_id
        x-title: Survey ID
        type: string
        required: true
        description: The ID of the survey.
        example: '500123'
      responses:
        '200':
          description: List of Survey Question Report Instances
          schema:
            type: object
            properties:
              questions:
                type: array
                title: Question Reports
                description: An array of reports for each question on the survey.
                items:
                  type: object
                  title: Survey Question Report
                  description: The details of a survey question's report.
                  properties:
                    id:
                      type: string
                      title: Survey Question ID
                      description: The ID of the survey question.
                      readOnly: true
                    survey_id:
                      type: string
                      title: Survey ID
                      description: The unique ID of the survey.
                      readOnly: true
                    query:
                      type: string
                      title: Query Text
                      description: The query of the survey question.
                      readOnly: true
                    type:
                      type: string
                      title: Response Type
                      description: The response type of the survey question.
                      enum:
                      - pickOne
                      - pickMany
                      - range
                      - text
                      - email
                      readOnly: true
                    total_responses:
                      type: integer
                      title: Total Responses
                      description: The total number of responses to this question.
                      readOnly: true
                      example: 810
                    is_required:
                      type: boolean
                      title: Is Required
                      description: Whether this survey question is required to answer.
                      readOnly: true
                    has_other:
                      type: boolean
                      title: Has Other Option
                      description: Whether this survey question has an 'other' option.
                      readOnly: true
                    other_label:
                      type: string
                      title: Other Option Label
                      description: Label used for the 'other' option of this survey question.
                      readOnly: true
                    average_rating:
                      type: number
                      format: float
                      title: Average Rating for a Range Question
                      description: The average rating for this range question.
                      readOnly: true
                      example: 2.5
                    range_low_label:
                      type: string
                      title: Range Low Label
                      description: Label for the low end of the range.
                      readOnly: true
                    range_high_label:
                      type: string
                      title: Range High Label
                      description: Label for the high end of the range.
                      readOnly: true
                    placeholder_label:
                      type: string
                      title: Placeholder Label
                      description: Placeholder text for this survey question's answer box.
                      readOnly: true
                    subscribe_checkbox_enabled:
                      type: boolean
                      title: Is Subscribe Checkbox Enabled
                      description: Whether the subscribe checkbox is shown for this email question.
                      readOnly: true
                    subscribe_checkbox_label:
                      type: string
                      title: Subscribe Checkbox Label
                      description: Label used for the subscribe checkbox for this email question.
                      readOnly: true
                    merge_field:
                      type: object
                      title: Merge Field
                      description: A [merge field](https://mailchimp.com/developer/marketing/docs/merge-fields/) for an audience.
                      properties:
                        id:
                          type: integer
                          title: Merge Field ID
                          description: An unchanging id for the merge field.
                          readOnly: true
                        label:
                          type: string
                          title: Merge Field Label
                          description: The [label](https://mailchimp.com/developer/marketing/docs/merge-fields/#structure) for the merge field.
                          readOnly: true
                        type:
                          type: string
                          title: Merge Field Type
                          description: The [type](https://mailchimp.com/developer/marketing/docs/merge-fields/#structure) for the merge field.
                          enum:
                          - text
                          - number
                          - address
                          - phone
                          - date
                          - url
                          - imageurl
                          - radio
                          - dropdown
                          - birthday
                          - zip
                          readOnly: true
                      readOnly: true
                    options:
                      type: array
                      title: Options
                      description: The answer choices for this question.
                      items:
                        type: object
                        properties:
                          label:
                            type: string
                            title: Option Label
                            description: The label for this survey question option.
                          id:
                            type: string
                            title: Option ID
                            description: The ID for this survey question option.
                          count:
                            type: integer
                            title: Response Count
                            description: The count of responses that selected this survey question option.
                      readOnly: true
                    contact_counts:
                      type: object
                      title: Contact Counts
                      description: For email question types, how many are new, known, or unknown contacts.
                      properties:
                        known:
                          type: integer
                          title: Known Contacts Count
                          description: The number of known contacts that responded to this survey.
                        unknown:
                          type: integer
                          title: Unknown Contacts Count
                          description: The number of unknown contacts that responded to this survey.
                        new:
                          type: integer
                          title: New Contacts Count
                          description: The number of new contacts that responded to this survey.
              total_items:
                type: integer
                title: Item Count
                description: The total number of items matching the query regardless of pagination.
                readOnly: true
              _links:
                title: Links
                description: A list of link types and descriptions for the API schema documents.
                type: array
                items:
                  type: object
                  title: Resource Link
                  description: This object represents a link from the resource where it is found to another resource or action that may be performed.
                  properties:
                    rel:
                      type: string
                      title: Rel
                      description: As with an HTML 'rel' attribute, this describes the type of link.
                      readOnly: true
                    href:
                      type: string
                      title: Href
                      description: This property contains a fully-qualified URL that can be called to retrieve the linked resource or perform the linked action.
                      readOnly: true
                    method:
                      type: string
                      title: Method
                      description: The HTTP method that should be used when accessing the URL defined in 'href'.
                      enum:
                      - GET
                      - POST
                      - PUT
                      - PATCH
                      - DELETE
                      - OPTIONS
                      - HEAD
                      readOnly: true
                    targetSchema:
                      type: string
                      title: Target Schema
                      description: For GETs, this is a URL representing the schema that the response should conform to.
                      readOnly: true
                    schema:
                      type: string
                      title: Schema
                      description: For HTTP methods that can receive bodies (POST and PUT), this is a URL representing the schema that the body should conform to.
                      readOnly: true
                readOnly: true
        default:
          description: An error generated by the Mailchimp API.
          schema:
            type: object
            title: Problem Detail Document
            description: An error generated by the Mailchimp API. Conforms to IETF draft 'draft-nottingham-http-problem-06'.
            required:
            - type
            - title
            - status
            - detail
            - instance
            properties:
              type:
                type: string
                title: Problem Type
                description: An absolute URI that identifies the problem type. When dereferenced, it should provide human-readable documentation for the problem type.
                example: https://mailchimp.com/developer/marketing/docs/errors/
              title:
                type: string
                title: Error Title
                description: A short, human-readable summary of the problem type. It shouldn't change based on the occurrence of the problem, except for purposes of localization.
                example: Resource Not Found
              status:
                type: integer
                title: HTTP Status Code
                description: The HTTP status code (RFC2616, Section 6) generated by the origin server for this occurrence of the problem.
                example: 404
              detail:
                type: string
                title: Error Message
                description: A human-readable explanation specific to this occurrence of the problem. [Learn more about errors](/developer/guides/get-started-with-mailchimp-api-3/#Errors).
                example: The requested resource could not be found.
              instance:
                type: string
                title: Instance ID
                description: A string that identifies this specific occurrence of the problem. Please provide this ID when contacting support.
                example: 995c5cb0-3280-4a6e-808b-3b096d0bb219
      tags:
      - Questions
      x-custom-config:
        methodNameSnake: get_survey_question_reports_all
        methodNameCamel: getSurveyQuestionReportsAll
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /reporting/surveys/{survey_id}/questions/{question_id}:
    get:
      summary: Mailchimp Get Survey Question Report
      description: Get report for a survey question.
      operationId: getReportingSurveysIdQuestionsId
      parameters:
      - name: fields
        x-title: Fields
        in: query
        description: A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
        required: false
        type: array
        collectionFormat: csv
        items:
          type: string
        example: example_value
      - name: exclude_fields
        x-title: Exclude Fields
        in: query
        description: A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
        required: false
        type: array
        collectionFormat: csv
        items:
          type: string
        example: example_value
      - in: path
        name: survey_id
        x-title: Survey ID
        type: string
        required: true
        description: The ID of the survey.
        example: '500123'
      - in: path
        name: question_id
        x-title: Question ID
        type: string
        required: true
        description: The ID of the survey question.
        example: '500123'
      responses:
        '200':
          description: Survey Question Report Instance
          schema:
            type: object
            title: Survey Question Report
            description: The details of a survey question's report.
            properties:
              id:
                type: string
                title: Survey Question ID
                description: The ID of the survey question.
                readOnly: true
              survey_id:
                type: string
                title: Survey ID
                description: The unique ID of the survey.
                readOnly: true
              query:
                type: string
                title: Query Text
                description: The query of the survey question.
                readOnly: true
              type:
                type: string
                title: Response Type
                description: The response type of the survey question.
                enum:
                - pickOne
                - pickMany
                - range
                - text
                - email
                readOnly: true
              total_responses:
                type: integer
                title: Total Responses
                description: The total number of responses to this question.
                readOnly: true
                example: 810
              is_required:
                type: boolean
                title: Is Required
                description: Whether this survey question is required to answer.
                readOnly: true
              has_other:
                type: boolean
                title: Has Other Option
                description: Whether this survey question has an 'other' option.
                readOnly: true
              other_label:
                type: string
                title: Other Option Label
                description: Label used for the 'other' option of this survey question.
                readOnly: true
              average_rating:
                type: number
                format: float
                title: Average Rating for a Range Question
                description: The average rating for this range question.
                readOnly: true
                example: 2.5
              range_low_label:
                type: string
                title: Range Low Label
                description: Label for the low end of the range.
                readOnly: true
              range_high_label:
                type: string
                title: Range High Label
                description: Label for the high end of the range.
                readOnly: true
              placeholder_label:
                type: string
                title: Placeholder Label
                description: Placeholder text for this survey question's answer box.
                readOnly: true
              subscribe_checkbox_enabled:
                type: boolean
                title: Is Subscribe Checkbox Enabled
                description: Whether the subscribe checkbox is shown for this email question.
                readOnly: true
              subscribe_checkbox_label:
                type: string
                title: Subscribe Checkbox Label
                description: Label used for the subscribe checkbox for this email question.
                readOnly: true
              merge_field:
                type: object
                title: Merge Field
                description: A [merge field](https://mailchimp.com/developer/marketing/docs/merge-fields/) for an audience.
                properties:
                  id:
                    type: integer
                    title: Merge Field ID
                    description: An unchanging id for the merge field.
                    readOnly: true
                  label:
                    type: string
                    title: Merge Field Label
                    description: The [label](https://mailchimp.com/developer/marketing/docs/merge-fields/#structure) for the merge field.
                    readOnly: true
                  type:
                    type: string
                    title: Merge Field Type
                    description: The [type](https://mailchimp.com/developer/marketing/docs/merge-fields/#structure) for the merge field.
                    enum:
                    - text
                    - number
                    - address
                    - phone
                    - date
                    - url
                    - imageurl
                    - radio
                    - dropdown
                    - birthday
                    - zip
                    readOnly: true
                readOnly: true
              options:
                type: array
                title: Options
                description: The answer choices for this question.
                items:
                  type: object
                  properties:
                    label:
                      type: string
                      title: Option Label
                      description: The label for this survey question option.
                    id:
                      type: string
                      title: Option ID
                      description: The ID for this survey question option.
                    count:
                      type: integer
                      title: Response Count
                      description: The count of responses that selected this survey question option.
                readOnly: true
              contact_counts:
                type: object
                title: Contact Counts
                description: For email question types, how many are new, known, or unknown contacts.
                properties:
                  known:
                    type: integer
                    title: Known Contacts Count
                    description: The number of known contacts that responded to this survey.
                  unknown:
                    type: integer
                    title: Unknown Contacts Count
                    description: The number of unknown contacts that responded to this survey.
                  new:
                    type: integer
                    title: New Contacts Count
                    description: The number of new contacts that responded to this survey.
        default:
          description: An error generated by the Mailchimp API.
          schema:
            type: object
            title: Problem Detail Document
            description: An error generated by the Mailchimp API. Conforms to IETF draft 'draft-nottingham-http-problem-06'.
            required:
            - type
            - title
            - status
            - detail
            - instance
            properties:
              type:
                type: string
                title: Problem Type
                description: An absolute URI that identifies the problem type. When dereferenced, it should provide human-readable documentation for the problem type.
                example: https://mailchimp.com/developer/marketing/docs/errors/
              title:
                type: string
                title: Error Title
                description: A short, human-readable summary of the problem type. It shouldn't change based on the occurrence of the problem, except for purposes of localization.
                example: Resource Not Found
              status:
                type: integer
                title: HTTP Status Code
                description: The HTTP status code (RFC2616, Section 6) generated by the origin server for this occurrence of the problem.
                example: 404
              detail:
                type: string
                title: Error Message
                description: A human-readable explanation specific to this occurrence of the problem. [Learn more about errors](/developer/guides/get-started-with-mailchimp-api-3/#Errors).
                example: The requested resource could not be found.
              instance:
                type: string
                title: Instance ID
                description: A string that identifies this specific occurrence of the problem. Please provide this ID when contacting support.
                example: 995c5cb0-3280-4a6e-808b-3b096d0bb219
      tags:
      - Questions
      x-custom-config:
        methodNameSnake: get_survey_question_report
        methodNameCamel: getSurveyQuestionReport
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /reporting/surveys/{survey_id}/questions/{question_id}/answers:
    get:
      summary: Mailchimp List Answers for Question
      description: Get answers for a survey question.
      operationId: getReportingSurveysIdQuestionsIdAnswers
      parameters:
      - name: fields
        x-title: Fields
        in: query
        description: A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
        required: false
        type: array
        collectionFormat: csv
        items:
          type: string
        example: example_value
      - name: exclude_fields
        x-title: Exclude Fields
        in: query
        description: A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
        required: false
        type: array
        collectionFormat: csv
        items:
          type: string
        example: example_value
      - in: path
        name: survey_id
        x-title: Survey ID
        type: string
        required: true
        description: The ID of the survey.
        example: '500123'
      - in: path
        name: question_id
        x-title: Question ID
        type: string
        required: true
        description: The ID of the survey question.
        example: '500123'
      - name: respondent_familiarity_is
        x-title: Respondent Familiarity Is
        in: query
        description: Filter survey responses by familiarity of the respondents.
        required: false
        type: string
        enum:
        - new
        - known
        - unknown
        example: example_value
      responses:
        '200':
          description: List of Survey Question Answers
          schema:
            type: object
            properties:
              answers:
                type: array
                title: Answers
                description: An array of answers for a question on the survey.
                items:
                  type: object
                  title: Survey Question Answer
                  description: The details of a survey question's answer.
                  properties:
                    id:
                      type: string
                      title: Answer ID
                      description: The ID of the answer.
                      readOnly: true
                    value:
                      type: string
                      title: Value
                      description: The raw text answer.
                      readOnly: true
                    response_id:
                      type: string
                      title: Response ID
                      description: The ID of the survey response.
                      readOnly: true
                    submitted_at:
                      type: string
                      format: date-time
                      title: Submitted At
                      description: The date and time when the survey response was submitted in ISO 8601 format.
                      readOnly: true
                    contact:
                      type: object
                      title: Contact
                      description: Information about the contact.
                      readOnly: true
                      properties:
                        email_id:
                          type: string
                          title: Email ID
                          description: The MD5 hash of the lowercase version of the list member's email address.
                          readOnly: true
                        contact_id:
                          type: string
                          title: Contact ID
                          description: The ID of this contact.
                          readOnly: true
                        status:
                          type: string
                          title: Contact Status
                          description: The contact's current status.
                          readOnly: true
                          enum:
                          - Subscribed
                          - Unsubscribed
                          - Non-Subscribed
                          - Cleaned
                          - Archived
                        email:
                          type: string
                          title: Contact Email
                          description: The contact's email address.
                          readOnly: true
                        phone:
                          type: string
                          title: Contact SMS Phone
                          description: The contact's sms phone number.
                          readOnly: true
                        full_name:
                          type: string
                          title: Full Name
                          description: The contact's full name.
                          readOnly: true
                        consents_to_one_to_one_messaging:
                          type: boolean
                          title: Messaging Consent
                          description: Indicates whether a contact consents to 1:1 messaging.
                          readOnly: true
                        avatar_url:
                          type: string
                          title: Avatar URL
                          description: URL for the contact's avatar or profile image.
                          readOnly: true
                    is_new_contact:
                      type: boolean
                      title: Is New Contact
                      description: If this contact was added to the Mailchimp audience via this survey.
                      readOnly: false
              total_items:
                type: integer
                title: Item Count
                description: The total number of items matching the query regardless of pagination.
                readOnly: true
              _links:
                title: Links
                description: A list of link types and descriptions for the API schema documents.
                type: array
                items:
                  type: object
                  title: Resource Link
                  description: This object represents a link from the resource where it is found to another resource or action that may be performed.
                  properties:
                    rel:
                      type: string
                      title: Rel
                      description: As with an HTML 'rel' attribute, this describes the type of link.
                      readOnly: true
                    href:
                      type: string
                      title: Href
                      description: This property contains a fully-qualified URL that can be called to retrieve the linked resource or perform the linked action.
                      readOnly: true
                    method:
                      type: string
                      title: Method
                      description: The HTTP method that should be used when accessing the URL defined in 'href'.
                      enum:
                      - GET
                      - POST
                      - PUT
                      - PATCH
                      - DELETE
                      - OPTIONS
                      - HEAD
                      readOnly: true
                    targetSchema:
                      type: string
                      title: Target Schema
                      description: For GETs, this is a URL representing the schema that the response should conform to.
                      readOnly: true
                    schema:
                      type: string
                      title: Schema
                      description: For HTTP methods that can receive bodies (POST and PUT), this is a URL representing the schema that the body should conform to.
                      readOnly: true
                readOnly: true
        default:
          description: An error generated by the Mailchimp API.
          schema:
            type: object
            title: Problem Detail Document
            description: An error generated by the Mailchimp API. Conforms to IETF draft 'draft-nottingham-http-problem-06'.
            required:
            - type
            - title
            - status
            - detail
            - instance
            properties:
              type:
                type: string
                title: Problem Type
                description: An absolute URI that identifies the problem type. When dereferenced, it should provide human-readable documentation for the problem type.
                example: https://mailchimp.com/developer/marketing/docs/errors/
              title:
                type: string
                title: Error Title
                description: A short, human-readable summary of the problem type. It shouldn't change based on the occurrence of

# --- truncated at 32 KB (59 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/mailchimp/refs/heads/main/openapi/mailchimp-questions-api-openapi.yml