---
openapi: 3.0.3
info:
  title: TM Next-Gen — Walk Creator
  description: |
    OpenAPI for the Walk Creator APIs (`walk-creator/v1/...`).

    Same server base URL as Walk execution and Task execution specs: `/MYWORK/service/`.
    Example: `https://fs3.reflexisinc.com/MYWORK/service/walk-creator/v1/attributes`.

    These endpoints are **not** mounted under `/api/v2/` (unlike some SWA controllers such as
    `/api/v2/formAttr`). Use `/MYWORK/service/walk-creator/v1/...` only.

    Query fields are **snake_case**; the server normalizes to camelCase internally.

    **Authentication:** All endpoints require the `X-reflexis-csrf-token-X` header carrying a valid
    session token. Session-derived identity fields (`domain_id`, `user_id`, `unit_id`, etc.) are
    **not** accepted as request parameters — they are resolved from the validated session.

    Companion spec: `walk-execution/next-gen-walk-execution-api.yaml` (walk instance execution).
    Error codes and structured envelopes follow the same Walk API conventions documented there.

    ---

    ## Common Response Envelope

    Successful responses use `status: OK` and a payload field named for the resource
    (e.g. `walk_creator_attributes`), not a generic `message` field.

    On **HTTP 200** application-level failure:

    ```json
    { "status": "ER", "error": "<details>" }
    ```

    On **HTTP 4xx/5xx** (structured validation / server error):

    ```json
    { "status": "ER", "errorCode": "E110", "response": "<localized message>" }
    ```
  version: 1.0.0
  contact:
    name: API Support
    email: noreply@zebra.com
servers:
- url: /MYWORK/service/
  description: Application context + Pulse servlet (typical deployment)
- url: https://fs3.reflexisinc.com/MYWORK/service/
  description: Example development host
- url: http://localhost:3001/MYWORK/service/
  description: Local CORS proxy — npm run cors-proxy
- url: https://dev-api.zebra.com/
  description: Dev API APIGEE
- url: https://api.zebra.com/
  description: API APIGEE
tags:
- name: WalkCreatorAttributes
  description: Walk template creator configuration attributes for mobile and web clients
- name: WalkCreatorPresets
  description: Walk question option preset operations for creator flows
- name: WalkCreatorCustomNotifications
  description: Walk template custom notification (post-action) CRUD for creator flows
- name: WalkCreatorTemplateConversion
  description: Convert classic walk templates (IS_MODERN_UI=N) to modern walk templates (IS_MODERN_UI=Y)
- name: WalkCreatorTemplateFeatures
  description: Update individual walk template feature flags (permission attributes) during creator flows
- name: WalkCreatorTemplateHistory
  description: Retrieve walk template history from MODEL_STATE_HISTORY using model_id and txn_category
- name: WalkCreatorTemplateInfo
  description: Retrieve walk template creator and last-updated metadata for the Info tab
- name: WalkCreatorTemplateApprovers
  description: Walk category Approvers (template reviewers of permit type REVIEWER only)
- name: WalkCreatorExternalAttributes
  description: Walk template external attribute save for creator flows
- name: WalkCreatorQuestions
  description: Walk question attachment operations for creator flows
- name: WalkCreatorTemplateImportExport
  description: Bulk import and export of walk/form templates (ZIP)
- name: WalkCreatorTemplateList
  description: Retrieve and search walk template lists — list by category, recent, all, search, and full template data
- name: WalkCreatorTemplateCRUD
  description: Create and update walk templates (add new template, update existing template)
- name: WalkCreatorTemplateLifecycle
  description: Walk template lifecycle — edit (open for editing), restore, submit for approval, copy, duplicate, delete
- name: WalkCreatorTemplateDetails
  description: Save supplementary template data — details, scores, print settings, translations, paste question/group
- name: WalkCreatorTemplateRoles
  description: Walk template access roles (get/save permission data) and user profile list
- name: WalkCreatorTemplateCleanup
  description: Remove scoring data, follow-up data, follow-up tasks, and linked-walk data from a template
- name: WalkCreatorBank
  description: Question bank retrieval for walk creator flows
- name: WalkCreatorCategory
  description: Walk category CRUD for creator flows
- name: WalkCreatorDistribution
  description: Template distribution data, attributes, units, and hierarchy for creator flows
- name: WalkCreatorFeedback
  description: Creator feedback form save and state
- name: WalkCreatorPermission
  description: Walk permit / group permission operations for creator flows
- name: WalkCreatorLogic
  description: Logic rules, skips, notifications, and tasks for walk creator
- name: WalkCreatorQuestionGroup
  description: Question group and question CRUD plus group permissions for creator flows
- name: WalkCreatorPreset
  description: Question-options preset CRUD for walk creator (reorder already documented)
- name: WalkCreatorReviewer
  description: Reviewer permit data get/save for walk creator templates
- name: WalkCreatorSchedule
  description: Walk template repeating schedule retrieve and save for creator flows
- name: WalkCreatorSkips
  description: Walk question/category skip logic — save, validate, allow-groups, question-level, delete, and category variable
    matrix
- name: WalkCreatorViolations
  description: Walk violation projects, tasks, masters, linked survey categories, form templates, and config
- name: WalkCreatorValidation
  description: Walk template validation helpers including review summary
