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

# Retrieve question set for a flow by id

> Return a question set for a given flow, used to filter potentially applicable forms down to a list of required forms.



## OpenAPI

````yaml /spf/api-reference/payroll-forms-api.yaml get /flowQuestionSet/{flowId}/{questionSetId}
openapi: 3.0.1
info:
  title: SPF Api
  contact:
    name: Symmetry Software
    url: https://www.symmetry.com
    email: support@symmetry.com
  license:
    name: Symmetry Software/Subscription & Service Agreement
    url: http://www.symmetry.com/software-subscription-license
  version: 1.94.0
  x-release-name:
    value: 2026.7.1
  x-endpoint-versions:
    fill_pdf_post_version: 1.95.0
    forms_version: 1.95.0
    form_questions_version: 1.95.0
    docs_version: 1.93.0
    guided_flows_version: 1.95.0
    flow_questions_version: 1.95.0
    getPdf_version: 1.95.0
    ste_mapping_version: 1.1.0
    fill_pdf_get_version: 1.95.0
    /v2/forms_version: 1.95.0
    form_ids_version: 1.95.0
    form_catalog_version: 1.87.0
servers:
  - url: https://api.symmetry.com/spf
    description: prod2
security: []
tags:
  - name: Forms
    description: Determine all applicable forms and retrieve information for each
  - name: Questions
    description: Retrieve form and guide flow questions
  - name: PDF and Tax Parameters
    description: Retrieve pdf and tax parameter schemas and generate filled documents
  - name: Documentation
    description: Retrieve OpenApi configuration yaml and use it to generate a client api
  - name: Postman
    description: Resources for Postman
  - name: STE Mapping
    description: Retrieve SPF-to-STE tax parameter mappings
paths:
  /flowQuestionSet/{flowId}/{questionSetId}:
    get:
      tags:
        - Questions
      summary: Retrieve question set for a flow by id
      description: >-
        Return a question set for a given flow, used to filter potentially
        applicable forms down to a list of required forms.
      operationId: getFlowQuestionSet
      parameters:
        - name: flowId
          in: path
          required: true
          schema:
            type: string
        - name: questionSetId
          in: path
          required: true
          schema:
            type: string
        - name: includeWarnings
          in: query
          description: >-
            When true, includes warning rules for the question set. Warnings are
            disabled by default.
          required: false
          schema:
            type: boolean
            default: false
        - name: prioritizeStandardFederalWithholding
          in: query
          description: >-
            When true, reorders Federal W-4 survey questions to prioritize
            Standard Federal Withholding first, followed by Foreign Earned
            Income Exclusion, then Nonresident Alien Exempt
          required: false
          schema:
            type: boolean
            default: false
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/QuestionSet'
              examples:
                Flow question set options may or may result in a list of forms to complete, similar to the /guide-flows endpoint, a list of form ids will be provided once a form determination has been made.  In the example response, if employee selects 'Yes' (true), no more questions are needed and the formsToComplete list associated with the radio button option will contain the required forms.  Additionally, the hasMoreQuestions field of the navigation mapping will be set to false for this option.  If the employee had selected 'No' (false) then no determination could be made and we must move on to the next question, and so on, until a determination can be made.:
                  summary: Flow question set
                  description: >-
                    Flow question set options may or may result in a list of
                    forms to complete, similar to the /guide-flows endpoint, a
                    list of form ids will be provided once a form determination
                    has been made.  In the example response, if employee selects
                    'Yes' (true), no more questions are needed and the
                    formsToComplete list associated with the radio button option
                    will contain the required forms.  Additionally, the
                    hasMoreQuestions field of the navigation mapping will be set
                    to false for this option.  If the employee had selected 'No'
                    (false) then no determination could be made and we must move
                    on to the next question, and so on, until a determination
                    can be made.
                  value:
                    id: QS1
                    questions:
                      - id: isTerminatingMilitarySpouseExemption
                        questionText: >-
                          Do you currently have a military spouse exemption that
                          you no longer qualify for OR no longer wish to claim?
                        validationErrorMessage: Please select an option
                        htmlType: INPUT
                        displayType: RADIO
                        required:
                          whenRequired: ALWAYS
                        questionOptions:
                          - label: 'Yes'
                            value: true
                            formsToComplete:
                              - id: AZ101
                                name: A-4
                                title: Employee's Arizona Withholding Election
                                formVersion: 2020.12.0
                                formLocality: AZ
                                initialQuestionSet: QS1
                              - id: AZ102
                                name: WEC
                                title: Employee Withholding Exemption Certificate
                                formVersion: 2020.12.0
                                formLocality: AZ
                                initialQuestionSet: QS1
                          - label: 'No'
                            value: false
                        isCalculated: false
                    breadcrumbTitle: Military Spouse Exemption
                    navigation:
                      navigationType: VARIABLE
                      questionId: isTerminatingMilitarySpouseExemption
                      navigationMappings:
                        'false':
                          nextQuestionSetId: QS2
                          hasMoreQuestions: true
                        'true':
                          hasMoreQuestions: false
        '400':
          description: ''
          content: {}
        '403':
          description: Forbidden
          content:
            '*/*':
              schema:
                $ref: '#/components/schemas/ApiError'
        '404':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
              example:
                path: uri=/spf/flowQuestionSet/FL_RESIDENT/QS3
                status: Not Found
                statusCode: 404
                timestamp: '2020-09-15 15:50:55'
                errors:
                  - message: Flow does not exist
                    rejectedValue: FL_RESIDENT
                errorCount: 1
        '500':
          description: Internal Server Error
          content:
            '*/*':
              schema:
                $ref: '#/components/schemas/ApiError'
      security:
        - jwtToken: []
