---
title: "Get complete approval history for an order"
method: GET
path: "/orders/{orderId}/approvalHistory"
tags: ["Approvals"]
---

# Get complete approval history for an order

`GET /orders/{orderId}/approvalHistory`

Returns comprehensive approval workflow history including all submission attempts and approver activity. 

**Important:** This endpoint returns ONLY approval domain data with user IDs and comment IDs as references. To get full details:
- User details: Call GET /users with user IDs from this response
- Order details: Call GET /orders/{orderId}
- Comment messages: Call GET /orders/{orderId}/comments

The response includes:
- All submission attempts (if order was rejected and resubmitted)
- All workflows triggered for each submission
- Detailed approval states with approver user IDs (not names)
- Summary statistics across all attempts

## Path parameters

- `orderId` string, required

## Response `200`

Successfully retrieved approval history

- OrderApprovalHistoryResponse — Complete approval history for an order (approval domain only)
  - `orderId` string, required — Order ID reference
  - `orderStatus` 'DRAFT' | 'SUBMITTED' | 'APPROVED' | 'EXECUTED' | 'EXPIRED', required — Status of the order
  - `currentAttempt` integer, required — Current approval attempt number
  - `currentSubmission` ApprovalSubmissionJson — Single approval submission attempt (approval domain only)
    - `attemptNumber` integer, required — Submission attempt number/version
    - `submittedAt` integer, required — Timestamp (in epoch seconds) when submitted
    - `submittedBy` string — Email of user who submitted
    - `submitterNote` string — Submission note text
    - `status` 'INACTIVE' | 'AWAITING_APPROVAL' | 'ADMIN_BYPASS' | 'NOT_APPLICABLE' | 'REJECTED' | 'APPROVED' | 'CANCELLED' | 'NEEDS_APPROVAL' | 'FULLY_APPROVED' | 'PENDING' | 'AUTO_APPROVED' | 'ERROR_ORDER_OWNER_IS_MISSING_TO_FIND_APPROVAL_SEGMENT' | 'ERROR_ORDER_OWNER_NOT_PART_OF_ANY_APPROVAL_SEGMENT' | 'ERROR_ORDER_OWNER_PART_OF_MULTIPLE_APPROVAL_SEGMENTS' | 'ERROR_ORDER_OWNER_NOT_PART_OF_APPROVAL_SEGMENT_SELECTED_ON_ORDER', required — Status of this submission
    - `fullyApprovedAt` integer — Timestamp (in epoch seconds) when fully approved, null if not approved
    - `rejectedAt` integer — Timestamp (in epoch seconds) when rejected, null if not rejected
    - `totalApprovalTime` integer — Total approval time in seconds (null if not completed)
    - `workflows` WorkflowJson[] — List of workflows triggered for this submission
      - `workflowId` string, required — Approval flow ID
      - `workflowName` string, required — Human-readable workflow name
      - `smartApprovalEnabled` boolean — Whether smart approval is enabled
      - `status` string, required — Current workflow status
      - `triggeredAt` integer, required — Timestamp (in epoch seconds) when workflow was triggered
      - `completedAt` integer — Timestamp (in epoch seconds) when workflow completed, null if in progress
      - `totalDuration` integer — Total workflow duration in seconds, null if not completed
      - `approvers` ApproverJson[] — List of approvers for this workflow
        - `level` integer, required — Approval level/sequence
        - `approver` string — Approver user ID or email
        - `status` 'INACTIVE' | 'AWAITING_APPROVAL' | 'ADMIN_BYPASS' | 'NOT_APPLICABLE' | 'REJECTED' | 'APPROVED' | 'CANCELLED' | 'NEEDS_APPROVAL' | 'FULLY_APPROVED' | 'PENDING' | 'AUTO_APPROVED' | 'ERROR_ORDER_OWNER_IS_MISSING_TO_FIND_APPROVAL_SEGMENT' | 'ERROR_ORDER_OWNER_NOT_PART_OF_ANY_APPROVAL_SEGMENT' | 'ERROR_ORDER_OWNER_PART_OF_MULTIPLE_APPROVAL_SEGMENTS' | 'ERROR_ORDER_OWNER_NOT_PART_OF_APPROVAL_SEGMENT_SELECTED_ON_ORDER', required — Approval status
        - `assignedAt` integer — Timestamp (in epoch seconds) when task was assigned
        - `respondedAt` integer — Timestamp (in epoch seconds) when approver responded, null if pending
        - `duration` integer — Duration from assignment to response in seconds, null if not responded
        - `originalApprovalAt` integer — Original approval timestamp (in epoch seconds) for smart approvals
        - `approverNote` string — Comment/note from approver
  - `approvalHistory` ApprovalSubmissionJson[] — Historical approval submissions (previous attempts, if any)
    - `attemptNumber` integer, required — Submission attempt number/version
    - `submittedAt` integer, required — Timestamp (in epoch seconds) when submitted
    - `submittedBy` string — Email of user who submitted
    - `submitterNote` string — Submission note text
    - `status` 'INACTIVE' | 'AWAITING_APPROVAL' | 'ADMIN_BYPASS' | 'NOT_APPLICABLE' | 'REJECTED' | 'APPROVED' | 'CANCELLED' | 'NEEDS_APPROVAL' | 'FULLY_APPROVED' | 'PENDING' | 'AUTO_APPROVED' | 'ERROR_ORDER_OWNER_IS_MISSING_TO_FIND_APPROVAL_SEGMENT' | 'ERROR_ORDER_OWNER_NOT_PART_OF_ANY_APPROVAL_SEGMENT' | 'ERROR_ORDER_OWNER_PART_OF_MULTIPLE_APPROVAL_SEGMENTS' | 'ERROR_ORDER_OWNER_NOT_PART_OF_APPROVAL_SEGMENT_SELECTED_ON_ORDER', required — Status of this submission
    - `fullyApprovedAt` integer — Timestamp (in epoch seconds) when fully approved, null if not approved
    - `rejectedAt` integer — Timestamp (in epoch seconds) when rejected, null if not rejected
    - `totalApprovalTime` integer — Total approval time in seconds (null if not completed)
    - `workflows` WorkflowJson[] — List of workflows triggered for this submission
      - `workflowId` string, required — Approval flow ID
      - `workflowName` string, required — Human-readable workflow name
      - `smartApprovalEnabled` boolean — Whether smart approval is enabled
      - `status` string, required — Current workflow status
      - `triggeredAt` integer, required — Timestamp (in epoch seconds) when workflow was triggered
      - `completedAt` integer — Timestamp (in epoch seconds) when workflow completed, null if in progress
      - `totalDuration` integer — Total workflow duration in seconds, null if not completed
      - `approvers` ApproverJson[] — List of approvers for this workflow
        - `level` integer, required — Approval level/sequence
        - `approver` string — Approver user ID or email
        - `status` 'INACTIVE' | 'AWAITING_APPROVAL' | 'ADMIN_BYPASS' | 'NOT_APPLICABLE' | 'REJECTED' | 'APPROVED' | 'CANCELLED' | 'NEEDS_APPROVAL' | 'FULLY_APPROVED' | 'PENDING' | 'AUTO_APPROVED' | 'ERROR_ORDER_OWNER_IS_MISSING_TO_FIND_APPROVAL_SEGMENT' | 'ERROR_ORDER_OWNER_NOT_PART_OF_ANY_APPROVAL_SEGMENT' | 'ERROR_ORDER_OWNER_PART_OF_MULTIPLE_APPROVAL_SEGMENTS' | 'ERROR_ORDER_OWNER_NOT_PART_OF_APPROVAL_SEGMENT_SELECTED_ON_ORDER', required — Approval status
        - `assignedAt` integer — Timestamp (in epoch seconds) when task was assigned
        - `respondedAt` integer — Timestamp (in epoch seconds) when approver responded, null if pending
        - `duration` integer — Duration from assignment to response in seconds, null if not responded
        - `originalApprovalAt` integer — Original approval timestamp (in epoch seconds) for smart approvals
        - `approverNote` string — Comment/note from approver
  - `summary` ApprovalSummaryJson — Summary statistics across all approval attempts
    - `totalAttempts` integer, required — Total number of submission attempts
    - `firstSubmittedAt` integer — Timestamp (in epoch seconds) of first submission
    - `lastUpdatedAt` integer — Timestamp (in epoch seconds) of final update
    - `totalTimeSeconds` integer — Total time from first submission to last update in seconds
    - `totalWorkflows` integer — Total number of unique workflows triggered across all attempts

## Other responses

- `404` — Order not found
- `500` — Internal server error

---

[API](https://skmtc.net/dealhub/apis/quote-api.md) · [All operations](https://skmtc.net/dealhub/apis/quote-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/dealhub/quote-api/versions/c30f5b9fbfab/schema)