security:
- AuthTokenHeader: []
components:
  securitySchemes:
    AuthTokenHeader:
      type: apiKey
      in: header
      name: X-reflexis-csrf-token-X
      description: |
        Session authentication token validated server-side against the user session store.
        Required on **every** request. Absence returns HTTP 400; invalid/expired token returns HTTP 401.
  schemas:
    WalkApiErrorResponse:
      type: object
      description: |
        Error envelope shape depends on how the error is produced:

        - **HTTP 200** — business or validation failure after the request is accepted:
          `{ "status": "ER", "error": "<string or JSON>" }` (no `errorCode`).
        - **HTTP 4xx/5xx** — structured API error:
          `{ "status": "ER", "errorCode": "<code>", "response": "<localized message>" }`.
      properties:
        status:
          type: string
          enum:
          - ER
        errorCode:
          type: string
          description: Structured error code for HTTP 4xx/5xx responses.
        response:
          type: string
          description: Human-readable message when `errorCode` is present (HTTP 4xx/5xx responses).
        error:
          description: Payload for HTTP 200 error bodies (string, array, or object).
          oneOf:
          - type: string
          - type: array
            items: {}
          - type: object
    WalkCreatorAttributesPayload:
      type: object
      description: |
        Walk creator attribute map. Response keys use **snake_case** (next-gen convention).
        `template_setup` and `default_external` values are **URL-encoded** JSON strings (same as legacy `evaluateAttributes`).
        `default_external` is translated on decoded JSON before encoding; `desc` fields use `resourceKey` and session `lang_code`.
      properties:
        walk_category_add:
          type: string
          description: Whether the user may add walk categories (`Y` / `N`). Present when `model_type` is supplied.
          example: Y
        template_setup:
          type: string
          description: URL-encoded JSON string of all `TEMPLATE_SETUP` system-code attributes for the domain.
        default_external:
          type: string
          description: URL-encoded JSON string of default external walk matrix parameters (translated `desc`, then encoded).
      additionalProperties:
        type: string
    WalkCreatorAttributesSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        walk_creator_attributes:
          $ref: '#/components/schemas/WalkCreatorAttributesPayload'
      required:
      - status
      - walk_creator_attributes
    WalkCreatorPresetReorderSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        response:
          type: string
          example: Presets reordered successfully.
      required:
      - status
      - response
    WalkCreatorCustomNotificationItem:
      type: object
      description: |
        Custom notification detail row from `MODEL_POST_ACT_DETAILS`.
        Response keys use **snake_case** (next-gen convention).
      properties:
        domain_id:
          type: integer
        model_id:
          type: string
        rule_id:
          type: string
        post_action_id:
          type: integer
        sequence_no:
          type: integer
        action_name:
          type: string
        message_type:
          type: string
        disposition_type:
          type: string
        category:
          type: string
        parameters:
          type: object
          additionalProperties: true
        created_by:
          type: string
        creation_time:
          type: string
          format: date-time
    WalkCreatorCustomNotificationListPayload:
      type: object
      properties:
        custom_notification_list:
          type: array
          items:
            $ref: '#/components/schemas/WalkCreatorCustomNotificationItem'
      required:
      - custom_notification_list
    WalkCreatorCustomNotificationListSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        custom_notifications:
          $ref: '#/components/schemas/WalkCreatorCustomNotificationListPayload'
      required:
      - status
      - custom_notifications
    WalkCreatorCustomNotificationSavedObject:
      type: object
      description: |
        Save/update result. Only fields that add context beyond `post_act_details` are included
        at the top level — `domain_id`, `model_id`, `post_action_id`, and `sequence_no` are
        available inside `post_act_details` and are not duplicated here.
      properties:
        rule_id:
          type: string
          description: The rule scope requested by the caller (`-1` for upon-completion).
        post_act_header_rule_id:
          type: string
          description: The rule id stored on the `MODEL_POST_ACT_HEADER` row (may differ from `rule_id` for the default scope).
        is_update:
          type: boolean
          description: '`true` when an existing row was updated; `false` for a newly created row.'
        post_act_details:
          $ref: '#/components/schemas/WalkCreatorCustomNotificationItem'
      required:
      - rule_id
      - post_act_header_rule_id
      - is_update
    WalkCreatorCustomNotificationSaveSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        custom_notification:
          $ref: '#/components/schemas/WalkCreatorCustomNotificationSavedObject'
      required:
      - status
      - custom_notification
    WalkCreatorCustomNotificationDeletedObject:
      type: object
      description: Summary of the deleted custom notification record.
      properties:
        domain_id:
          type: integer
        model_id:
          type: string
        post_action_id:
          type: integer
        rule_id:
          type: string
          description: The rule scope the deleted row belonged to.
        header_deleted:
          type: boolean
          description: |
            `true` when the `MODEL_POST_ACT_HEADER` for the rule was also deleted
            because no details remained after this deletion.
        logic_rule_id:
          type: string
          description: |
            Present when the `post_action_id` was successfully unlinked from
            `LOGIC_RULE.custom_notification_id_list`.
    WalkCreatorCustomNotificationDeleteSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        deleted_custom_notification:
          $ref: '#/components/schemas/WalkCreatorCustomNotificationDeletedObject'
      required:
      - status
      - deleted_custom_notification
    ConvertedTemplatePayload:
      type: object
      description: |
        Template list entry returned under `response.modelList[]` after a successful
        classic-to-modern walk template conversion. Shape is identical to the
        `duplicateTemplate` API response.
      properties:
        modelId:
          type: string
          description: |
            For `CONVERT`: the original `MODEL_ID`, now pointing to the modern template.
            For `DUPLICATE_AS_MODERN`: the newly generated `MODEL_ID` for the modern copy.
          example: FORM_123
        modelName:
          type: string
        status:
          type: string
          description: Final template status (`D` for Draft, `A` for Active).
          example: A
        isModernUi:
          type: string
          enum:
          - Y
          description: Always `Y` — the resulting template is modern.
      additionalProperties: true
    WalkCreatorConvertSuccessResponse:
      type: object
      description: |
        Follows the same envelope as the legacy `duplicateTemplate` API.
        The converted/duplicated template appears in `response.modelList`.
      properties:
        status:
          type: string
          enum:
          - OK
        response:
          type: object
          properties:
            modelList:
              type: array
              items:
                $ref: '#/components/schemas/ConvertedTemplatePayload'
      required:
      - status
      - response
    WalkCreatorQuestionLevelMigrationPayload:
      type: object
      description: |
        Migration summary returned when question-level skips/tasks are normalized to logic rules.
        Response keys use snake_case in the API envelope.
      properties:
        migrated:
          type: boolean
          description: |
            `true` only when at least one `LOGIC_RULE` was successfully created or updated and
            the linked question-level `question_id` values were cleared; `false` for no-op or
            when question-level records could not be linked to logic rules.
        skips_cleared:
          type: integer
          description: Number of `SKIP_HEADER` rows whose `question_id` was reset to `0`.
        tasks_cleared:
          type: integer
          description: Number of `WALK_VIOLATION_TASK` rows whose `question_id` was reset to `0`.
        logic_rules_created:
          type: integer
          description: Number of new `LOGIC_RULE` documents inserted.
        logic_rules_updated:
          type: integer
          description: Number of existing `LOGIC_RULE` documents updated with merged skip/task ids.
      required:
      - migrated
      - skips_cleared
      - tasks_cleared
      - logic_rules_created
      - logic_rules_updated
    WalkCreatorQuestionLevelMigrationSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        response:
          $ref: '#/components/schemas/WalkCreatorQuestionLevelMigrationPayload'
      required:
      - status
      - response
    WalkCreatorQuestionAppliedLogicRule:
      type: object
      description: Summary of one QUESTION_BASED rule that names this question in its conditions.
      properties:
        rule_id:
          type: string
          example: '24'
        rule_name:
          type: string
          example: Rule 24
        action_types:
          type: array
          description: |
            Fixed order when present: `SKIP`, `TASK`, `NOTIFICATION`.
            Only types that exist on the rule are included (may be empty).
          items:
            type: string
            enum:
            - SKIP
            - TASK
            - NOTIFICATION
      required:
      - rule_id
      - rule_name
      - action_types
    WalkCreatorQuestionAppliedLogicItem:
      type: object
      description: |
        Applied-logic indicator for one question. Unfiltered responses include only
        questions with `has_logic: true`. A filtered request may return `has_logic: false`.
      properties:
        group_id:
          type: string
          example: GROUP_1
        question_id:
          type: integer
          example: 12
        has_logic:
          type: boolean
          description: When `true`, show the questionnaire outline indicator (dot).
        rules:
          type: array
          description: Popover contents / logic types attached to this condition question.
          items:
            $ref: '#/components/schemas/WalkCreatorQuestionAppliedLogicRule'
      required:
      - group_id
      - question_id
      - has_logic
      - rules
    WalkCreatorQuestionAppliedLogicSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        question_applied_logic:
          type: array
          items:
            $ref: '#/components/schemas/WalkCreatorQuestionAppliedLogicItem'
      required:
      - status
      - question_applied_logic
    WalkCreatorTemplateExportFileItem:
      type: object
      properties:
        path:
          type: string
          description: Absolute server path to the generated ZIP file.
        name:
          type: string
          description: ZIP file name (e.g. `FORM_<epoch>.zip`).
      required:
      - path
      - name
    WalkCreatorTemplateExportPayload:
      type: object
      description: |
        Export result from `ImportExportService.exportAllModel`.
        Keys are snake_cased in the next-gen envelope (`file_path`, `file_list`).
      properties:
        file_path:
          type: string
          description: Directory containing the export ZIP before client download.
        file_list:
          type: array
          items:
            $ref: '#/components/schemas/WalkCreatorTemplateExportFileItem'
      required:
      - file_path
      - file_list
    WalkCreatorTemplateExportSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        template_export:
          $ref: '#/components/schemas/WalkCreatorTemplateExportPayload'
      required:
      - status
      - template_export
    WalkCreatorTemplateImportModelItem:
      type: object
      description: |
        One imported template. Use these ids to open the Walk Creator editor
        (`retrieveTemplateData` / template route) without a follow-up list lookup.
      properties:
        model_id:
          type: string
          description: Newly created template `MODEL_ID` (clean id, no list brackets).
          example: FORM_55662
          pattern: ^FORM_.+
        category_id:
          type: string
          description: Category id persisted on the imported `FORM_MODEL` row.
          example: CAT_123
      required:
      - model_id
      - category_id
    WalkCreatorTemplateImportPayload:
      type: object
      description: |
        Next-gen import success payload under `template_import`.

        **Primary contract — use `models[]`:**
        each entry has clean `model_id` + `category_id` for editor navigation.

        **Single-import convenience:** when exactly one template is imported, the same
        ids are also mirrored at the top level as `model_id` / `category_id`.
        For multi-import those top-level fields are omitted; iterate `models`.
      properties:
        models:
          type: array
          minItems: 1
          description: Imported templates in package order.
          items:
            $ref: '#/components/schemas/WalkCreatorTemplateImportModelItem'
        model_id:
          type: string
          description: |
            Present only when `models.length === 1`. Same value as `models[0].model_id`.
          example: FORM_55662
        category_id:
          type: string
          description: |
            Present only when `models.length === 1`. Same value as `models[0].category_id`.
          example: CAT_123
        formula_id:
          description: Optional formula ids created during import (when formulas were copied).
          oneOf:
          - type: array
            items:
              type: string
          - type: string
      required:
      - models
      additionalProperties: false
    WalkCreatorTemplateImportSuccessResponse:
      type: object
      description: Successful next-gen template import envelope.
      properties:
        status:
          type: string
          enum:
          - OK
        template_import:
          $ref: '#/components/schemas/WalkCreatorTemplateImportPayload'
      required:
      - status
      - template_import
    WalkCreatorTemplateHistoryItem:
      type: object
      additionalProperties: true
      description: Existing history detail object returned from MODEL_STATE_HISTORY mapping.
    WalkCreatorTemplateHistoryPayload:
      type: object
      properties:
        history_details:
          type: array
          items:
            $ref: '#/components/schemas/WalkCreatorTemplateHistoryItem'
        info_msg:
          type: string
      oneOf:
      - required:
        - history_details
      - required:
        - info_msg
    WalkCreatorTemplateHistorySuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        walk_template_history:
          $ref: '#/components/schemas/WalkCreatorTemplateHistoryPayload'
      required:
      - status
      - walk_template_history
    WalkCreatorTemplateInfoPayload:
      type: object
      description: Walk template metadata for the creator Info tab. All keys use snake_case in JSON responses.
      properties:
        created_by:
          type: string
          description: User id of the template creator.
          example: user1
        created_by_name:
          type: string
          description: Display name of the template creator from perm_description.
          example: Jane Doe
        creation_time:
          type: integer
          format: int64
          description: Template creation time as epoch milliseconds (UTC).
          example: 1723891200000
        last_updated_by:
          type: string
          description: User id of the last updater (persisted on FormModel, or latest MODEL_STATE_HISTORY when either updater
            field is blank).
          example: user2
        last_updated_by_name:
          type: string
          description: Display name of the last updater (persisted on FormModel, or latest MODEL_STATE_HISTORY when either
            updater field is blank).
          example: John Smith
        last_updated_time:
          type: integer
          format: int64
          description: Last update time as epoch milliseconds (UTC). Uses latest MODEL_STATE_HISTORY creation_time when either
            updater field is blank and history exists; otherwise persisted value or zero.
          example: 1723977600000
        form_unique_id:
          type: string
          example: abc-123
        form_access_key:
          type: string
          example: key-456
        model_id:
          type: string
          example: FORM_123
        form_trace_id:
          type: integer
          format: int64
          example: 987654321
      required:
      - created_by
      - created_by_name
      - creation_time
      - last_updated_by
      - last_updated_by_name
      - last_updated_time
      - form_unique_id
      - form_access_key
      - model_id
      - form_trace_id
    WalkCreatorTemplateInfoSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        walk_template_info:
          $ref: '#/components/schemas/WalkCreatorTemplateInfoPayload'
      required:
      - status
      - walk_template_info
    WalkCreatorExternalAttributeItem:
      type: object
      description: External attribute row stored for a walk template.
      properties:
        key:
          type: string
          description: Attribute identifier.
        name:
          type: string
          description: Attribute display name.
        value:
          type: string
          description: Attribute value.
      required:
      - key
      - name
      - value
    WalkCreatorExternalAttributesPayload:
      type: object
      properties:
        external_attribute:
          type: array
          items:
            $ref: '#/components/schemas/WalkCreatorExternalAttributeItem'
      required:
      - external_attribute
    WalkCreatorExternalAttributesSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        external_attributes:
          $ref: '#/components/schemas/WalkCreatorExternalAttributesPayload'
      required:
      - status
      - external_attributes
    WalkCreatorTemplateFeaturePayload:
      type: object
      description: |
        Partial `PERMISSION_ATTR` JSON object. Send **only** the key(s) being changed;
        all other permission attributes on the template are preserved.

        Values are `Y` (enabled) or `N` (disabled). Common keys:

        | Key | Feature |
        |-----|---------|
        | `allowScoring` | Scoring |
        | `showModelPoint` | Walk score on summary |
        | `showGroupPoint` | Group score on summary |
        | `showSummaryPoint` | Summary score (often derived from walk/group score) |
        | `allowFollowUpTask` | Automated follow-up tasks |
        | `allowManualTask` | Manual follow-up tasks |
        | `futureWalk` | Enable future walk |
        | `externalWalk` | Link walk to project |
        | `enableQuestionAudit` | Edit history |
        | `showRecall` | Recall walk |
        | `showPrevResponse` | Response history |
        | `offlineFlag` | Offline walk |
        | `showGroupPermission` | Collaborative walk |
        | `enableAnnotation` | Annotations |
        | `enableSignature` | Require signature |
        | `adhocWalk` | Ad-hoc walk |
        | `allowDiscard` | Discard approved walk |
        | `walkNameEditable` | Edit walk name |
        | `autoUnclaim` | Auto unclaim |

        Some features disable conflicting keys when enabled (for example `externalWalk=Y`
        may set `offlineFlag`, `showGroupPermission`, and `showPrevResponse` to `N`).
      additionalProperties:
        type: string
        enum:
        - Y
        - N
      example:
        showRecall: Y
    WalkCreatorUpdatedTemplatePayload:
      type: object
      description: |
        Updated walk template returned under `template` after a successful feature update.
        Same shape as a `templateList[]` entry from legacy template retrieve APIs; response
        keys use **snake_case** (next-gen convention).
      additionalProperties: true
    WalkCreatorTemplateFeatureUpdateSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        template:
          $ref: '#/components/schemas/WalkCreatorUpdatedTemplatePayload'
      required:
      - status
      - template
    WalkCreatorTemplateApprover:
      type: object
      description: |
        One walk-category Approver. Stored as a template reviewer of permit type REVIEWER
        (`permit_type` = `R`, `txn_category` = `C`). Authorize (`C`) and Approver (`A`)
        permit rows are not part of this resource.
      properties:
        domain_id:
          type: integer
        txn_category:
          type: string
          enum:
          - C
          description: Creation transaction. Category Approvers are always `C`.
        permit_type:
          type: string
          enum:
          - R
          description: REVIEWER. This API never returns `C` (authorize) or `A` (approver).
        entity_id:
          type: string
          description: Walk template category id.
        entity_name:
          type: string
          description: Walk template category name.
        permit_sequence:
          type: integer
          description: 1-based order on the Approvers screen.
        user_id:
          type: string
        profile_id:
          type: string
        department_id:
          type: string
        unit_id:
          type: string
        unit_level:
          type: integer
        response_time:
          type: string
          description: Response window, for example `1440M`.
          example: 1440M
        created_by:
          type: string
        creation_time:
          type: integer
          format: int64
          description: UTC creation time in epoch milliseconds.
        permit_desc:
          type: string
          description: JSON string of display labels (profile, department, unit, org level).
        model_type:
          type: string
          description: Category model type. `W` for a walk category.
          example: W
      required:
      - txn_category
      - permit_type
      - entity_id
      - permit_sequence
      - model_type
    WalkCreatorTemplateApproversSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        template_approvers:
          type: array
          items:
            $ref: '#/components/schemas/WalkCreatorTemplateApprover'
      required:
      - status
      - template_approvers
    WalkCreatorTemplateApproversDeleteSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        deleted_template_approvers:
          type: array
          description: REVIEWER rows that were removed.
          items:
            $ref: '#/components/schemas/WalkCreatorTemplateApprover'
      required:
      - status
      - deleted_template_approvers
    WalkTemplateListItem:
      type: object
      description: |
        Single walk template entry as returned in a list response (`templates.template_list[]`).
        Keys use **snake_case** (next-gen convention). Fields vary by `view_type` / projection;
        `additionalProperties` covers less-common fields.
      properties:
        model_id:
          type: string
          example: FORM_55740
        model_name:
          type: string
          example: Store Walk
        model_type:
          type: string
          example: W
        category_id:
          type: string
          example: '1787735704510'
        category_name:
          type: string
          example: Safety
        domain_id:
          type: integer
          example: 170010099
        status:
          type: string
          description: Template status code, e.g. `D` (draft), `A` (active), `R` (retired).
          example: A
        txn_category:
          type: string
          description: Transaction category — `C` for creation template.
          example: C
        model_description:
          type: string
        form_unique_id:
          type: string
          example: WALK_29132894
        form_access_key:
          type: string
        form_trace_id:
          type: integer
          format: int64
        reference_key:
          type: integer
        model_logo:
          type: string
          example: default.png
        logo_path:
          type: string
        last_updated_time:
          type: string
          description: Last-updated time string (server locale). Epoch form available via `template_data`.
        user_id:
          type: string
          description: Owner/creator user id.
        read_only_flag:
          type: string
          enum:
          - Y
          - N
        lang_code:
          type: string
          example: en_US
        attachment_folder:
          type: string
        file_key:
          type: string
        is_modern_ui:
          type: string
          enum:
          - Y
          - N
          description: '`Y` for modern walk templates (Walk Creator); `N` for classic.'
      additionalProperties: true
    WalkTemplatesPayload:
      type: object
      description: Payload under `templates` key for list/recent/all/search responses.
      properties:
        template_list:
          type: array
          items:
            $ref: '#/components/schemas/WalkTemplateListItem'
        total_count:
          type: integer
          description: Total matching templates across all pages.
        total_pages:
          type: integer
          description: Total pages for the given page size.
        last_fetch_time:
          type: integer
          format: int64
          description: Server-side fetch time, epoch milliseconds UTC.
      required:
      - template_list
      - last_fetch_time
    WalkTemplatesListSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        templates:
          $ref: '#/components/schemas/WalkTemplatesPayload'
      required:
      - status
      - templates
    WalkTemplateObject:
      type: object
      description: |
        Walk template object returned by add / update / edit / restore / copy / duplicate / submit operations.
        Shape mirrors the legacy `FORM_MODEL` document projected to the template-list projection columns;
        exact fields depend on the operation. All keys use **snake_case**.
      additionalProperties: true
    WalkTemplateSuccessResponse:
      type: object
      description: Success response for operations returning a single template (add, update, edit, restore, copy, duplicate,
        submit, scores, print, paste, remove-*).
      properties:
        status:
          type: string
          enum:
          - OK
        template:
          $ref: '#/components/schemas/WalkTemplateObject'
      required:
      - status
      - template
    WalkTemplateDeleteSuccessResponse:
      type: object
      description: |
        Deletion success response. The `template` field is a localized string message
        (not an object), e.g. `"Questionnaire Deleted Successfully"`.
      properties:
        status:
          type: string
          enum:
          - OK
        template:
          type: string
          description: Localized deletion success message.
          example: Questionnaire Deleted Successfully
      required:
      - status
      - template
    WalkTemplateDataSuccessResponse:
      type: object
      description: Full template structure including groups, questions, skip logic, scores, and task configuration.
      properties:
        status:
          type: string
          enum:
          - OK
        template_data:
          type: object
          description: Full `FORM_MODEL` document with nested groups/questions.
          additionalProperties: true
      required:
      - status
      - template_data
    WalkAccessRolesSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        access_roles:
          type: object
          description: Permission data for the walk template (profile/department/unit rows).
          additionalProperties: true
      required:
      - status
      - access_roles
    WalkUserProfilesSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        user_profiles:
          type: object
          description: User profile list for access role assignment (from `getUserProfileList`).
          additionalProperties: true
      required:
      - status
      - user_profiles
    WalkTranslationSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        translation:
          type: object
          description: Translation data payload (save result or retrieved translation map).
          additionalProperties: true
      required:
      - status
      - translation
    WalkCreatorBankQuestionsSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        bank_questions:
          description: Bank question payload from BankService.getBankQuestions
          additionalProperties: true
      required:
      - status
      - bank_questions
    WalkCreatorCategorySuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        category:
          description: Single category payload (add/update/delete)
          additionalProperties: true
      required:
      - status
      - category
    WalkCreatorCategoriesSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        categories:
          description: Category list/retrieve payload
          additionalProperties: true
      required:
      - status
      - categories
    WalkCreatorDistributionSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        distribution:
          description: Distribution data payload
          additionalProperties: true
      required:
      - status
      - distribution
    WalkCreatorDistributionListSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        distribution_list:
          description: Distribution list payload
          additionalProperties: true
      required:
      - status
      - distribution_list
    WalkCreatorDistributionAttributesSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        distribution_attributes:
          description: Distribution attribute list payload
          additionalProperties: true
      required:
      - status
      - distribution_attributes
    WalkCreatorAttributeUnitsSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        attribute_units:
          description: Attribute units payload
          additionalProperties: true
      required:
      - status
      - attribute_units
    WalkCreatorUnitHierarchySuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        unit_hierarchy:
          description: Unit hierarchy payload
          additionalProperties: true
      required:
      - status
      - unit_hierarchy
    WalkCreatorFeedbackSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        feedback:
          description: Feedback save / decide-later payload
          additionalProperties: true
      required:
      - status
      - feedback
    WalkCreatorFeedbackStateSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        feedback_state:
          description: Feedback state payload
          additionalProperties: true
      required:
      - status
      - feedback_state
    WalkCreatorPermissionsSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        permissions:
          description: Walk permit data payload
          additionalProperties: true
      required:
      - status
      - permissions
    WalkCreatorGroupPermExistsSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        group_perm_exists:
          description: 1 when group permission exists (legacy successMessage(1))
          additionalProperties: true
      required:
      - status
      - group_perm_exists
    WalkCreatorLogicCountSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        logic_count:
          description: Logic count payload
          additionalProperties: true
      required:
      - status
      - logic_count
    WalkCreatorLogicRulesSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        logic_rules:
          description: Logic rule list payload
          additionalProperties: true
      required:
      - status
      - logic_rules
    WalkCreatorLogicRuleSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        logic_rule:
          description: Single logic rule payload
          additionalProperties: true
      required:
      - status
      - logic_rule
    WalkCreatorLogicSkipSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        logic_skip:
          description: Logic skip payload
          additionalProperties: true
      required:
      - status
      - logic_skip
    WalkCreatorLogicNotificationsSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        logic_notifications:
          description: Logic notification list payload
          additionalProperties: true
      required:
      - status
      - logic_notifications
    WalkCreatorLogicNotificationSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        logic_notification:
          description: Single logic notification payload
          additionalProperties: true
      required:
      - status
      - logic_notification
    WalkCreatorLogicTasksSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        logic_tasks:
          description: Logic task list payload
          additionalProperties: true
      required:
      - status
      - logic_tasks
    WalkCreatorLogicTaskSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        logic_task:
          description: Single logic task payload
          additionalProperties: true
      required:
      - status
      - logic_task
    WalkCreatorGroupSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        group:
          description: Question group payload
          additionalProperties: true
      required:
      - status
      - group
    WalkCreatorGroupPermissionsSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        group_permissions:
          description: Group permit data payload
          additionalProperties: true
      required:
      - status
      - group_permissions
    WalkCreatorQuestionSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        question:
          description: Question payload
          additionalProperties: true
      required:
      - status
      - question
    WalkCreatorPresetsSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        presets:
          description: Question-options preset list
          additionalProperties: true
      required:
      - status
      - presets
    WalkCreatorPresetSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        preset:
          description: Single question-options preset
          additionalProperties: true
      required:
      - status
      - preset
    WalkCreatorReviewersSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        reviewers:
          description: Reviewer permit data payload
          additionalProperties: true
      required:
      - status
      - reviewers
    WalkRepeatingScheduleSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        repeating_schedule:
          type: object
          description: Repeating schedule info for the template.
          additionalProperties: true
      required:
      - status
      - repeating_schedule
    WalkScheduleSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        schedule:
          type: object
          description: Saved model schedule data payload.
          additionalProperties: true
      required:
      - status
      - schedule
    WalkQuestionSkipSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        question_skip:
          type: object
          description: Saved question skip payload.
          additionalProperties: true
      required:
      - status
      - question_skip
    WalkGroupPermissionSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        group_permission:
          type: object
          description: Group permission validation result.
          additionalProperties: true
      required:
      - status
      - group_permission
    WalkAllowGroupsSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        allow_groups:
          type: object
          description: Allow-groups payload for skip targeting.
          additionalProperties: true
      required:
      - status
      - allow_groups
    WalkQuestionLevelSkipSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        question_level_skip:
          type: object
          description: Question-level skip configuration for the template.
          additionalProperties: true
      required:
      - status
      - question_level_skip
    WalkSkipSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        skip:
          type: object
          description: Skip delete result (localized success/error message envelope).
          additionalProperties: true
      required:
      - status
      - skip
    WalkCategoryVarMatrixSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        category_var_matrix:
          type: object
          description: Category/variable matrix used by skip formula designer.
          additionalProperties: true
      required:
      - status
      - category_var_matrix
    WalkViolationProjectSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        violation_project:
          type: object
          description: Violation project payload (get/save/delete).
          additionalProperties: true
      required:
      - status
      - violation_project
    WalkViolationTaskSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        violation_task:
          type: object
          description: Violation task payload (get/save).
          additionalProperties: true
      required:
      - status
      - violation_task
    WalkViolationMasterSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        violation_master:
          type: object
          description: Violation master delete result.
          additionalProperties: true
      required:
      - status
      - violation_master
    WalkLinkedSurveyCategorySuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        linked_survey_category:
          type: object
          description: Linked survey categories for violation feedback.
          additionalProperties: true
      required:
      - status
      - linked_survey_category
    WalkFormTemplatesSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        form_templates:
          type: object
          description: Form templates for a linked survey category.
          additionalProperties: true
      required:
      - status
      - form_templates
    WalkViolationConfigSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        violation_config:
          type: object
          description: Domain violation configuration.
          additionalProperties: true
      required:
      - status
      - violation_config
    WalkReviewSummarySuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
          - OK
        review_summary:
          type: object
          description: Template review/validation summary.
          additionalProperties: true
      required:
      - status
      - review_summary
  responses:
    Unauthorized:
      description: Missing or invalid `X-reflexis-csrf-token-X` session token.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/WalkApiErrorResponse'
          examples:
            missingHeader:
              summary: Header not sent
              value:
                status: ER
                errorCode: E112
                response: X-reflexis-csrf-token-X header is mandatory
            expiredToken:
              summary: Token invalid or expired
              value:
                status: ER
                errorCode: E204
                response: Invalid or expired token
    BadRequest:
      description: Invalid or missing required request parameter.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/WalkApiErrorResponse'
          example:
            status: ER
            errorCode: E110
            response: model_id is mandatory
    InternalServerError:
      description: Unexpected server-side error.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/WalkApiErrorResponse'
          example:
            status: ER
            errorCode: E500
            response: Unexpected server error.