components:
  schemas:
    QuestionSet:
      type: object
      properties:
        id:
          type: string
        notice:
          $ref: '#/components/schemas/Notice'
        questions:
          type: array
          items:
            $ref: '#/components/schemas/Question'
        breadcrumbTitle:
          type: string
        copyKey:
          type: string
          description: >-
            Stable key identifying this question set's breadcrumb title for copy
            customization. Format: {formId}.{questionSetId}.breadcrumbTitle.
            Omitted when not applicable.
        navigation:
          $ref: '#/components/schemas/Navigation'
        warningRulesList:
          type: array
          items:
            $ref: '#/components/schemas/WarningRule'
        notes:
          type: array
          items:
            $ref: '#/components/schemas/Note'
    ApiError:
      type: object
      properties:
        path:
          type: string
        status:
          type: string
        statusCode:
          type: integer
          format: int32
        timestamp:
          type: string
          format: date-time
        errors:
          type: array
          items:
            $ref: '#/components/schemas/ValidationError'
        errorCount:
          type: integer
          format: int32
    Notice:
      type: object
      properties:
        type:
          type: string
          enum:
            - WARNING
            - DEPRECATION
            - INFORMATION
        message:
          type: string
    Question:
      type: object
      properties:
        id:
          type: string
        questionText:
          type: string
        notes:
          type: array
          items:
            $ref: '#/components/schemas/Note'
        validationRegex:
          type: string
        validationErrorMessage:
          type: string
        htmlType:
          type: string
          enum:
            - INPUT
            - SELECT
            - TEXTAREA
            - PARAGRAPH
            - UNORDERED_LIST
            - TABLE
            - IMAGE
        displayType:
          type: string
          enum:
            - TEXT
            - RADIO
            - CHECKBOX
            - MULTI_SELECT_CHECKBOX
            - MONTH_YEAR
            - YEAR
            - TELEPHONE
            - EMAIL
            - ZIPCODE
            - INTEGER
            - PERCENT
            - DOLLAR
        required:
          $ref: '#/components/schemas/Required'
        questionOptions:
          type: array
          items:
            $ref: '#/components/schemas/QuestionOption'
        multiSelectQuestionOptions:
          type: array
          items:
            $ref: '#/components/schemas/MultiSelectionQuestionOption'
        calculation:
          $ref: '#/components/schemas/Calculation'
        isCalculated:
          type: boolean
        copyKey:
          type: string
          description: >-
            Stable, human-readable key identifying this question's primary label
            for copy customization. Format: {formId}.{questionId}.questionText.
            Omitted when not applicable.
        validationErrorCopyKey:
          type: string
          description: >-
            Stable, human-readable key identifying this question's validation
            error message for copy customization. Format:
            {formId}.{questionId}.validationErrorMessage. Omitted when the
            question has no validation error message.
    Navigation:
      type: object
      properties:
        navigationType:
          type: string
          enum:
            - CONSTANT
            - VARIABLE
      discriminator:
        propertyName: navigationType
        mapping:
          CONSTANT:
            $ref: '#/components/schemas/ConstantNavigation'
          VARIABLE:
            $ref: '#/components/schemas/VariableNavigation'
    WarningRule:
      type: object
      properties:
        warningId:
          type: string
          description: >-
            Unique identifier following the pattern `{FormID}_{name}`. Examples:
            `W4101_exemption_warning`, `CA101_high_allowances_warning`.
          example: W4101_exemption_warning
        questionId:
          type: string
          description: >-
            The question ID this warning monitors. The condition is evaluated
            against the user's answer to this question.
          example: isExempt
        condition:
          $ref: '#/components/schemas/WarningCondition'
        title:
          type: string
          description: The title/header displayed when this warning is shown.
          example: Exemption Warning
        warningText:
          type: string
          description: The warning message displayed to the user.
          example: >-
            You have claimed exemption from withholding. This must be renewed
            annually.
      description: >-
        A form-specific warning rule that fires when a condition is met.
        Warnings are disabled by default; enable them via `includedWarnings` in
        MiscConfig using the warning ID or form ID (e.g., `["W4101"]` enables
        all W-4 warnings).
    Note:
      type: object
      properties:
        htmlType:
          type: string
          enum:
            - INPUT
            - SELECT
            - TEXTAREA
            - PARAGRAPH
            - UNORDERED_LIST
            - TABLE
            - IMAGE
        suggestedPlacement:
          type: string
          enum:
            - ABOVE_QUESTION
            - BELOW_QUESTION
            - ABOVE_ALL_QUESTIONS
            - BELOW_ALL_QUESTIONS
        copyKey:
          type: string
          description: >-
            Stable key identifying this note for copy customization. Format:
            {formId}.{questionId}.note.{noteId} for a note attached to a
            Question, or {formId}.{questionSetId}.note.{noteId} for a note
            attached directly to a QuestionSet. Omitted when not applicable.
        noteId:
          type: string
          description: >-
            Optional semantic identifier for this note. Always null in API
            responses unless the form author called withId() when building it;
            the {noteId} segment of copyKey falls back to this note's zero-based
            position within its parent's notes list when no semantic identifier
            was set.
      discriminator:
        propertyName: htmlType
        mapping:
          IMAGE:
            $ref: '#/components/schemas/Image'
          PARAGRAPH:
            $ref: '#/components/schemas/Paragraph'
          TABLE:
            $ref: '#/components/schemas/Table'
          UNORDERED_LIST:
            $ref: '#/components/schemas/UnorderedList'
    ValidationError:
      type: object
      properties:
        field:
          type: string
        message:
          type: string
        rejectedValue:
          type: string
    Required:
      type: object
      properties:
        whenRequired:
          type: string
          enum:
            - ALWAYS
            - DEPENDENT
            - NEVER
    QuestionOption:
      type: object
      properties:
        id:
          type: string
        label:
          type: string
        value:
          type: object
        formsToComplete:
          type: array
          items:
            $ref: '#/components/schemas/Form'
        copyKey:
          type: string
          description: >-
            Stable key identifying this option's label for copy customization.
            Format: {formId}.{questionId}.option.{optionId} for options with a
            semantic ID, or {formId}.{questionId}.option.{index} for boolean
            (yes/no) options only. Omitted when not applicable.
    MultiSelectionQuestionOption:
      type: object
      properties:
        id:
          type: string
        label:
          type: string
        copyKey:
          type: string
          description: >-
            Stable key identifying this option's label for copy customization.
            Format: {formId}.{questionId}.option.{optionId}. Omitted when not
            applicable.
    Calculation:
      type: object
      properties:
        formula:
          type: string
        roundingMode:
          type: string
          enum:
            - CEILING
            - FLOOR
            - HALF_UP
            - DOWN
            - UP
        scale:
          type: integer
          format: int32
    ConstantNavigation:
      type: object
      allOf:
        - $ref: '#/components/schemas/Navigation'
        - type: object
          properties:
            navigationMapping:
              $ref: '#/components/schemas/NavigationMapping'
    VariableNavigation:
      type: object
      allOf:
        - $ref: '#/components/schemas/Navigation'
        - type: object
          properties:
            questionSetId:
              type: string
            questionId:
              type: string
            navigationMappings:
              type: object
              additionalProperties:
                $ref: '#/components/schemas/NavigationMapping'
    WarningCondition:
      type: object
      properties:
        formula:
          type: string
          description: >-
            MathJS expression for complex conditions. Use question IDs as
            variables. Examples: `isExempt == 'noTaxLiability'`,
            `worksheetB_line8 > 200`, `amount > 0 && status == 'SINGLE'`.
          example: isExempt == 'noTaxLiability'
        string:
          type: string
          description: >-
            Exact case-sensitive string match. Use for radio buttons, dropdowns,
            or text inputs. Examples: `SINGLE`, `noTaxLiability`, `optOut`.
          example: SINGLE
        integer:
          type: integer
          description: >-
            Exact whole number match. Use for counts or whole-dollar amounts.
            For threshold comparisons (>, <), use `formula` instead. Examples:
            `0`, `10`.
          format: int32
          example: 0
        floatVal:
          type: number
          description: >-
            Exact decimal match. Use for dollar amounts with cents or
            percentages. Examples: `0.0`, `100.50`.
          format: double
          example: 0
        bool:
          type: boolean
          description: >-
            Exact boolean match. Use for yes/no questions or checkboxes (checked
            = true, unchecked = false).
          example: true
      description: >-
        Defines when a warning fires. Exactly one field should be set. Condition
        types vary between warnings: one may check a boolean, another may
        compare integers, another may use a formula with multiple questions.
    Image:
      type: object
      allOf:
        - $ref: '#/components/schemas/Note'
        - type: object
          properties:
            href:
              type: string
            optionalLabel:
              type: string
    Paragraph:
      type: object
      allOf:
        - $ref: '#/components/schemas/Note'
        - type: object
          properties:
            text:
              type: string
            href:
              type: string
            hrefText:
              type: string
    Table:
      type: object
      allOf:
        - $ref: '#/components/schemas/Note'
        - type: object
          properties:
            optionalLabel:
              type: string
            headerPlacement:
              type: string
              enum:
                - ROW
                - COLUMN
            headers:
              type: array
              items:
                $ref: '#/components/schemas/TableHeader'
            rows:
              type: array
              items:
                $ref: '#/components/schemas/TableRow'
    UnorderedList:
      type: object
      allOf:
        - $ref: '#/components/schemas/Note'
        - type: object
          properties:
            optionalLabel:
              type: string
            listItems:
              type: array
              items:
                type: string
            listItemCopyKeys:
              type: array
              items:
                type: string
    Form:
      type: object
      properties:
        id:
          $ref: '#/components/schemas/WithholdingForm'
        name:
          type: string
        title:
          type: string
        formVersion:
          type: string
        formLocality:
          type: string
          description: States and territories
        formType:
          type: string
          enum:
            - CANADA_RESIDENT
            - RESIDENT
            - NON_RESIDENT
            - RESIDENT_OUT_OF_STATE
            - EXEMPT
            - MILITARY
            - EIC
            - LOCAL
            - PENSION
            - EXEMPT_STUDENT
            - EXEMPT_NATIVE_AMERICAN
            - NONRESIDENT_EMPLOYER
            - RESIDENT_ALLOWANCE_ADJ
            - NON_RESIDENT_FORT_CAMPBELL
            - EXEMPT_TAX_CREDIT
            - RESIDENT_PITTSBURGH
            - NON_RESIDENT_PITTSBURGH
            - TAX_ADJ
            - EXEMPT_MILITARY_SPOUSE
        recommended:
          type: boolean
        initialQuestionSet:
          type: string
    NavigationMapping:
      type: object
      properties:
        nextQuestionSetId:
          type: string
        hasMoreQuestions:
          type: boolean
        perjuryStatement:
          type: string
          description: >-
            The perjury statement, which may contain templates with formulas
            that must be evaluated by the client. See the [Dynamic perjury
            statements](https://docs.symmetry.com/spf/api/interpreting-responses#dynamic-perjury-statements)
            for more details on evaluating formulas.
    TableHeader:
      type: object
      properties:
        textValue:
          type: string
        headerIndex:
          type: integer
          format: int32
        copyKey:
          type: string
    TableRow:
      type: object
      properties:
        cells:
          type: array
          items:
            $ref: '#/components/schemas/TableCell'
        rowIndex:
          type: integer
          format: int32
    WithholdingForm:
      type: string
      description: >-
        Form IDs - Use the /getAllFormIds endpoint to get all withholding form
        IDs available
    TableCell:
      type: object
      properties:
        textValue:
          type: string
        calculation:
          $ref: '#/components/schemas/Calculation'
        isCalculated:
          type: boolean
        columnIndex:
          type: integer
          format: int32
        copyKey:
          type: string
  securitySchemes:
    jwtToken:
      type: http
      scheme: bearer
      bearerFormat: JWT

````