> ## Documentation Index
> Fetch the complete documentation index at: https://developers.partoo.co/llms.txt
> Use this file to discover all available pages before exploring further.

# Search for feedback results

> <Warning>
The Feedback Management API is currently in **BETA**, therefore the following endpoints are subject to modification, given a **2 week notice**.

If you are planning to use any of them, please **notify us** so we will be able to keep you informed about upcoming changes.
</Warning>

This endpoint lets you search for the feedback results of your businesses.

The response is paginated (30 results per page).




## OpenAPI

````yaml /assets/openapi/openapi-bundled.yaml get /feedback/feedback_result
openapi: 3.1.0
info:
  title: Partoo Rest API
  version: v2
  license:
    name: © Copyright Partoo
    url: https://www.partoo.co/en/gtu-api/
  x-logo:
    url: >-
      https://partoo-client-images.s3.amazonaws.com/logo-partoo-restapi-white.png
  description: >
    ## Introduction

    The Partoo Rest API allows you to automate all the actions that are possible
    to do in the Partoo Web Application.


    The Partoo Rest API can be used for many different purposes:
      - Create/update/delete your businesses & users if you are a client.
      - Create/subscribe/manage organizations, businesses & users if you are a reseller.
      - Retrieve data on businesses you have access to if you are a publisher.
      - ...
servers:
  - url: https://api.partoo.co/v2
    description: Production server
  - url: https://api.sandbox.partoo.co/v2
    description: Sandbox server (dev environment for clients & partners)
security:
  - ApiKeyAuth: []
paths:
  /feedback/feedback_result:
    get:
      tags:
        - Feedback Management
      summary: Search for feedback results
      description: >
        <Warning>

        The Feedback Management API is currently in **BETA**, therefore the
        following endpoints are subject to modification, given a **2 week
        notice**.


        If you are planning to use any of them, please **notify us** so we will
        be able to keep you informed about upcoming changes.

        </Warning>


        This endpoint lets you search for the feedback results of your
        businesses.


        The response is paginated (30 results per page).
      operationId: searchFeedbackResults
      parameters:
        - $ref: '#/components/parameters/query_business__in'
        - $ref: '#/components/parameters/query_business__notin'
        - $ref: '#/components/parameters/state__in'
        - $ref: '#/components/parameters/created__lte'
        - $ref: '#/components/parameters/created__gte'
        - $ref: '#/components/parameters/nps__lte'
        - $ref: '#/components/parameters/nps__gte'
        - $ref: '#/components/parameters/nps__in'
        - $ref: '#/components/parameters/search'
        - $ref: '#/components/parameters/optin'
        - $ref: '#/components/parameters/feedback_form_ids'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/ListResult'
                  - type: object
                    properties:
                      items:
                        description: Filtered feedback results
                        type: array
                        items:
                          $ref: '#/components/schemas/feedback_result'
        '400':
          $ref: '#/components/responses/400'
        '401':
          $ref: '#/components/responses/401'
        '403':
          $ref: '#/components/responses/403'