paths:
  /walk-creator/v1/attributes:
    get:
      tags:
      - WalkCreatorAttributes
      summary: Fetch walk creator configuration attributes
      operationId: getWalkCreatorAttributes
      description: |
        Returns walk-creator attributes required to initialize the template authoring UI:

        - `walk_category_add` — permission flag derived from module functions for the given `model_type`
        - `template_setup` — template setup system codes (URL-encoded JSON string)
        - `default_external` — default external walk matrix configuration (URL-encoded JSON string, translated `desc`)

        Mirrors legacy `POST /service/formAttr/fetchAttributes` for the above keys, adapted to the
        next-gen GET + session envelope pattern used by Walk execution APIs.

        **Authentication:** `X-reflexis-csrf-token-X` required. Domain and user context are resolved
        from the session — not accepted as query parameters.

        ---

        ## Response Structure

        ```json
        {
          "status": "OK",
          "walk_creator_attributes": {
            "walk_category_add": "Y",
            "template_setup": "{ ... }",
            "default_external": "{ ... }"
          }
        }
        ```

        ---

        ## Error Scenarios

        | Scenario | HTTP Status | Message |
        |---|---|---|
        | Missing `X-reflexis-csrf-token-X` header | 400 | `X-reflexis-csrf-token-X header is mandatory` |
        | Invalid or expired token | 401 | `Invalid or expired token` |
        | Missing `model_type` | 400 | `model_type is mandatory` |
        | No attributes returned (e.g. invalid session in service) | 200 | `status: ER`, `error` string |
        | Internal server error | 500 | `Unexpected server error.` |
      parameters:
      - name: model_type
        in: query
        required: true
        description: |
          Walk model type code (e.g. `W` for walk). Used for permission evaluation (`walk_category_add`)
          and passed to the attribute service as `modelType` after snake_case normalization.
        schema:
          type: string
          example: W
      responses:
        '200':
          description: |
            Success — returns `walk_creator_attributes` object.
            Application-level errors also return HTTP 200 with `status: "ER"`.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorAttributesSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                success:
                  summary: Successful response
                  value:
                    status: OK
                    walk_creator_attributes:
                      walk_category_add: Y
                      template_setup: '[{"key":"IS_CLASSIC_UI_ENABLE","value":"Y"}]'
                      default_external: '{"W":[]}'
                error:
                  summary: Application error
                  value:
                    status: ER
                    error: Error in Fetching Walk Creator Attributes Data
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/presets/reorder:
    post:
      tags:
      - WalkCreatorPresets
      summary: Reorder question option presets
      operationId: reorderQuestionOptionsPreset
      description: |
        Reorders walk question option presets based on incoming `preset_ids`.
        API boundary accepts snake_case and normalizes to `presetIds` internally.

        **Authentication:** `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - preset_ids
              properties:
                preset_ids:
                  type: string
                  description: Comma-separated preset ids in desired order.
                  example: 11,12,13
      responses:
        '200':
          description: |
            Success returns `status: OK` and `response`.
            Application-level failures may also return HTTP 200 with `status: ER`.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorPresetReorderSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                success:
                  value:
                    status: OK
                    response: Presets reordered successfully.
                error:
                  value:
                    status: ER
                    error: Error in Reordering Question Options Presets
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/custom-notifications:
    get:
      tags:
      - WalkCreatorCustomNotifications
      summary: List custom notifications for a walk template
      operationId: getCustomNotificationList
      description: |
        Returns custom notification rows (`MODEL_POST_ACT_DETAILS`) for the given walk template.

        Mirrors legacy `POST /api/v2/logic/getCustomNotificationList`, adapted to the next-gen GET +
        session envelope pattern. When `rule_id` is omitted, the service defaults to the upon-completion
        scope (`-1`, stored as `ALL_MSG_RULE` / `-99`).

        **Authentication:** `X-reflexis-csrf-token-X` required. Domain and user context are resolved
        from the session — not accepted as query parameters.
      parameters:
      - name: model_id
        in: query
        required: true
        description: Walk template model id.
        schema:
          type: string
      - name: rule_id
        in: query
        required: false
        description: |
          Logic rule id scope. Omit or pass `-1` for upon-completion (all-message) notifications.
        schema:
          type: string
          example: '-1'
      responses:
        '200':
          description: |
            Success — returns `custom_notifications.custom_notification_list`.
            Application-level errors also return HTTP 200 with `status: "ER"`.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorCustomNotificationListSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
    post:
      tags:
      - WalkCreatorCustomNotifications
      summary: Create or update a custom notification
      operationId: saveCustomNotification
      description: |
        Creates or updates a custom notification (`MODEL_POST_ACT_HEADER` / `MODEL_POST_ACT_DETAILS`).

        Mirrors legacy `POST /api/v2/logic/saveCustomNotification`. Presence of `post_action_id`
        selects update; omission selects create (new ids are minted server-side).

        **Authentication:** `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              - action_name
              - message_type
              properties:
                model_id:
                  type: string
                rule_id:
                  type: string
                  description: Logic rule scope; defaults to upon-completion (`-1`) when omitted.
                post_action_id:
                  type: string
                  description: When present, updates the existing row; when absent, creates a new row.
                action_name:
                  type: string
                  description: URL-encoded action name.
                message_type:
                  type: string
                disposition_type:
                  type: string
                  default: EVENT_MSG
                category:
                  type: string
                parameters:
                  type: string
                  description: URL-encoded JSON object string for notification parameters.
                rule_name:
                  type: string
                  description: Optional display name for the post-action header on create.
      responses:
        '200':
          description: |
            Success — returns `custom_notification` payload.
            Application-level failures may also return HTTP 200 with `status: ER`.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorCustomNotificationSaveSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/custom-notifications/delete:
    post:
      tags:
      - WalkCreatorCustomNotifications
      summary: Delete a custom notification
      operationId: deleteCustomNotification
      description: |
        Deletes a custom notification by `post_action_id`, unlinks it from `LOGIC_RULE.custom_notification_id_list`
        when applicable, and removes the post-action header when no details remain for the rule.

        Mirrors legacy `POST /api/v2/logic/deleteCustomNotification`.

        **Authentication:** `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              - post_action_id
              properties:
                model_id:
                  type: string
                post_action_id:
                  type: string
      responses:
        '200':
          description: |
            Success — returns deletion summary under `deleted_custom_notification`.
            Application-level failures may also return HTTP 200 with `status: ER`.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorCustomNotificationDeleteSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/convert:
    post:
      tags:
      - WalkCreatorTemplateConversion
      summary: Convert a classic walk template to modern UI
      operationId: convertWalkTemplate
      description: |
        Converts a classic walk template (`IS_MODERN_UI=N`) to a modern one (`IS_MODERN_UI=Y`).

        Two conversion modes are supported via `conversion_type`:

        **`CONVERT`** — In-place ID swap:
        - The classic template is archived as `<MODEL_ID>-AR` (status `AR`).
        - A modern copy takes the exact original `MODEL_ID`, so all historical reporting and
          walk-instance data continue to reference the correct template.
        - Status mapping: the modern template inherits the same status as the source.
        - Identity fields (`formTraceId`, `formUniqueId`, `formAccessKey`, `mockTraceId`,
          `referenceKey`, `cycleNo`, `iterationTime`, `submittedTime`, `editTime`) are
          transferred to the modern template. The archive receives only the newly generated
          `formTraceId`, `formUniqueId`, and `formAccessKey` to avoid unique-key collisions.
        - `start_time` is optional; when omitted the source template's start date is used.
        - A temporary `-MD` (modern draft) suffix is used internally during the swap;
          if the conversion fails mid-way the rollback restores the original template.
        - **Not allowed** when source status is `ED` (Edit) or `WD` (Withdrawn).

        **`DUPLICATE_AS_MODERN`** — New modern template:
        - Creates a new template with an auto-generated `MODEL_ID` (status always `D`).
        - Historical reporting remains with the original classic template.
        - Optionally accepts `model_name` and `model_description` for the new copy.
        - **Not allowed** when source status is `ED` (Edit).

        **Data transformations applied in both modes:**
        - `QUESTION_TYPE='Y'` (YES_NO) is converted to `'O'` (PICK_ONE).
        - `LOGIC_RULE` documents are created from existing `SKIP_DETAILS`,
          `WALK_VIOLATION_TASK`, and `MODEL_POST_ACT_DETAILS` records.
        - `allowScoring` is set to `Y` in `PERMISSION_ATTR` when any question has
          `TOTAL_POINTS > 0`. `allowFollowUpTask` is set to `Y` when `WALK_VIOLATION_PROJECT`
          records exist for the template.

        **Authentication:** `X-reflexis-csrf-token-X` required.

        ---

        ## Success — CONVERT response

        ```json
        {
          "status": "OK",
          "response": {
            "modelList": [
              {
                "modelId": "FORM_123",
                "modelName": "My Walk Template",
                "status": "A",
                "isModernUi": "Y"
              }
            ]
          }
        }
        ```

        ## Success — DUPLICATE_AS_MODERN response

        ```json
        {
          "status": "OK",
          "response": {
            "modelList": [
              {
                "modelId": "FORM_9876",
                "modelName": "Copy of My Walk Template",
                "status": "D",
                "isModernUi": "Y"
              }
            ]
          }
        }
        ```

        ## Error Scenarios

        | Scenario | HTTP Status | Message |
        |---|---|---|
        | Missing `X-reflexis-csrf-token-X` header | 400 | `X-reflexis-csrf-token-X header is mandatory` |
        | Invalid or expired token | 401 | `Invalid or expired token` |
        | Missing `model_id` | 400 | `model_id is mandatory` |
        | Missing `conversion_type` | 400 | `conversion_type is mandatory` |
        | Template not found | 200 | `status: ER`, business error string |
        | Template already modern (`IS_MODERN_UI=Y`) | 200 | `status: ER`, business error string |
        | Source status is `ED` (Edit) — both modes | 200 | `status: ER`, `Template … is in Edit status and cannot be converted` |
        | Source status is `WD` (Withdrawn) — `CONVERT` only | 200 | `status: ER`, `Template … is Withdrawn and cannot be converted in-place; use DUPLICATE_AS_MODERN instead` |
        | Conversion failure (partial rollback) | 500 | `Unexpected server error.` |
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              - conversion_type
              properties:
                model_id:
                  type: string
                  description: |
                    `MODEL_ID` of the source classic walk template (`IS_MODERN_UI=N`).
                    Allowed for most statuses; `ED` (Edit) is blocked for both modes,
                    `WD` (Withdrawn) is blocked for `CONVERT` only.
                  example: FORM_123
                conversion_type:
                  type: string
                  enum:
                  - CONVERT
                  - DUPLICATE_AS_MODERN
                  description: |
                    `CONVERT` — in-place ID swap; classic archived as `<MODEL_ID>-AR`,
                    modern takes the original `MODEL_ID` (reporting continuity preserved).
                    `DUPLICATE_AS_MODERN` — new template with auto-generated `MODEL_ID`
                    (historical reporting stays on the old classic template).
                  example: CONVERT
                start_time:
                  type: string
                  description: |
                    `CONVERT` only. Start date for the new modern template in `yyyy-MM-dd`
                    format. **Optional** — when omitted the source template's own start date
                    is used automatically.
                  example: '2026-07-15'
                end_time:
                  type: string
                  description: |
                    `CONVERT` only. End date for the new modern template in `yyyy-MM-dd`
                    format. Optional — when omitted the source template's own end date
                    is used automatically.
                  example: '2026-12-31'
                model_name:
                  type: string
                  description: |
                    `DUPLICATE_AS_MODERN` only. Name for the new modern template.
                    Defaults to the source template name when omitted.
                model_description:
                  type: string
                  description: |
                    `DUPLICATE_AS_MODERN` only. Description for the new modern template.
                    Defaults to the source template description when omitted.
      responses:
        '200':
          description: |
            Success returns `status: OK` and `response.modelList` payload (same shape as `duplicateTemplate` API).
            Application-level failures (validation, business rule) return HTTP 200
            with `status: ER`.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorConvertSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                convertActive:
                  summary: CONVERT — Active classic template
                  value:
                    status: OK
                    response:
                      modelList:
                      - modelId: FORM_123
                        modelName: My Walk Template
                        status: A
                        isModernUi: Y
                convertDraft:
                  summary: CONVERT — Draft classic template
                  value:
                    status: OK
                    response:
                      modelList:
                      - modelId: FORM_456
                        modelName: My Walk Template
                        status: D
                        isModernUi: Y
                duplicateAsModern:
                  summary: DUPLICATE_AS_MODERN
                  value:
                    status: OK
                    response:
                      modelList:
                      - modelId: FORM_9876
                        modelName: Copy of My Walk Template
                        status: D
                        isModernUi: Y
                alreadyModern:
                  summary: Source template already modern
                  value:
                    status: ER
                    error: Template FORM_123 is already modern (IS_MODERN_UI=Y)
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/migrate-question-level-rules:
    post:
      tags:
      - WalkCreatorTemplateConversion
      summary: Migrate question-level skips and tasks to logic rules
      operationId: migrateQuestionLevelRules
      description: |
        Called immediately after a user opens a modern walk template in the Walk Creator
        (following `POST /service/api/v2/template/retrieveTemplateData`).

        Detects legacy question-level skips (`SKIP_HEADER.question_id > 0`) and tasks
        (`WALK_VIOLATION_TASK.question_id > 0`), creates or updates `LOGIC_RULE` documents,
        and resets `question_id` to `0` so they appear under Logic Rules only.

        **Preconditions:**
        - Template must have `IS_MODERN_UI=Y`.
        - Caller must have template **edit** access.

        **Idempotent:** safe to call on every template open. After the first successful run,
        no question-level records remain and the API returns `migrated: false` with zero counts.

        **Authentication:** `X-reflexis-csrf-token-X` required.

        ---

        ## Success — no-op

        ```json
        {
          "status": "OK",
          "response": {
            "migrated": false,
            "skips_cleared": 0,
            "tasks_cleared": 0,
            "logic_rules_created": 0,
            "logic_rules_updated": 0
          }
        }
        ```

        ## Success — migrated

        ```json
        {
          "status": "OK",
          "response": {
            "migrated": true,
            "skips_cleared": 2,
            "tasks_cleared": 1,
            "logic_rules_created": 1,
            "logic_rules_updated": 1
          }
        }
        ```

        ## Error scenarios

        | Scenario | HTTP Status | Message |
        |---|---|---|
        | Missing `model_id` | 400 | `model_id is mandatory` |
        | Invalid template access | 200 | `status: ER`, `Invalid Template Access` |
        | Template not found | 200 | `status: ER`, `template not found: …` |
        | Not a modern template | 200 | `status: ER`, `IS_MODERN_UI=Y required` |
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Walk template `MODEL_ID` to migrate.
                  example: FORM_123
      responses:
        '200':
          description: |
            Success returns `status: OK` and migration counts under `response`.
            Application-level failures return HTTP 200 with `status: ER`.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorQuestionLevelMigrationSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                noOp:
                  summary: No question-level records
                  value:
                    status: OK
                    response:
                      migrated: false
                      skips_cleared: 0
                      tasks_cleared: 0
                      logic_rules_created: 0
                      logic_rules_updated: 0
                migrated:
                  summary: Question-level skips/tasks migrated
                  value:
                    status: OK
                    response:
                      migrated: true
                      skips_cleared: 2
                      tasks_cleared: 1
                      logic_rules_created: 1
                      logic_rules_updated: 1
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/features:
    post:
      tags:
      - WalkCreatorTemplateFeatures
      summary: Update a single walk template feature (permission attribute)
      operationId: updateWalkTemplateFeature
      description: |
        Merges a partial `permission_attr` JSON payload into the walk template's stored
        `PERMISSION_ATTR` and returns the updated template.

        Use this endpoint when toggling one feature on the modern walk template **Features**
        screen instead of posting the full feature list via legacy `saveTemplateFeatures`.

        **Merge semantics:** only keys present in `permission_attr` are updated; all other
        permission attributes remain unchanged.

        **Side effects** (same as legacy feature save):
        - Enabling link walk (`externalWalk=Y`) may reset schedule type and clear distribution,
          reviewer, and walk-permission data when transitioning to external walk.
        - Disabling scoring or follow-up tasks triggers related cleanup via post-update processing.
        - Collaborative walk, response history, and offline walk changes may update related
          question or permission data.

        **Authentication:** `X-reflexis-csrf-token-X` required. Caller must have template edit access.

        ---

        ## Success response

        ```json
        {
          "status": "OK",
          "template": {
            "model_id": "FORM_123",
            "model_name": "Store Walk",
            "permission_attr": "{\"showRecall\":\"Y\", ...}"
          }
        }
        ```

        ## Error scenarios

        | Scenario | HTTP Status | Message |
        |---|---|---|
        | Missing `X-reflexis-csrf-token-X` header | 400 | `X-reflexis-csrf-token-X header is mandatory` |
        | Invalid or expired token | 401 | `Invalid or expired token` |
        | Missing `model_id` | 400 | `model_id is mandatory` |
        | Missing `permission_attr` | 400 | `permission_attr is mandatory` |
        | Invalid template access | 200 | `status: ER`, `Invalid Template Access` |
        | Template not found | 200 | `status: ER`, business error string |
        | Persist failure | 200 | `status: ER`, business error string |
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              - permission_attr
              properties:
                model_id:
                  type: string
                  description: Walk template `MODEL_ID` to update.
                  example: FORM_123
                permission_attr:
                  type: string
                  description: |
                    URL-encoded JSON string containing one or more permission attribute keys
                    to merge (see `WalkCreatorTemplateFeaturePayload`). Example value before
                    encoding: `{"showRecall":"Y"}`.
                  example: '{"showRecall":"Y"}'
                group_instance_name:
                  type: string
                  description: |
                    Optional. Used when `showAsWalk` in the merged permission attributes is `G`
                    (group walk display mode).
      responses:
        '200':
          description: |
            Success returns `status: OK` and the updated template under `template`.
            Application-level failures return HTTP 200 with `status: ER`.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorTemplateFeatureUpdateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                enableRecallWalk:
                  summary: Enable recall walk
                  value:
                    status: OK
                    template:
                      model_id: FORM_123
                      model_name: Store Walk
                      permission_attr: '{"showRecall":"Y"}'
                invalidAccess:
                  summary: Invalid template access
                  value:
                    status: ER
                    error: Invalid Template Access
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/questions/applied-logic:
    get:
      tags:
      - WalkCreatorQuestions
      summary: Retrieve question-based applied logic indicators
      operationId: getWalkQuestionAppliedLogic
      description: |
        Returns QUESTION_BASED logic rule summaries for questionnaire outline badges.

        - Omit `group_id` and `question_id` to receive every question that is a **condition**
          of at least one QUESTION_BASED rule (UI shows a dot when the question appears).
        - Pass **both** `group_id` and `question_id` to filter to one question. If that
          question has no applied logic, a single entry with `has_logic: false` and empty
          `rules` is returned.
        - Sending only one of `group_id` / `question_id` is a validation error.
        - When filtering, `question_id` must be a positive integer.

        Not included: advanced formula rules, Upon Completion rules, or questions that are
        only skip/task/notification **targets**.

        Replaces the former nested `appliedLogic` field on
        `POST /service/api/v2/questionGroup/retrieveQuestion` (that field is no longer returned).

        Requires template **READ** access via line-of-sight permissions.
      parameters:
      - name: model_id
        in: query
        required: true
        description: Walk template model id.
        schema:
          type: string
          example: FORM_123
      - name: group_id
        in: query
        required: false
        description: Question group id. Must be paired with `question_id` when filtering.
        schema:
          type: string
          example: GROUP_1
      - name: question_id
        in: query
        required: false
        description: |
          Question id. Must be paired with `group_id` when filtering.
          Must be a positive integer (`> 0`).
        schema:
          type: integer
          minimum: 1
          example: 12
      responses:
        '200':
          description: Applied logic indicators retrieved successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WalkCreatorQuestionAppliedLogicSuccessResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: Invalid template access
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WalkApiErrorResponse'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/questions/attachments:
    post:
      tags:
      - WalkCreatorQuestions
      summary: Save question attachments
      operationId: saveWalkQuestionAttachments
      description: |
        Saves logo, audio, info file, links, services, and attach config for an
        existing walk question without calling the full question update API.

        Mirrors legacy `POST /service/api/v2/questionGroup/saveQuestionAttachments`.

        **Authentication:** `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              - group_id
              - question_id
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                group_id:
                  type: string
                  description: Question group id.
                question_id:
                  type: integer
                  description: Question id.
                attach_config:
                  type: string
                  description: JSON string of attachment configuration.
                question_logo:
                  type: string
                  description: Existing logo JSON or empty/`undefined` to clear.
                question_audio:
                  type: string
                  description: Existing audio JSON or empty/`undefined` to clear.
                question_info:
                  type: string
                  description: JSON array of links, services, and/or existing info file metadata.
                questionLogo:
                  type: string
                  format: binary
                  description: New logo image upload (form field name `questionLogo`).
                questionAudio:
                  type: string
                  format: binary
                  description: New audio upload (form field name `questionAudio`).
                questionInfoFile:
                  type: string
                  format: binary
                  description: New info attachment upload (form field name `questionInfoFile`).
      responses:
        '200':
          description: Success or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - type: object
                  properties:
                    status:
                      type: string
                      example: OK
                    question:
                      type: object
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/history:
    get:
      tags:
      - WalkCreatorTemplateHistory
      summary: Retrieve template history
      description: |
        Retrieves MODEL_STATE_HISTORY records using session-derived domain and `model_id`.
        The server always uses `txn_category=C` (template/creation history).
        Domain, txn_category, and cluster_child_id are not accepted from the client.

        Requires template **READ** access via line-of-sight permissions (or creator/alternate-user bypass).
        READ access is verified before the history lookup (E202 before downstream errors).
         Empty-history behavior:
        - If no records exist, `info_msg` will be returned with a localized message.
      operationId: getWalkTemplateHistory
      parameters:
      - name: model_id
        in: query
        required: true
        description: Model identifier for the template history lookup.
        schema:
          type: string
          example: FORM_123
      responses:
        '200':
          description: Template history retrieved successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WalkCreatorTemplateHistorySuccessResponse'
              examples:
                success:
                  summary: Successful response with history
                  value:
                    status: OK
                    walk_template_history:
                      history_details:
                      - domain_id: 170010099
                        model_id: FORM_123
                        action_text: Template created
                        created_by: user1
                        creation_time: '2026-08-10T10:00:00Z'
                        txn_category: C
                emptyHistory:
                  summary: Successful response with no history
                  value:
                    status: OK
                    walk_template_history:
                      info_msg: This section will show history messages on template submission
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: READ access denied (E202); evaluated before history lookup
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WalkApiErrorResponse'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/info:
    get:
      tags:
      - WalkCreatorTemplateInfo
      summary: Retrieve walk template Info tab metadata
      description: |
        Returns creator and last-updated metadata for a walk template (`txn_category=C`).
        Domain context is resolved from the session — not accepted from the client.

        Requires template **READ** access via line-of-sight permissions (or creator/alternate-user bypass).

        When either persisted updater id or name is blank, the server falls back to the latest
        `MODEL_STATE_HISTORY` row (`txn_category=C`) and returns that row's creator id, name, and
        creation time as `last_updated_by`, `last_updated_by_name`, and `last_updated_time`.

        READ access is verified before template existence lookup (E202 before E212).
      operationId: getWalkTemplateInfo
      parameters:
      - name: model_id
        in: query
        required: true
        description: Active walk template model identifier.
        schema:
          type: string
          example: FORM_123
      responses:
        '200':
          description: Template info retrieved successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WalkCreatorTemplateInfoSuccessResponse'
              examples:
                success:
                  summary: Successful response
                  value:
                    status: OK
                    walk_template_info:
                      created_by: user1
                      created_by_name: Jane Doe
                      creation_time: 1723891200000
                      last_updated_by: user2
                      last_updated_by_name: John Smith
                      last_updated_time: 1723977600000
                      form_unique_id: abc-123
                      form_access_key: key-456
                      model_id: FORM_123
                      form_trace_id: 987654321
        '400':
          description: Missing model_id (E112) or no creation template after access verified (E212)
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: READ access denied (E202); evaluated before existence lookup
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WalkApiErrorResponse'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/template-approvers:
    get:
      tags:
      - WalkCreatorTemplateApprovers
      summary: Fetch template approvers
      operationId: fetchTemplateApprovers
      description: |
        Returns Approvers for a walk template category.

        Walk template categories have an Approvers screen. In the modern experience the
        screen is named **Approvers** so it is distinct from template reviewers and from
        the legacy category Approver (`A`) permit. The rows behind this screen are template
        reviewers of permit type **REVIEWER** only (`permit_type` = `R`, `txn_category` = `C`).

        Mirrors legacy `POST /api/v2/reviewer/getPermitData` with `permitType` forced to `R`.
        Authorize (`C`) and Approver (`A`) rows are not returned, even if the client asks for them.

        **Authentication:** `X-reflexis-csrf-token-X` required. Domain context is resolved
        from the session. Category **READ** access is required.
      parameters:
      - name: category_id
        in: query
        required: true
        description: Walk template category id (`entity_id` on the permit row).
        schema:
          type: string
          example: CAT_SAFETY
      - name: model_type
        in: query
        required: true
        description: Category model type. `W` for a walk category.
        schema:
          type: string
          example: W
      - name: unit_id
        in: query
        required: false
        description: |
          Optional. Accepted as `unit_id` or `unitId`. A supplied value is kept; the session
          unit does not replace it. Fetch does not require a unit and does not filter the
          list by unit. `unit_id` is required only when adding or updating Approvers.
        schema:
          type: string
          example: HQ
      responses:
        '200':
          description: Approvers for the category. An empty array means none are defined.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WalkCreatorTemplateApproversSuccessResponse'
              examples:
                success:
                  summary: REVIEWER rows only
                  value:
                    status: OK
                    template_approvers:
                    - domain_id: 170010099
                      txn_category: C
                      permit_type: R
                      entity_id: CAT_SAFETY
                      entity_name: Safety
                      permit_sequence: 1
                      user_id: ''
                      profile_id: STORE_MGR
                      department_id: OPS
                      unit_id: HQ
                      unit_level: 1
                      response_time: 1440M
                      created_by: user1
                      creation_time: 1723891200000
                      permit_desc: '{"PROFILE-STORE_MGR":"Store Manager"}'
                      model_type: W
                empty:
                  summary: No REVIEWER rows
                  value:
                    status: OK
                    template_approvers: []
        '400':
          description: Missing category_id (E113) or model_type (E110), or category_id does not exist (E213)
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: Category READ access denied (E202)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WalkApiErrorResponse'
        '500':
          $ref: '#/components/responses/InternalServerError'
    post:
      tags:
      - WalkCreatorTemplateApprovers
      summary: Add template approvers
      operationId: addTemplateApprovers
      description: |
        Replaces Approvers for a walk template category.

        Same product meaning as **Fetch template approvers**: the modern Approvers screen
        stores template reviewers of permit type **REVIEWER** only. This operation follows
        `CategoryV2Service.addTemplateReviewers` for the reviewer list and ignores authorize
        and approver permit data.

        Behavior:
        - Each item is saved with `permit_type` = `R` and `txn_category` = `C`.
        - A request that includes any other permit type (`C`, `A`, `AUTHORIZE`, `APPROVER`) is rejected (E215).
        - Existing REVIEWER rows for the category are replaced. Authorize and Approver rows are not deleted.
        - Duplicate reviewer keys (category + profile + department + unit level) are stored once.
        - `permit_sequence` is assigned by the server from the remaining order.
        - The category `permitConfig` flag `REVIEWER` is set to `Y` when the saved list is not empty,
          and removed when `approvers` is `[]`. `AUTHORIZE` and `APPROVER` flags are preserved.
        - Pass `approvers` as `[]` to clear Approvers.
        - `unit_id` is required and is kept exactly as supplied. The session unit does not replace it.
          An approver object that omits `unit_id` is stored with this request `unit_id`. An explicit unit on the object is kept.

        Each object accepts snake_case or camelCase fields. `profile_id` or `department_id` is required.
        `category_name` is optional; when omitted the stored category name is used as `entity_name`.

        **Authentication:** `X-reflexis-csrf-token-X` required. Category **EDIT** access is required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - category_id
              - model_type
              - unit_id
              - approvers
              properties:
                category_id:
                  type: string
                  description: Walk template category id.
                  example: CAT_SAFETY
                model_type:
                  type: string
                  description: Category model type. `W` for a walk category.
                  example: W
                unit_id:
                  type: string
                  description: |
                    Caller unit id. Accepted as `unit_id` or `unitId`. Kept as supplied.
                    The session unit does not replace it.
                    Stored on approver rows that omit their own unit.
                  example: HQ
                category_name:
                  type: string
                  description: Optional category display name stored on each permit row.
                  example: Safety
                approvers:
                  type: string
                  description: |
                    JSON array of Approver objects. Permit type is forced to REVIEWER (`R`).
                    Do not send authorize or approver rows. `[]` clears the Approvers list.
                  example: '[{"profile_id":"STORE_MGR","department_id":"OPS","unit_id":"HQ","unit_level":1,"response_time":"1440M","permit_desc":"{\"PROFILE-STORE_MGR\":\"Store
                    Manager\"}"}]'
      responses:
        '200':
          description: Saved Approvers, in server-assigned sequence. Empty array when the list was cleared.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WalkCreatorTemplateApproversSuccessResponse'
              examples:
                success:
                  summary: REVIEWER rows saved
                  value:
                    status: OK
                    template_approvers:
                    - domain_id: 170010099
                      txn_category: C
                      permit_type: R
                      entity_id: CAT_SAFETY
                      entity_name: Safety
                      permit_sequence: 1
                      user_id: ''
                      profile_id: STORE_MGR
                      department_id: OPS
                      unit_id: HQ
                      unit_level: 1
                      response_time: 1440M
                      created_by: user1
                      creation_time: 1723891200000
                      permit_desc: '{"PROFILE-STORE_MGR":"Store Manager"}'
                      model_type: W
                cleared:
                  summary: Approvers cleared
                  value:
                    status: OK
                    template_approvers: []
        '400':
          description: |
            Missing category_id (E113), model_type or approvers (E110), or unit_id (E106);
            unknown category (E213); or a permit type other than REVIEWER (E215).
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: Category EDIT access denied (E202)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WalkApiErrorResponse'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/template-approvers/update:
    post:
      tags:
      - WalkCreatorTemplateApprovers
      summary: Update template approvers
      operationId: updateTemplateApprovers
      description: |
        Updates Approvers for a walk template category by replacing all REVIEWER rows.

        Same request and response contract as **Add template approvers**. Prefer this path
        when editing an existing Approvers list; use **Add** for the initial save.

        REVIEWER-only rules apply: authorize (`C`) and Approver (`A`) rows are never written.
        Pass `approvers` as `[]` to clear Approvers.

        **Authentication:** `X-reflexis-csrf-token-X` required. Category **EDIT** access is required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - category_id
              - model_type
              - unit_id
              - approvers
              properties:
                category_id:
                  type: string
                  example: CAT_SAFETY
                model_type:
                  type: string
                  example: W
                unit_id:
                  type: string
                  description: Caller unit id. Same rules as **Add template approvers**.
                  example: HQ
                category_name:
                  type: string
                  example: Safety
                approvers:
                  type: string
                  description: |
                    JSON array of Approver objects. Permit type is forced to REVIEWER (`R`).
                    `[]` clears the Approvers list.
                  example: '[{"profile_id":"STORE_MGR","department_id":"OPS","unit_level":1,"response_time":"1440M"}]'
      responses:
        '200':
          description: Updated Approvers in server-assigned sequence.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WalkCreatorTemplateApproversSuccessResponse'
              examples:
                success:
                  value:
                    status: OK
                    template_approvers:
                    - permit_type: R
                      txn_category: C
                      entity_id: CAT_SAFETY
                      profile_id: STORE_MGR
                      department_id: OPS
                      unit_level: 1
                      permit_sequence: 1
                      model_type: W
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: Category EDIT access denied (E202)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WalkApiErrorResponse'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/template-approvers/delete:
    post:
      tags:
      - WalkCreatorTemplateApprovers
      summary: Delete template approvers
      operationId: deleteTemplateApprovers
      description: |
        Deletes Approvers for a walk template category. Only REVIEWER (`permit_type` = `R`)
        rows are removed. Authorize (`C`) and Approver (`A`) rows are never deleted.

        - Omit `approvers`, or pass `approvers` as `[]`, to clear every REVIEWER row.
        - Pass a non-empty `approvers` JSON array to remove matching rows by unique key
          (`profile_id` + `department_id` + `unit_level`). Remaining REVIEWER rows are
          resequenced. When no row matches, the API returns E404 (`NO_DATA_FOUND`).

        The category `permitConfig` flag `REVIEWER` is removed when no REVIEWER rows remain;
        `AUTHORIZE` and `APPROVER` flags are preserved.

        This operation does not take `unit_id`. A supplied unit is discarded.

        **Authentication:** `X-reflexis-csrf-token-X` required. Category **EDIT** access is required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - category_id
              - model_type
              properties:
                category_id:
                  type: string
                  example: CAT_SAFETY
                model_type:
                  type: string
                  example: W
                approvers:
                  type: string
                  description: |
                    Optional JSON array of Approver keys to delete. Omit or pass `[]` to
                    clear all Approvers. Each object needs `profile_id` or `department_id`
                    (and optional `unit_level`, default `0`).
                  example: '[{"profile_id":"STORE_MGR","department_id":"OPS","unit_level":1}]'
      responses:
        '200':
          description: |
            Success — returns removed rows under `deleted_template_approvers`.
            When a selective delete matches no rows, HTTP 200 with `errorCode` E404 may be returned.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorTemplateApproversDeleteSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                clearAll:
                  summary: All Approvers cleared
                  value:
                    status: OK
                    deleted_template_approvers:
                    - permit_type: R
                      txn_category: C
                      entity_id: CAT_SAFETY
                      profile_id: STORE_MGR
                      department_id: OPS
                      unit_level: 1
                      permit_sequence: 1
                      model_type: W
                selective:
                  summary: Matching Approvers removed
                  value:
                    status: OK
                    deleted_template_approvers:
                    - permit_type: R
                      entity_id: CAT_SAFETY
                      profile_id: STORE_MGR
                      department_id: OPS
                      unit_level: 1
                      model_type: W
                noneMatched:
                  summary: Selective delete matched no rows
                  value:
                    status: ER
                    errorCode: E404
                    response: No data found
        '400':
          description: Missing category_id (E113) or model_type (E110)
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: Category EDIT access denied (E202)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WalkApiErrorResponse'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/export:
    post:
      tags:
      - WalkCreatorTemplateImportExport
      summary: Export walk/form template(s) as ZIP
      operationId: exportWalkTemplateModel
      description: |
        Exports one or more templates to a ZIP package on the server upload directory.

        Mirrors legacy `POST /service/api/v2/model/exportModel` and delegates to the same
        `ImportExportService.exportAllModel` implementation.

        **Authentication:** `X-reflexis-csrf-token-X` required. Domain context is resolved
        from the session — do not send `domain_id` / `auth_token` as form fields.

        `model_id` may be a single id or a comma-separated list.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Template model id, or comma-separated list of model ids.
                  example: FORM_123,FORM_456
                model_type:
                  type: string
                  description: Model type code (e.g. `W` for walk, `F` for form).
                  example: W
                category_id:
                  type: string
                  description: Optional category filter for the export.
      responses:
        '200':
          description: |
            Success returns `status: OK` and export file metadata under `template_export`.
            Application-level failures may also return HTTP 200 with `status: ER`.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorTemplateExportSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                success:
                  value:
                    status: OK
                    template_export:
                      file_path: /uploads/170010099/ModelExport/FORM_1723891200000/
                      file_list:
                      - path: /uploads/170010099/ModelExport/FORM_1723891200000/FORM_1723891200000.zip
                        name: FORM_1723891200000.zip
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/import:
    post:
      tags:
      - WalkCreatorTemplateImportExport
      summary: Import walk/form template(s) from ZIP
      operationId: importWalkTemplateModel
      description: |
        Imports modern (`16.11`) template ZIP package(s).

        Mirrors legacy `POST /service/api/v2/model/importModel` (same `ImportExportService`)
        with a **next-gen response envelope** shaped for Walk Creator UI navigation.

        **Authentication:** `X-reflexis-csrf-token-X` required. Domain and user context are
        resolved from the session — do not send `domain_id` / `auth_token` as form fields.

        **Next-gen defaults** (when omitted; legacy Admin Export-Import unchanged):

        | Field | Default |
        |---|---|
        | `copy_with_permission` | `Y` |
        | `version_type` | `16.11` |
        | `entity_type` | `W` |
        | `created_by` / `creator_unit` | Session user id / unit id |

        **Multipart:** the ZIP **part name** must end with `zip` (e.g. `file.zip`).

        ---

        ## Success response contract

        Always read **`template_import.models[]`**:

        | Field | Type | Purpose |
        |---|---|---|
        | `models[].model_id` | string | New template id (clean, e.g. `FORM_55662`) |
        | `models[].category_id` | string | Category id for `retrieveTemplateData` / editor route |

        When exactly one template is imported, the same ids are also mirrored as
        top-level `template_import.model_id` and `template_import.category_id`.

        Imported templates are created as **Draft (`D`)**.

        ### Single import (example)

        ```json
        {
          "status": "OK",
          "template_import": {
            "model_id": "FORM_55662",
            "category_id": "CAT_123",
            "models": [
              { "model_id": "FORM_55662", "category_id": "CAT_123" }
            ]
          }
        }
        ```

        ### Multi import (example)

        ```json
        {
          "status": "OK",
          "template_import": {
            "models": [
              { "model_id": "FORM_1", "category_id": "CAT_A" },
              { "model_id": "FORM_2", "category_id": "CAT_B" }
            ]
          }
        }
        ```
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                file.zip:
                  type: string
                  format: binary
                  description: |
                    Modern template ZIP (`16.11`). Multipart field name must end with `zip`
                    (e.g. `file.zip`).
                copy_with_permission:
                  type: string
                  enum:
                  - Y
                  - N
                  description: |
                    When `Y`, import copies permission listings with the template.
                    Next-gen default is `Y` when omitted.
                  example: Y
                created_by:
                  type: string
                  description: Optional override creator user id. Defaults to session user id.
                creator_unit:
                  type: string
                  description: Optional override creator unit id. Defaults to session unit id.
                entity_type:
                  type: string
                  description: |
                    Entity type for package compatibility (`W` / `F` / `S`).
                    Next-gen default is `W` when omitted.
                  example: W
                version_type:
                  type: string
                  description: |
                    Package version. Next-gen default is `16.11` when omitted.
                    Older package formats are not supported on this endpoint.
                  example: '16.11'
      responses:
        '200':
          description: |
            Success — `status: OK` with `template_import.models[]` (`model_id` + `category_id`).
            Application-level failures may also return HTTP 200 with `status: ER`.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorTemplateImportSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                singleImport:
                  summary: One template imported — use models[0] or top-level ids
                  value:
                    status: OK
                    template_import:
                      model_id: FORM_55662
                      category_id: CAT_123
                      models:
                      - model_id: FORM_55662
                        category_id: CAT_123
                multiImport:
                  summary: Multiple templates — iterate models[] only
                  value:
                    status: OK
                    template_import:
                      models:
                      - model_id: FORM_1
                        category_id: CAT_A
                      - model_id: FORM_2
                        category_id: CAT_B
                missingZip:
                  summary: Multipart part name did not end with zip
                  value:
                    status: ER
                    error: Please Upload Zip file.
                entityTypeMismatch:
                  summary: Package model type does not match entity_type
                  value:
                    status: ER
                    error: File is not compatible with Walk
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/external-attributes:
    post:
      tags:
      - WalkCreatorExternalAttributes
      summary: Save external attributes for a walk template
      operationId: saveWalkTemplateExternalAttributes
      description: |
        Replaces the external attribute rows for a walk template (`MODEL_ID`).

        Mirrors the external-attribute save previously bundled into legacy
        `POST /service/template/updateTemplateDetails`. Pass an empty `external_attribute`
        string (or `[]`) to clear all rows for the template.

        **Authentication:** `X-reflexis-csrf-token-X` required. Domain and user context are
        resolved from the session — not accepted as form parameters.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_123
                external_attribute:
                  type: string
                  description: |
                    JSON array string of external attribute objects, each with `key`, `name`, and `value`.
                    Pass an empty string or `[]` to remove all external attributes for the template.
                  example: '[{"key":"STORE_ID","name":"Store Id","value":"123"}]'
      responses:
        '200':
          description: |
            Success — returns saved rows under `external_attributes.external_attribute`.
            Application-level failures may also return HTTP 200 with `status: ER`.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorExternalAttributesSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                success:
                  value:
                    status: OK
                    external_attributes:
                      external_attribute:
                      - key: STORE_ID
                        name: Store Id
                        value: '123'
                cleared:
                  value:
                    status: OK
                    external_attributes:
                      external_attribute: []
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/list:
    post:
      tags:
      - WalkCreatorTemplateList
      summary: List walk templates by category
      operationId: retrieveTemplates
      description: |
        Returns a paginated list of walk templates for a given `model_type` and `category_id`.
        Defaults `view_type` to `CATEGORY_TAB_VIEW` (`C`) when omitted.
        Mirrors legacy `POST /api/v2/template/retrieveTemplates`.
        **Authentication:** `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_type
              - category_id
              properties:
                model_type:
                  type: string
                  example: W
                category_id:
                  type: string
                  example: '1787735704510'
                view_type:
                  type: string
                  description: Defaults to C (CATEGORY_TAB_VIEW).
                status:
                  type: string
                page_no:
                  type: integer
                  default: 1
                sort_by:
                  type: string
                  default: lastUpdatedTime
                sort_order:
                  type: string
                  enum:
                  - '1'
                  - '-1'
                  default: '-1'
                model_name:
                  type: string
                from_time:
                  type: integer
                  format: int64
      responses:
        '200':
          description: Template list, possibly empty.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplatesListSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                success:
                  value:
                    status: OK
                    templates:
                      template_list:
                      - model_id: FORM_55740
                        model_name: Store Walk
                        model_type: W
                        category_id: '1787735704510'
                        status: A
                      total_count: 1
                      total_pages: 1
                      last_fetch_time: 1792753677893
                empty:
                  value:
                    status: OK
                    templates:
                      template_list: []
                      total_count: 0
                      total_pages: 0
                      last_fetch_time: 1792753677893
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/recent:
    post:
      tags:
      - WalkCreatorTemplateList
      summary: List recently updated walk templates
      operationId: retrieveRecentTemplates
      description: |
        Returns recently updated walk templates. Defaults view_type to RC (RECENT_TAB_VIEW).
        Mirrors legacy POST /api/v2/template/retrieveRecentTemplates.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_type
              properties:
                model_type:
                  type: string
                  example: W
                view_type:
                  type: string
                  description: Defaults to RC (RECENT_TAB_VIEW).
                page_no:
                  type: integer
                  default: 1
                sort_order:
                  type: string
                  enum:
                  - '1'
                  - '-1'
                  default: '-1'
      responses:
        '200':
          description: Recent template list.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplatesListSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/all:
    post:
      tags:
      - WalkCreatorTemplateList
      summary: List all walk templates (no category filter)
      operationId: retrieveAllTemplates
      description: |
        Returns all walk templates for the domain. Defaults view_type to A (ALL_TEMPLATES_TAB_VIEW).
        Mirrors legacy POST /api/v2/template/retrieveAllTemplates.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_type
              properties:
                model_type:
                  type: string
                  example: W
                view_type:
                  type: string
                status:
                  type: string
                page_no:
                  type: integer
                  default: 1
                sort_order:
                  type: string
                  enum:
                  - '1'
                  - '-1'
                  default: '-1'
                from_time:
                  type: integer
                  format: int64
      responses:
        '200':
          description: All-templates list.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplatesListSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/search:
    post:
      tags:
      - WalkCreatorTemplateList
      summary: Search walk templates (typeahead)
      operationId: searchTemplates
      description: |
        Searches walk templates for typeahead flows. Sets showSearchWalkList=Y internally.
        Mirrors legacy POST /api/v2/template/searchTemplates.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_type
              properties:
                model_type:
                  type: string
                  example: W
                model_name:
                  type: string
                category_id:
                  type: string
      responses:
        '200':
          description: Search results.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplatesListSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/data:
    post:
      tags:
      - WalkCreatorTemplateList
      summary: Retrieve full template data (open in Walk Creator editor)
      operationId: retrieveTemplateData
      description: |
        Returns the full template document including groups, questions, skip logic, scores, tasks.
        Requires template READ access.
        Mirrors legacy POST /api/v2/template/retrieveTemplateData.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
      responses:
        '200':
          description: Full template structure under template_data.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateDataSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                success:
                  value:
                    status: OK
                    template_data:
                      model_id: FORM_55740
                      model_name: Store Walk
                      model_type: W
                      status: A
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates:
    post:
      tags:
      - WalkCreatorTemplateCRUD
      summary: Add a new walk template
      operationId: addWalkTemplate
      description: |
        Creates a new walk template (Draft status).
        Mirrors legacy POST /api/v2/template/addTemplate.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                model_name:
                  type: string
                model_type:
                  type: string
                  example: W
                category_id:
                  type: string
                model_description:
                  type: string
                start_date:
                  type: string
                end_date:
                  type: string
                modelLogo:
                  type: string
                  format: binary
      responses:
        '200':
          description: Created template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                success:
                  value:
                    status: OK
                    template:
                      model_id: FORM_55800
                      model_name: New Store Walk
                      status: D
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/update:
    post:
      tags:
      - WalkCreatorTemplateCRUD
      summary: Update an existing walk template
      operationId: updateWalkTemplate
      description: |
        Updates template metadata (name, description, dates, logo). Requires template EDIT access.
        Mirrors legacy POST /api/v2/template/updateTemplate.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
                model_name:
                  type: string
                model_description:
                  type: string
                start_date:
                  type: string
                end_date:
                  type: string
                modelLogo:
                  type: string
                  format: binary
      responses:
        '200':
          description: Updated template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                success:
                  value:
                    status: OK
                    template:
                      model_id: FORM_55740
                      model_name: Updated Store Walk
                invalidAccess:
                  value:
                    status: ER
                    error: Invalid Template Access
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/edit:
    post:
      tags:
      - WalkCreatorTemplateLifecycle
      summary: Open a walk template for editing (create ED copy)
      operationId: editWalkTemplate
      description: |
        Opens an active template for editing by creating an ED copy. Requires EDIT access.
        Mirrors legacy POST /api/v2/template/editTemplate.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
      responses:
        '200':
          description: Edit-in-progress template (status ED) under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/restore:
    post:
      tags:
      - WalkCreatorTemplateLifecycle
      summary: Restore a walk template (discard ED changes)
      operationId: restoreWalkTemplate
      description: |
        Discards the ED copy and restores to the last committed state.
        Mirrors legacy POST /api/v2/template/restoreTemplate.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
      responses:
        '200':
          description: Restored template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/submit:
    post:
      tags:
      - WalkCreatorTemplateLifecycle
      summary: Submit a walk template for approval
      operationId: submitWalkTemplate
      description: |
        Submits a walk template for review/approval (Draft to Pending Approval).
        Mirrors legacy POST /api/v2/template/submitForm.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
                approver_id:
                  type: string
      responses:
        '200':
          description: Submitted template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/copy:
    post:
      tags:
      - WalkCreatorTemplateLifecycle
      summary: Copy a walk template
      operationId: copyWalkTemplate
      description: |
        Creates a copy with a new MODEL_ID (Draft status).
        Mirrors legacy POST /api/v2/template/copyTemplate.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
                model_name:
                  type: string
                category_id:
                  type: string
      responses:
        '200':
          description: Copied template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                success:
                  value:
                    status: OK
                    template:
                      model_id: FORM_55801
                      model_name: Copy of Store Walk
                      status: D
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/duplicate:
    post:
      tags:
      - WalkCreatorTemplateLifecycle
      summary: Duplicate a walk template
      operationId: duplicateWalkTemplate
      description: |
        Duplicates a walk template. Mirrors legacy POST /api/v2/template/duplicateTemplate.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
                model_name:
                  type: string
      responses:
        '200':
          description: Duplicated template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/delete:
    post:
      tags:
      - WalkCreatorTemplateLifecycle
      summary: Delete a walk template
      operationId: deleteWalkTemplate
      description: |
        Deletes a walk template. Requires template REMOVE access.
        Returns a localized success message string (not an object) under template.
        Mirrors legacy POST /api/v2/template/deleteTemplate.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
      responses:
        '200':
          description: Success message string under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateDeleteSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                success:
                  value:
                    status: OK
                    template: Questionnaire Deleted Successfully
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/details:
    post:
      tags:
      - WalkCreatorTemplateDetails
      summary: Save template details (schedule, assignment, distribution)
      operationId: updateWalkTemplateDetails
      description: |
        Saves the Details tab data. Requires template EDIT access.
        Mirrors legacy POST /api/v2/template/addTemplateDetails / updateTemplateDetails.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
                assignment_type:
                  type: string
                start_date:
                  type: string
                end_date:
                  type: string
      responses:
        '200':
          description: Updated template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/scores:
    post:
      tags:
      - WalkCreatorTemplateDetails
      summary: Save template scoring configuration
      operationId: saveWalkTemplateScores
      description: |
        Saves the scoring configuration. Requires template EDIT access.
        Mirrors legacy POST /api/v2/template/saveTemplateScores.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
                score_data:
                  type: string
                pass_percentage:
                  type: string
      responses:
        '200':
          description: Updated template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/print:
    post:
      tags:
      - WalkCreatorTemplateDetails
      summary: Save template print/PDF settings
      operationId: saveWalkTemplatePrintData
      description: |
        Saves print/PDF export settings. Requires template EDIT access.
        Mirrors legacy POST /api/v2/template/saveTemplatePrintData.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
                print_data:
                  type: string
      responses:
        '200':
          description: Updated template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/translation:
    post:
      tags:
      - WalkCreatorTemplateDetails
      summary: Save template translation strings
      operationId: saveWalkTemplateTranslation
      description: |
        Saves translation strings. When model_id is supplied, caller must have EDIT access.
        Mirrors legacy POST /api/v2/template/saveTranslation.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                model_id:
                  type: string
                  example: FORM_55740
                translation_data:
                  type: string
      responses:
        '200':
          description: Save result under translation.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTranslationSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/translation/get:
    post:
      tags:
      - WalkCreatorTemplateDetails
      summary: Get template translation strings
      operationId: getWalkTemplateTranslation
      description: |
        Retrieves translation strings. Mirrors legacy POST /api/v2/template/getTranslation.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                model_id:
                  type: string
                  example: FORM_55740
      responses:
        '200':
          description: Translation data under translation.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTranslationSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/paste-question:
    post:
      tags:
      - WalkCreatorTemplateDetails
      summary: Paste a copied question into a template group
      operationId: pasteWalkQuestion
      description: |
        Pastes a copied question into the target group. Requires EDIT access.
        Mirrors legacy POST /api/v2/template/pasteQuestion.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
                group_id:
                  type: string
                question_data:
                  type: string
      responses:
        '200':
          description: Updated template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/paste-group:
    post:
      tags:
      - WalkCreatorTemplateDetails
      summary: Paste a copied question group into a template
      operationId: pasteWalkGroup
      description: |
        Pastes a copied group into the template. Requires EDIT access.
        Mirrors legacy POST /api/v2/template/pasteGroup.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
                group_data:
                  type: string
      responses:
        '200':
          description: Updated template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/access-roles:
    post:
      tags:
      - WalkCreatorTemplateRoles
      summary: Get template access roles (permission data)
      operationId: getWalkTemplateAccessRoles
      description: |
        Returns access roles configured for a walk template.
        Mirrors legacy POST /api/v2/template/getAccessRoles.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
                model_type:
                  type: string
                  example: W
      responses:
        '200':
          description: Access roles under access_roles.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkAccessRolesSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/access-roles/save:
    post:
      tags:
      - WalkCreatorTemplateRoles
      summary: Save template access roles
      operationId: saveWalkTemplateAccessRoles
      description: |
        Saves access roles for a walk template.
        Mirrors legacy POST /api/v2/template/saveAccessRoles.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
                model_type:
                  type: string
                  example: W
                permission_data:
                  type: string
      responses:
        '200':
          description: Saved access roles under access_roles.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkAccessRolesSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/user-profiles:
    post:
      tags:
      - WalkCreatorTemplateRoles
      summary: Get user profile list for access role assignment
      operationId: getWalkTemplateUserProfiles
      description: |
        Returns available user profiles for the template access roles screen.
        Mirrors legacy POST /api/v2/template/getUserProfileList.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                model_type:
                  type: string
                  example: W
      responses:
        '200':
          description: User profile list under user_profiles.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkUserProfilesSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/external-attributes/get:
    post:
      tags:
      - WalkCreatorExternalAttributes
      summary: Get external attributes for a walk template
      operationId: getWalkTemplateExternalAttributes
      description: |
        Returns stored external attribute rows for a walk template.
        Mirrors legacy POST /api/v2/template/getExternalAttribute.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
      responses:
        '200':
          description: External attributes under external_attributes.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorExternalAttributesSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
              examples:
                success:
                  value:
                    status: OK
                    external_attributes:
                      external_attribute:
                      - key: STORE_ID
                        name: Store Id
                        value: '123'
                empty:
                  value:
                    status: OK
                    external_attributes:
                      external_attribute: []
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/remove-score:
    post:
      tags:
      - WalkCreatorTemplateCleanup
      summary: Remove scoring data from a template
      operationId: removeWalkTemplateScoreData
      description: |
        Removes all scoring configuration. Used when scoring feature is disabled.
        Mirrors legacy POST /api/v2/template/removeScoreData.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
      responses:
        '200':
          description: Updated template under template after score data removal.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/remove-follow-up:
    post:
      tags:
      - WalkCreatorTemplateCleanup
      summary: Remove follow-up data from a template
      operationId: removeWalkTemplateFollowUpData
      description: |
        Removes automated follow-up task configuration. Used when follow-up feature is disabled.
        Mirrors legacy POST /api/v2/template/removeFollowUpData.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
      responses:
        '200':
          description: Updated template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/remove-follow-up-tasks:
    post:
      tags:
      - WalkCreatorTemplateCleanup
      summary: Remove follow-up tasks from a template
      operationId: removeWalkTemplateFollowUpTasks
      description: |
        Removes manual follow-up task records.
        Mirrors legacy POST /api/v2/template/removeFollowUpTasks.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
      responses:
        '200':
          description: Updated template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/templates/remove-linked-walk:
    post:
      tags:
      - WalkCreatorTemplateCleanup
      summary: Remove linked-walk data from a template
      operationId: removeWalkTemplateLinkedWalkData
      description: |
        Removes linked-walk (external/project walk) configuration. Used when externalWalk feature is disabled.
        Mirrors legacy POST /api/v2/template/removeLinkedWalkData.
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
      responses:
        '200':
          description: Updated template under template.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkTemplateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/bank/questions:
    post:
      tags:
      - WalkCreatorBank
      summary: Retrieve bank questions
      operationId: getWalkCreatorBankQuestions
      description: |
        Returns question bank questions for creator flows.
        Mirrors legacy POST /api/v2/bank/getBankQuestions.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Bank questions under bank_questions.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorBankQuestionsSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/categories:
    post:
      tags:
      - WalkCreatorCategory
      summary: Add walk category
      operationId: addWalkCreatorCategory
      description: |
        Creates a walk category. Mirrors legacy POST /api/v2/category/addCategory (multipart).
        When model_type is present, requires category-add permission (FormRedirectUtils).
        Authentication - X-reflexis-csrf-token-X required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                model_type:
                  type: string
                  example: W
                category_name:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Category under category.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorCategorySuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/categories/update:
    post:
      tags:
      - WalkCreatorCategory
      summary: Update walk category
      operationId: updateWalkCreatorCategory
      description: |
        Updates a walk category. Mirrors legacy POST /api/v2/category/updateCategory (multipart).
        Validates category EDIT access via CategoryResolverUtils.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                category_id:
                  type: string
                category_type:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Category under category.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorCategorySuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/categories/delete:
    post:
      tags:
      - WalkCreatorCategory
      summary: Delete walk category
      operationId: deleteWalkCreatorCategory
      description: |
        Deletes a walk category. Mirrors legacy POST /api/v2/category/deleteCategory.
        Validates category REMOVE access via CategoryResolverUtils.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                category_id:
                  type: string
                category_type:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Category under category.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorCategorySuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/categories/list:
    post:
      tags:
      - WalkCreatorCategory
      summary: Retrieve walk categories
      operationId: retrieveWalkCreatorCategories
      description: |
        Retrieves categories. Mirrors legacy POST /api/v2/category/retrieveCategory.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Categories under categories.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorCategoriesSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/distribution:
    post:
      tags:
      - WalkCreatorDistribution
      summary: Get distribution data for a template
      operationId: getWalkCreatorDistributionData
      description: |
        Mirrors legacy POST /api/v2/distribution/getDistributionData.
        Required - model_id. domain_id from session.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  example: FORM_55740
      responses:
        '200':
          description: Distribution under distribution.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorDistributionSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/distribution/list:
    post:
      tags:
      - WalkCreatorDistribution
      summary: Get distribution list
      operationId: getWalkCreatorDistributionList
      description: Mirrors legacy POST /api/v2/distribution/getDistributionList.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Distribution list under distribution_list.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorDistributionListSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/distribution/attributes:
    post:
      tags:
      - WalkCreatorDistribution
      summary: Get distribution attribute list
      operationId: getWalkCreatorDistributionAttributes
      description: Mirrors legacy POST /api/v2/distribution/getAttributeList.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Attributes under distribution_attributes.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorDistributionAttributesSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/distribution/attribute-units:
    post:
      tags:
      - WalkCreatorDistribution
      summary: Get distribution attribute units
      operationId: getWalkCreatorDistributionAttributeUnits
      description: |
        Mirrors legacy POST /api/v2/distribution/getAttributeUnits.
        Required - dist_type.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - dist_type
              properties:
                dist_type:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Units under attribute_units.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorAttributeUnitsSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/distribution/save:
    post:
      tags:
      - WalkCreatorDistribution
      summary: Save distribution data
      operationId: saveWalkCreatorDistributionData
      description: |
        Mirrors legacy POST /api/v2/distribution/saveDistributionData.
        Required - model_id, dist_id, dist_category. Validates template EDIT access.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              - dist_id
              - dist_category
              properties:
                model_id:
                  type: string
                dist_id:
                  type: string
                dist_category:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Distribution under distribution.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorDistributionSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/distribution/unit-hierarchy:
    post:
      tags:
      - WalkCreatorDistribution
      summary: Get all unit hierarchy
      operationId: getWalkCreatorUnitHierarchy
      description: Mirrors legacy POST /api/v2/distribution/getAllUnitHierarchy.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Hierarchy under unit_hierarchy.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorUnitHierarchySuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/feedback:
    post:
      tags:
      - WalkCreatorFeedback
      summary: Save feedback form data
      operationId: saveWalkCreatorFeedback
      description: |
        Mirrors legacy POST /api/v2/feedbackForm/saveFeedbackData (multipart).
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Feedback under feedback.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorFeedbackSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/feedback/state:
    post:
      tags:
      - WalkCreatorFeedback
      summary: Check feedback state
      operationId: checkWalkCreatorFeedbackState
      description: |
        Mirrors legacy POST /api/v2/feedbackForm/checkFeedbackState.
        Optional module_name defaults to modern walk.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                module_name:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: State under feedback_state.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorFeedbackStateSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/feedback/decide-later:
    post:
      tags:
      - WalkCreatorFeedback
      summary: Decide later on feedback
      operationId: decideLaterWalkCreatorFeedback
      description: Mirrors legacy POST /api/v2/feedbackForm/decideLater.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                module_name:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Result under feedback.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorFeedbackSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/permissions:
    post:
      tags:
      - WalkCreatorPermission
      summary: Get walk permit data
      operationId: getWalkCreatorPermissions
      description: |
        Mirrors legacy POST /api/v2/permission/getWalkPermitData.
        Required - entity_id.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - entity_id
              properties:
                entity_id:
                  type: string
                  example: FORM_55740
              additionalProperties: true
      responses:
        '200':
          description: Permissions under permissions.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorPermissionsSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/permissions/save:
    post:
      tags:
      - WalkCreatorPermission
      summary: Save walk permit data
      operationId: saveWalkCreatorPermissions
      description: |
        Mirrors legacy POST /api/v2/permission/saveWalkPermitData (multipart).
        Required - model_id.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Permissions under permissions.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorPermissionsSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/permissions/update:
    post:
      tags:
      - WalkCreatorPermission
      summary: Update walk permit data
      operationId: updateWalkCreatorPermissions
      description: |
        Mirrors legacy POST /api/v2/permission/updateWalkPermitData (multipart).
        Required - model_id.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Permissions under permissions.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorPermissionsSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/permissions/delete:
    post:
      tags:
      - WalkCreatorPermission
      summary: Delete walk permission
      operationId: deleteWalkCreatorPermission
      description: |
        Mirrors legacy POST /api/v2/permission/deleteWalkPermission (multipart).
        Required - model_id.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Permissions under permissions.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorPermissionsSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/permissions/group-exists:
    post:
      tags:
      - WalkCreatorPermission
      summary: Check if group permission exists
      operationId: isWalkCreatorGroupPermExist
      description: |
        Mirrors FormUtils.isGroupPermExist (legacy /service/model/isGroupPermExist and
        /api/v2/permission/isGroupPermExist). domain_id from session — do not send domain_id.
        Required - model_id. Optional - profile_id, department_id.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                profile_id:
                  type: string
                department_id:
                  type: string
      responses:
        '200':
          description: |
            When exists - status OK with group_perm_exists. When not - status ER (legacy errorMessage(0)).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorGroupPermExistsSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/count:
    post:
      tags:
      - WalkCreatorLogic
      summary: Get logic count
      operationId: getWalkCreatorLogicCount
      description: |
        Returns logic rule count. Mirrors legacy POST /api/v2/logicRule/getLogicCount.
        Required - model_id.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Count under logic_count.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicCountSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/rules:
    post:
      tags:
      - WalkCreatorLogic
      summary: List logic rules
      operationId: getWalkCreatorLogicRuleList
      description: |
        Returns logic rules sorted alphabetically by ruleName (case-insensitive).
        Mirrors legacy POST /api/v2/logicRule/getLogicRuleList.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Rules under logic_rules.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicRulesSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/rules/details:
    post:
      tags:
      - WalkCreatorLogic
      summary: Get logic rule details
      operationId: getWalkCreatorLogicRuleDetails
      description: |
        Returns logic rule details. Mirrors legacy POST /api/v2/logicRule/getLogicRuleDetails.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Rule under logic_rule.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicRuleSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/skips/details:
    post:
      tags:
      - WalkCreatorLogic
      summary: Get logic skip details
      operationId: getWalkCreatorLogicSkipDetails
      description: |
        Returns logic skip details. Mirrors legacy POST /api/v2/logicRule/getLogicSkipDetails.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Skip under logic_skip.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicSkipSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/notifications:
    post:
      tags:
      - WalkCreatorLogic
      summary: List logic notifications
      operationId: getWalkCreatorLogicNotificationList
      description: |
        Returns logic notifications. Mirrors legacy POST /api/v2/logicRule/getLogicNotificationList.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Notifications under logic_notifications.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicNotificationsSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/tasks:
    post:
      tags:
      - WalkCreatorLogic
      summary: List logic tasks
      operationId: getWalkCreatorLogicTaskList
      description: |
        Returns logic tasks. Mirrors legacy POST /api/v2/logicRule/getLogicTaskList.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Tasks under logic_tasks.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicTasksSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/rules/save:
    post:
      tags:
      - WalkCreatorLogic
      summary: Save logic rule
      operationId: saveWalkCreatorLogicRule
      description: |
        Saves question-based or advanced logic rule. Mirrors legacy POST /api/v2/logicRule/saveLogicRule. Required - model_id, rule_name.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              - rule_name
              properties:
                model_id:
                  type: string
                rule_name:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Rule under logic_rule.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicRuleSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/notifications/save:
    post:
      tags:
      - WalkCreatorLogic
      summary: Save logic notification
      operationId: saveWalkCreatorLogicNotification
      description: |
        Saves logic notification. Mirrors legacy POST /api/v2/logicRule/saveLogicNotification.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Notification under logic_notification.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicNotificationSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/skips/save:
    post:
      tags:
      - WalkCreatorLogic
      summary: Save logic skip
      operationId: saveWalkCreatorLogicSkip
      description: |
        Saves logic skip. Mirrors legacy POST /api/v2/logicRule/saveLogicSkip.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Skip under logic_skip.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicSkipSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/tasks/save:
    post:
      tags:
      - WalkCreatorLogic
      summary: Save logic task
      operationId: saveWalkCreatorLogicTask
      description: |
        Saves logic task (multipart). Mirrors legacy POST /api/v2/logicRule/saveLogicTask.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Task under logic_task.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicTaskSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/rules/delete:
    post:
      tags:
      - WalkCreatorLogic
      summary: Delete logic rule
      operationId: deleteWalkCreatorLogicRule
      description: |
        Deletes logic rule. Mirrors legacy POST /api/v2/logicRule/deleteLogicRule.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Rule under logic_rule.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicRuleSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/skips/delete:
    post:
      tags:
      - WalkCreatorLogic
      summary: Delete logic skip
      operationId: deleteWalkCreatorLogicSkip
      description: |
        Deletes logic skip. Mirrors legacy POST /api/v2/logicRule/deleteLogicSkip.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Skip under logic_skip.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicSkipSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/tasks/delete:
    post:
      tags:
      - WalkCreatorLogic
      summary: Delete logic task
      operationId: deleteWalkCreatorLogicTask
      description: |
        Deletes logic task. Mirrors legacy POST /api/v2/logicRule/deleteLogicTask.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Task under logic_task.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicTaskSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/logic/notifications/delete:
    post:
      tags:
      - WalkCreatorLogic
      summary: Delete logic notification
      operationId: deleteWalkCreatorLogicNotification
      description: |
        Deletes logic notification. Mirrors legacy POST /api/v2/logicRule/deleteLogicNotification.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Notification under logic_notification.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorLogicNotificationSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/groups:
    post:
      tags:
      - WalkCreatorQuestionGroup
      summary: Add question group
      operationId: addWalkCreatorGroup
      description: |
        Adds a question group (multipart). Requires template EDIT access. Mirrors legacy POST /api/v2/questionGroup/addGroup.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Group under group.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorGroupSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/groups/update:
    post:
      tags:
      - WalkCreatorQuestionGroup
      summary: Update question group
      operationId: updateWalkCreatorGroup
      description: |
        Updates a question group (multipart). Requires template EDIT access. Mirrors legacy POST /api/v2/questionGroup/updateGroup.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Group under group.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorGroupSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/groups/delete:
    post:
      tags:
      - WalkCreatorQuestionGroup
      summary: Delete question group
      operationId: deleteWalkCreatorQuestionGroup
      description: |
        Deletes a question group. Requires template EDIT access. Mirrors legacy POST /api/v2/questionGroup/deleteQuestionGroup.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Group under group.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorGroupSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/groups/permissions:
    post:
      tags:
      - WalkCreatorQuestionGroup
      summary: Get group permit data
      operationId: getWalkCreatorGroupPermitData
      description: |
        Returns group permissions. Mirrors legacy POST /api/v2/questionGroup/getGroupPermitData.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Permissions under group_permissions.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorGroupPermissionsSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/questions:
    post:
      tags:
      - WalkCreatorQuestionGroup
      summary: Add question
      operationId: addWalkCreatorQuestion
      description: |
        Adds a question (multipart). Requires template EDIT access. Mirrors legacy POST /api/v2/questionGroup/addQuestion.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Question under question.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorQuestionSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/questions/update:
    post:
      tags:
      - WalkCreatorQuestionGroup
      summary: Update question
      operationId: updateWalkCreatorQuestion
      description: |
        Updates a question (multipart). Requires template EDIT access. Mirrors legacy POST /api/v2/questionGroup/updateQuestion.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Question under question.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorQuestionSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/questions/retrieve:
    post:
      tags:
      - WalkCreatorQuestionGroup
      summary: Retrieve question
      operationId: retrieveWalkCreatorQuestion
      description: |
        Retrieves a question. Mirrors legacy POST /api/v2/questionGroup/retrieveQuestion.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Question under question.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorQuestionSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/questions/delete:
    post:
      tags:
      - WalkCreatorQuestionGroup
      summary: Delete question
      operationId: deleteWalkCreatorQuestion
      description: |
        Deletes a question. Requires template EDIT access. Mirrors legacy POST /api/v2/questionGroup/deleteQuestion.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Question under question.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorQuestionSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/presets:
    post:
      tags:
      - WalkCreatorPreset
      summary: List question-options presets
      operationId: getWalkCreatorQuestionOptionsPreset
      description: |
        Returns presets. Mirrors legacy POST /api/v2/preset/getQuestionOptionsPreset. Reorder remains at /presets/reorder.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Presets under presets.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorPresetsSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/presets/save:
    post:
      tags:
      - WalkCreatorPreset
      summary: Save question-options preset
      operationId: saveWalkCreatorQuestionOptionsPreset
      description: |
        Saves a preset (multipart). Mirrors legacy POST /api/v2/preset/saveQuestionOptionsPreset.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Preset under preset.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorPresetSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/presets/update:
    post:
      tags:
      - WalkCreatorPreset
      summary: Update question-options preset
      operationId: updateWalkCreatorQuestionOptionsPreset
      description: |
        Updates a preset (multipart). Mirrors legacy POST /api/v2/preset/updateQuestionOptionsPreset.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Preset under preset.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorPresetSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/presets/delete:
    post:
      tags:
      - WalkCreatorPreset
      summary: Delete question-options preset
      operationId: deleteWalkCreatorQuestionOptionsPreset
      description: |
        Deletes a preset. Mirrors legacy POST /api/v2/preset/deleteQuestionOptionsPreset.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              additionalProperties: true
      responses:
        '200':
          description: Preset under preset.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorPresetSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/reviewers:
    post:
      tags:
      - WalkCreatorReviewer
      summary: Get reviewer permit data
      operationId: getWalkCreatorReviewerPermitData
      description: |
        Returns reviewer permit data. Distinct from /template-approvers. Mirrors legacy POST /api/v2/reviewer/getPermitData.
        Required - entity_id (service reads entityId; React sends template modelId as entityId).
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - entity_id
              properties:
                entity_id:
                  type: string
                  description: Template/category entity id (not model_id)
                txn_category:
                  type: string
                permit_type:
                  type: string
                model_type:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Reviewers under reviewers.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorReviewersSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/reviewers/save:
    post:
      tags:
      - WalkCreatorReviewer
      summary: Save reviewer permit data
      operationId: saveWalkCreatorReviewerPermitData
      description: |
        Saves reviewer permit data (multipart). Mirrors legacy POST /api/v2/reviewer/savePermitData.
        Required - entity_id (legacy controller parity) and model_id (service persist key). React sends both.
        Authentication - X-reflexis-csrf-token-X required. Session identity only.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - entity_id
              - model_id
              properties:
                entity_id:
                  type: string
                model_id:
                  type: string
                  description: Used by ReviewerV2Service as the persist entity key
                permit_data:
                  type: string
                type:
                  type: string
                model_type:
                  type: string
              additionalProperties: true
      responses:
        '200':
          description: Reviewers under reviewers.
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCreatorReviewersSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/schedules/repeating:
    post:
      tags:
      - WalkCreatorSchedule
      summary: Get repeating schedule info
      operationId: getWalkRepeatingScheduleInfo
      description: |
        Returns repeating schedule configuration for a walk template.
        Mirrors legacy `POST /api/v2/schedule/getRepeatingScheduleInfo`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
      responses:
        '200':
          description: Success under `repeating_schedule`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkRepeatingScheduleSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/schedules/save:
    post:
      tags:
      - WalkCreatorSchedule
      summary: Save model schedule data
      operationId: saveWalkModelScheduleData
      description: |
        Saves schedule/repeating configuration for a walk template.
        Requires template **EDIT** access.
        Mirrors legacy `POST /api/v2/schedule/saveModelScheduleData`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
      responses:
        '200':
          description: Success under `schedule`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkScheduleSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/skips/save:
    post:
      tags:
      - WalkCreatorSkips
      summary: Save question skip
      operationId: saveWalkQuestionSkip
      description: |
        Saves question skip logic (skip header/details + formula data).
        Mirrors legacy `POST /api/v2/skip/saveQuestionSkip`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              - skip_data
              - formula_data
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
                skip_data:
                  type: string
                  description: JSON string of skip configuration.
                formula_data:
                  type: string
                  description: JSON string of formula/designer data for the skip.
      responses:
        '200':
          description: Success under `question_skip`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkQuestionSkipSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/skips/group-permission/validate:
    post:
      tags:
      - WalkCreatorSkips
      summary: Validate group permission for skip
      operationId: validateWalkSkipGroupPermission
      description: |
        Validates whether the given entities have permission for skip-group operations.
        Mirrors legacy `POST /api/v2/skip/validateGroupPermission`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              - entity_ids
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
                entity_ids:
                  type: string
                  description: Comma-separated entity ids to validate.
      responses:
        '200':
          description: Success under `group_permission`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkGroupPermissionSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/skips/allow-groups:
    post:
      tags:
      - WalkCreatorSkips
      summary: Get allow groups for skip
      operationId: getWalkSkipAllowGroups
      description: |
        Returns allow-group options for skip targeting for the given entities.
        Mirrors legacy `POST /api/v2/skip/getAllowGroup`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              - entity_ids
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
                entity_ids:
                  type: string
                  description: Comma-separated entity ids.
      responses:
        '200':
          description: Success under `allow_groups`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkAllowGroupsSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/skips/question-level:
    post:
      tags:
      - WalkCreatorSkips
      summary: Get question-level skip
      operationId: getWalkQuestionLevelSkip
      description: |
        Returns question-level skip configuration for a walk template.
        Mirrors legacy `POST /api/v2/skip/getQuestionLevelSkip`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
      responses:
        '200':
          description: Success under `question_level_skip`, or application-level error (`status` ER may still return HTTP
            200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkQuestionLevelSkipSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/skips/delete:
    post:
      tags:
      - WalkCreatorSkips
      summary: Delete skip
      operationId: deleteWalkSkip
      description: |
        Deletes a skip (header, details, related formula/joins) from a walk template.
        Requires template **EDIT** access.
        Mirrors legacy `POST /api/v2/skip/deleteSkip`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
                skip_id:
                  type: string
                  description: Skip id to delete (passed through to service).
      responses:
        '200':
          description: Success under `skip`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkSkipSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/skips/category-var-matrix:
    post:
      tags:
      - WalkCreatorSkips
      summary: Get category variable matrix
      operationId: getWalkCategoryVarMatrix
      description: |
        Returns category/variable matrix for skip formula design.
        When `model_id` is present, returns formula categories for that model;
        otherwise returns the domain category variable matrix.
        Mirrors legacy `POST /api/v2/skip/getCategoryVarMatrix`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: false
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                model_id:
                  type: string
                  description: Optional walk template model id. When set, returns model-scoped formula categories.
                  example: FORM_55740
                include_all_question_responses:
                  type: string
                  description: When retrieving model formula categories, whether to include all question responses.
                  example: 'false'
      responses:
        '200':
          description: Success under `category_var_matrix`, or application-level error (`status` ER may still return HTTP
            200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkCategoryVarMatrixSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/violations/projects:
    post:
      tags:
      - WalkCreatorViolations
      summary: Get violation projects
      operationId: getWalkViolationProject
      description: |
        Returns violation project configuration for a walk template.
        Mirrors legacy `POST /api/v2/violation/getViolationProject`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
      responses:
        '200':
          description: Success under `violation_project`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkViolationProjectSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/violations/tasks:
    post:
      tags:
      - WalkCreatorViolations
      summary: Get violation task data
      operationId: getWalkViolationTaskData
      description: |
        Returns violation task data for a walk template.
        Mirrors legacy `POST /api/v2/violation/getViolationTaskData`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
      responses:
        '200':
          description: Success under `violation_task`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkViolationTaskSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/violations/projects/save:
    post:
      tags:
      - WalkCreatorViolations
      summary: Save violation project
      operationId: saveWalkViolationProject
      description: |
        Saves a violation project (supports file uploads).
        Requires template **EDIT** access.
        Mirrors legacy `POST /api/v2/violation/saveViolationProject`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
      responses:
        '200':
          description: Success under `violation_project`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkViolationProjectSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/violations/tasks/save:
    post:
      tags:
      - WalkCreatorViolations
      summary: Save violation task
      operationId: saveWalkViolationTask
      description: |
        Saves a violation task (supports file uploads).
        Requires template **REMOVE** access (mirrors legacy control check).
        Mirrors legacy `POST /api/v2/violation/saveViolationTask`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
      responses:
        '200':
          description: Success under `violation_task`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkViolationTaskSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/violations/projects/delete:
    post:
      tags:
      - WalkCreatorViolations
      summary: Delete violation project
      operationId: deleteWalkViolationProject
      description: |
        Deletes a violation project from a walk template.
        Requires template **REMOVE** access.
        Mirrors legacy `POST /api/v2/violation/deleteViolationProject`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
      responses:
        '200':
          description: Success under `violation_project`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkViolationProjectSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/violations/masters/delete:
    post:
      tags:
      - WalkCreatorViolations
      summary: Delete violation master
      operationId: deleteWalkViolationMaster
      description: |
        Deletes a violation master from a walk template.
        Requires template **REMOVE** access.
        Mirrors legacy `POST /api/v2/violation/deleteViolationMaster`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
      responses:
        '200':
          description: Success under `violation_master`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkViolationMasterSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/violations/linked-survey-categories:
    post:
      tags:
      - WalkCreatorViolations
      summary: Retrieve linked survey categories
      operationId: retrieveWalkLinkedSurveyCategory
      description: |
        Returns linked survey categories available for violation feedback.
        Mirrors legacy `POST /api/v2/violation/retrieveLinkedSurveyCategory`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_type
              properties:
                model_type:
                  type: string
                  description: Model type (e.g. `W` walk, `S` survey/form).
                  example: S
      responses:
        '200':
          description: Success under `linked_survey_category`, or application-level error (`status` ER may still return HTTP
            200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkLinkedSurveyCategorySuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/violations/form-templates:
    post:
      tags:
      - WalkCreatorViolations
      summary: Get form templates for linked category
      operationId: getWalkViolationFormTemplates
      description: |
        Returns form templates for a linked survey category (violation feedback).
        Mirrors legacy `POST /api/v2/violation/getFormTemplates`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - category_id
              properties:
                category_id:
                  type: string
                  description: Linked survey category id.
                  example: '1787735704510'
      responses:
        '200':
          description: Success under `form_templates`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkFormTemplatesSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/violations/config:
    post:
      tags:
      - WalkCreatorViolations
      summary: Get violation config
      operationId: getWalkViolationConfig
      description: |
        Returns domain violation configuration used by the creator UI.
        Mirrors legacy `POST /api/v2/violation/getViolationConfig`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: false
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties: {}
      responses:
        '200':
          description: Success under `violation_config`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkViolationConfigSuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
  /walk-creator/v1/validation/review-summary:
    post:
      tags:
      - WalkCreatorValidation
      summary: Show review summary
      operationId: showWalkReviewSummary
      description: |
        Returns the template review/validation summary used before submit/approval.
        Mirrors legacy `POST /api/v2/validation/showReviewSummary`.
        Authentication — `X-reflexis-csrf-token-X` required.
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - model_id
              properties:
                model_id:
                  type: string
                  description: Walk template model id.
                  example: FORM_55740
      responses:
        '200':
          description: Success under `review_summary`, or application-level error (`status` ER may still return HTTP 200).
          content:
            application/json:
              schema:
                oneOf:
                - $ref: '#/components/schemas/WalkReviewSummarySuccessResponse'
                - $ref: '#/components/schemas/WalkApiErrorResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          $ref: '#/components/responses/InternalServerError'