components:
  parameters:
    query_business__in:
      in: query
      name: business__in
      description: >-
        Filter by business ids. Use a comma-separated list to provide multiple
        ids.
      schema:
        type: array
        example: >-
          a1c9f37b4deca92f83b61d02,9f4e2a8c0d73b154e621bc97,c73b15e9fa42d60b3a8c21ef
        items:
          $ref: '#/components/schemas/BusinessId'
          description: ''
    query_business__notin:
      in: query
      name: business__notin
      description: Excludes from the request all businesses provided
      schema:
        type: array
        items:
          $ref: '#/components/schemas/BusinessId'
    state__in:
      in: query
      name: state__in
      schema:
        type: array
        items:
          allOf:
            - $ref: '#/components/schemas/FeedbackResultState'
        example: treated,not_treated
      description: State of the feedback result
    created__lte:
      in: query
      name: created__lte
      schema:
        type: string
        format: datetime
        example: '2024-10-01T00:00:00Z'
      description: Max date the feedback result was created on
    created__gte:
      in: query
      name: created__gte
      schema:
        type: string
        format: datetime
        example: '2024-11-01T00:00:00Z'
      description: Min date the feedback result was created on
    nps__lte:
      in: query
      name: nps__lte
      schema:
        allOf:
          - $ref: '#/components/schemas/nps'
      description: Max NPS of the feedback result
    nps__gte:
      in: query
      name: nps__gte
      schema:
        allOf:
          - $ref: '#/components/schemas/nps'
      description: Min NPS of the feedback result
    nps__in:
      in: query
      name: nps__in
      schema:
        type: array
        items:
          allOf:
            - $ref: '#/components/schemas/nps'
        example: 0,1,2,8,9,10
      description: The possible NPS values of the feedback result
    search:
      in: query
      name: search
      schema:
        type: array
        maxItems: 6
        items:
          type: string
      description: The possible words contained in the text field of the feedback result
    optin:
      in: query
      name: optin
      schema:
        type: boolean
        enum:
          - true
          - false
      description: Whether the respondent accepts to be contacted
    feedback_form_ids:
      in: query
      name: feedback_form_ids
      schema:
        type: array
        items:
          allOf:
            - $ref: '#/components/schemas/FeedbackFormId'
      description: The forms for which the feedback result is for
  schemas:
    ListResult:
      type: object
      properties:
        page:
          $ref: '#/components/schemas/current_page'
        max_page:
          $ref: '#/components/schemas/max_page'
        count:
          $ref: '#/components/schemas/count'
    feedback_result:
      type: object
      properties:
        id:
          type: integer
          example: 1
        business_id:
          allOf:
            - $ref: '#/components/schemas/BusinessId'
        firstname:
          type: string
          description: Firstname of the respondent
          example: John
        lastname:
          type: string
          description: Lastname of the respondent
          example: Doe
        nps:
          allOf:
            - $ref: '#/components/schemas/nps'
        content:
          type: string
          description: Content of the FREE_FORM field
          example: >-
            Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse
            vulputate efficitur augue, ac auctor nibh scelerisque at. Nulla
            facilisi. Maecenas luctus efficitur sem sit amet ullamcorper. Donec
            tempor augue lorem, vitae convallis sapien aliquam id. Maecenas eu
            odio non est pretium eleifend. Nullam at odio eu ligula ultrices
            tincidunt. Nulla euismod aliquet ex eget efficitur.
        state:
          allOf:
            - $ref: '#/components/schemas/FeedbackResultState'
        optin:
          type: boolean
          description: Whether the respondent accepts to be contacted
          enum:
            - true
            - false
        created:
          type: string
          format: datetime
          description: Date the feedback result was created on
          example: '2024-10-25T15:12:11+00:00'
        feedback_form:
          type: object
          properties:
            id:
              allOf:
                - $ref: '#/components/schemas/FeedbackFormId'
            display_name:
              allOf:
                - $ref: '#/components/schemas/display_name'
          description: Information about the corresponding feedback form
        feedback_result_fields:
          type: array
          items:
            $ref: '#/components/schemas/feedback_result_field'
          description: The various fields of the feedback result
        comments:
          type: array
          items:
            $ref: '#/components/schemas/feedback_result_reply'
          description: The replies of the feedback result
        extra:
          type: object
          description: >-
            The additional hidden fields (other than `firstname`, `lastname`,
            `store_code`, `email` and `date`)
          example:
            extra_field: value
            extra_field_2: value_2
    BusinessId:
      description: Business id
      type: string
      example: 5409c35a97bbc544d8e26737
    FeedbackResultState:
      type: string
      enum:
        - treated
        - not_treated
      description: State of the feedback result
    nps:
      type: integer
      minimum: 0
      maximum: 10
      description: NPS of the feedback result
      example: 9
    FeedbackFormId:
      type: string
      description: The unique identifier of the form
      example: 674d791c13c9d976e20001b1
    current_page:
      type: integer
      description: Current page number
      example: 1
    max_page:
      type: integer
      description: Last page number
      example: 10
    count:
      type: integer
      description: Number of resources complying with filters
      example: 287
    display_name:
      type: string
      description: Name of your form
      example: Global Satisfaction
    feedback_result_field:
      type: object
      properties:
        rating:
          type:
            - integer
            - 'null'
          description: |
            Rating assigned by the respondent, if any

            Is set for CSAT and NPS fields
          example: 4
        content:
          type:
            - string
            - 'null'
          description: |
            Text content written by the respondent, if any

            Is set for FREE_FORM fields
          example: null
        choices:
          type:
            - array
            - 'null'
          items:
            type: string
          description: |
            Choices selected by the respondent

            Is set for MULTIPLE_CHOICE fields
          example: null
        feedback_form_field:
          $ref: '#/components/schemas/feedback_form_field'
    feedback_result_reply:
      type: object
      properties:
        id:
          type: integer
          description: Unique identifier of the reply
          example: 1
        created:
          type: string
          format: datetime
          description: Date the reply was created
          example: '2024-11-15T10:00:15+00:00'
        author_name:
          type: string
          description: Author of the reply
          example: Jane Doe
        content:
          type: string
          description: Content of the reply
          example: Thank you for your feedback
        feedback_result_id:
          type: integer
          description: Identifier of the feedback result
          example: 1
        user_id:
          allOf:
            - $ref: '#/components/schemas/UserId'
        is_reply_suggestion:
          type: boolean
          description: Whether the reply was created using an AI suggestion
          example: false
    feedback_form_field:
      type: object
      properties:
        id:
          type: string
          description: |
            Unique identifier of the field
          example: 674d7aaa13e599deae0001b2
        field_type:
          type: string
          enum:
            - NPS
            - FREE_FORM
            - CSAT
            - MULTIPLE_CHOICE
          example: CSAT
        field_label:
          type: string
          description: |
            The label of the field (i.e. the question that was answered)
          example: How would you rate our service?
        field_choices:
          type:
            - array
            - 'null'
          items:
            type: object
            properties:
              id:
                type: string
              text:
                type: string
              isOtherOption:
                type: boolean
                description: Whether this is the "Other" option
                example: false
          description: |
            All choices that were ever available for this field

            Only set for MULTIPLE_CHOICE fields
          example: null
    UserId:
      description: User id
      type: string
      example: 5309c3a237bbc544d8e26737
  responses:
    '400':
      description: Your request is incorrect
      content:
        application/json:
          schema:
            description: |
              Error that occcurs when your request is incorrect
            properties:
              errors:
                type: object
                description: The detail of the error encountered
                properties:
                  json:
                    type: object
    '401':
      description: You are not authenticated
      content:
        application/json:
          schema:
            description: Error that occurs when you are not authenticated
            type: object
            properties:
              errors:
                type: object
                description: The detail of the error encountered
                properties:
                  authentication:
                    type: string
                    default: User not authenticated
    '403':
      description: |
        You are not allowed to perform this action
      content:
        application/json:
          schema:
            description: >
              Error that occurs when you are authenticated but you are trying to
              perform an action you are not allowed to perform
            type: object
            properties:
              errors:
                type: object
                description: The detail of the error encountered
                properties:
                  authorization:
                    type: string
                    default: Operation not allowed
  securitySchemes:
    ApiKeyAuth:
      description: >
        The authentication system on Partoo API is using API Key that should be
        put in the header of the request (the name of the header is `x-APIKey`).
        An api_key is linked to a user. This user's role will give you different
        access level to the API features.
      type: apiKey
      in: header
      name: x-APIKey

````