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

# 获取列表

> Queries for historic decision instances that fulfill the given parameters. 
The size of the result set can be retrieved by using the 
[Get Historic Decision Instance Count](https://docs.camunda.org/manual/7.22/reference/rest/history/decision-instance/get-decision-instance-query-count/) 
method.



## OpenAPI

````yaml GET /history/decision-instance
openapi: 3.0.2
info:
  title: ORION Platform REST API
  description: OpenApi Spec for ORION Camunda Platform REST API.
  version: 7.22.6-ee
  license:
    name: Apache License 2.0
    url: http://www.apache.org/licenses/LICENSE-2.0.html
servers:
  - url: http://{host}:{port}/{contextPath}
    description: The API server for the default process engine
    variables:
      host:
        default: localhost
      port:
        default: '8080'
      contextPath:
        default: engine-rest
  - url: http://{host}:{port}/{contextPath}/engine/{engineName}
    description: The API server for a named process engine
    variables:
      host:
        default: localhost
      port:
        default: '8080'
      contextPath:
        default: engine-rest
      engineName:
        default: default
  - url: '{url}'
    description: The API server with a custom url
    variables:
      url:
        default: ''
security:
  - basicAuth: []
tags:
  - name: Authorization
  - name: Batch
  - name: Condition
  - name: Decision Definition
  - name: Decision Requirements Definition
  - name: Deployment
  - name: Engine
  - name: Event Subscription
  - name: Execution
  - name: External Task
  - name: Filter
  - name: Group
  - name: Historic Activity Instance
  - name: Historic Batch
  - name: Historic Decision Definition
  - name: Historic Decision Instance
  - name: Historic Decision Requirements Definition
  - name: Historic Detail
  - name: Historic External Task Log
  - name: Historic Identity Link Log
  - name: Historic Incident
  - name: Historic Job Log
  - name: Historic Process Definition
  - name: Historic Process Instance
  - name: Historic Task Instance
  - name: Historic User Operation Log
  - name: Historic Variable Instance
  - name: History Cleanup
  - name: Identity
  - name: Incident
  - name: Job
  - name: Job Definition
  - name: Message
  - name: Metrics
  - name: Migration
  - name: Modification
  - name: Process Definition
  - name: Process Instance
  - name: Signal
  - name: Schema Log
  - name: Task
  - name: Task Attachment
  - name: Task Comment
  - name: Task Identity Link
  - name: Task Local Variable
  - name: Task Variable
  - name: Telemetry
  - name: Tenant
  - name: User
  - name: Variable Instance
  - name: Version
externalDocs:
  description: Find out more about ORION Rest API
  url: https://docs.eorion.com
paths:
  /history/decision-instance:
    get:
      tags:
        - Historic Decision Instance
      summary: Get Historic Decision Instances
      description: >-
        Queries for historic decision instances that fulfill the given
        parameters. 

        The size of the result set can be retrieved by using the 

        [Get Historic Decision Instance
        Count](https://docs.camunda.org/manual/7.22/reference/rest/history/decision-instance/get-decision-instance-query-count/) 

        method.
      operationId: getHistoricDecisionInstances
      parameters:
        - name: decisionInstanceId
          in: query
          schema:
            type: string
          description: Filter by decision instance id.
        - name: decisionInstanceIdIn
          in: query
          schema:
            type: string
          description: >-
            Filter by decision instance ids. Must be a comma-separated list of
            decision instance ids.
        - name: decisionDefinitionId
          in: query
          schema:
            type: string
          description: Filter by the decision definition the instances belongs to.
        - name: decisionDefinitionIdIn
          in: query
          schema:
            type: string
          description: >-
            Filter by the decision definitions the instances belongs to. Must be
            a

            comma-separated list of decision definition ids.
        - name: decisionDefinitionKey
          in: query
          schema:
            type: string
          description: >-
            Filter by the key of the decision definition the instances belongs
            to.
        - name: decisionDefinitionKeyIn
          in: query
          schema:
            type: string
          description: >-
            Filter by the keys of the decision definition the instances belongs
            to. Must be a comma-

            separated list of decision definition keys.
        - name: decisionDefinitionName
          in: query
          schema:
            type: string
          description: >-
            Filter by the name of the decision definition the instances belongs
            to.
        - name: decisionDefinitionNameLike
          in: query
          schema:
            type: string
          description: >-
            Filter by the name of the decision definition the instances belongs
            to, that the parameter

            is a substring of.
        - name: processDefinitionId
          in: query
          schema:
            type: string
          description: Filter by the process definition the instances belongs to.
        - name: processDefinitionKey
          in: query
          schema:
            type: string
          description: >-
            Filter by the key of the process definition the instances belongs
            to.
        - name: processInstanceId
          in: query
          schema:
            type: string
          description: Filter by the process instance the instances belongs to.
        - name: caseDefinitionId
          in: query
          schema:
            type: string
          description: Filter by the case definition the instances belongs to.
        - name: caseDefinitionKey
          in: query
          schema:
            type: string
          description: Filter by the key of the case definition the instances belongs to.
        - name: caseInstanceId
          in: query
          schema:
            type: string
          description: Filter by the case instance the instances belongs to.
        - name: activityIdIn
          in: query
          schema:
            type: string
          description: |-
            Filter by the activity ids the instances belongs to.
            Must be a comma-separated list of acitvity ids.
        - name: activityInstanceIdIn
          in: query
          schema:
            type: string
          description: |-
            Filter by the activity instance ids the instances belongs to.
            Must be a comma-separated list of acitvity instance ids.
        - name: tenantIdIn
          in: query
          schema:
            type: string
          description: >-
            Filter by a comma-separated list of tenant ids. A historic decision
            instance must have one

            of the given tenant ids.
        - name: withoutTenantId
          in: query
          schema:
            type: boolean
          description: >-
            Only include historic decision instances that belong to no tenant.
            Value may only be

            `true`, as `false` is the default behavior.
        - name: evaluatedBefore
          in: query
          schema:
            type: string
            format: date-time
          description: >-
            Restrict to instances that were evaluated before the given date.

            By
            [default](https://docs.camunda.org/manual/7.22/reference/rest/overview/date-format/),
            the date must have the format `yyyy-MM-

            dd'T'HH:mm:ss.SSSZ`, e.g., `2013-01-23T14:42:45.000+0200`.
        - name: evaluatedAfter
          in: query
          schema:
            type: string
            format: date-time
          description: >-
            Restrict to instances that were evaluated after the given date.

            By
            [default](https://docs.camunda.org/manual/7.22/reference/rest/overview/date-format/),
            the date must have the format `yyyy-MM-

            dd'T'HH:mm:ss.SSSZ`, e.g., `2013-01-23T14:42:45.000+0200`.
        - name: userId
          in: query
          schema:
            type: string
          description: Restrict to instances that were evaluated by the given user.
        - name: rootDecisionInstanceId
          in: query
          schema:
            type: string
          description: |-
            Restrict to instances that have a given root decision instance id.
            This also includes the decision instance with the given id.
        - name: rootDecisionInstancesOnly
          in: query
          schema:
            type: boolean
          description: >-
            Restrict to instances those are the root decision instance of an
            evaluation.

            Value may only be `true`, as `false` is the default behavior.
        - name: decisionRequirementsDefinitionId
          in: query
          schema:
            type: string
          description: >-
            Filter by the decision requirements definition the instances belongs
            to.
        - name: decisionRequirementsDefinitionKey
          in: query
          schema:
            type: string
          description: >-
            Filter by the key of the decision requirements definition the
            instances belongs to.
        - name: includeInputs
          in: query
          schema:
            type: boolean
          description: |-
            Include input values in the result.
            Value may only be `true`, as `false` is the default behavior.
        - name: includeOutputs
          in: query
          schema:
            type: boolean
          description: |-
            Include output values in the result.
            Value may only be `true`, as `false` is the default behavior.
        - name: disableBinaryFetching
          in: query
          schema:
            type: boolean
          description: |-
            Disables fetching of byte array input and output values.
            Value may only be `true`, as `false` is the default behavior.
        - name: disableCustomObjectDeserialization
          in: query
          schema:
            type: boolean
          description: >-
            Disables deserialization of input and output values that are custom
            objects.

            Value may only be `true`, as `false` is the default behavior.
        - name: sortBy
          in: query
          schema:
            enum:
              - evaluationTime
              - tenantId
            type: string
          description: |-
            Sort the results lexicographically by a given criterion.
            Must be used in conjunction with the sortOrder parameter.
        - name: sortOrder
          in: query
          schema:
            enum:
              - asc
              - desc
            type: string
          description: >-
            Sort the results in a given order. Values may be asc for ascending
            order or desc for descending order.

            Must be used in conjunction with the sortBy parameter.
        - name: firstResult
          in: query
          schema:
            type: integer
          description: >-
            Pagination of results. Specifies the index of the first result to
            return.
        - name: maxResults
          in: query
          schema:
            type: integer
          description: >-
            Pagination of results. Specifies the maximum number of results to
            return.

            Will return less results if there are no more results left.
      responses:
        '200':
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/HistoricDecisionInstanceDto'
              examples:
                example-1:
                  summary: request including inputs and outputs
                  description: >-
                    GET
                    `/history/decision-instance?includeInputs=true&includeOutputs=true`
                  value:
                    - activityId: assignApprover
                      activityInstanceId: assignApprover:67e9de1e-579d-11e5-9848-f0def1e59da8
                      collectResultValue: null
                      decisionDefinitionId: >-
                        invoice-assign-approver:1:4c864d79-579d-11e5-9848-f0def1e59da8
                      decisionDefinitionKey: invoice-assign-approver
                      decisionDefinitionName: Assign Approver
                      evaluationTime: 2015-09-10T11:22:06.000+0200
                      removalTime: null
                      id: 67ea2c3f-579d-11e5-9848-f0def1e59da8
                      inputs:
                        - clauseId: clause1
                          clauseName: Invoice Amount
                          decisionInstanceId: 67ea2c3f-579d-11e5-9848-f0def1e59da8
                          errorMessage: null
                          id: 67ea2c41-579d-11e5-9848-f0def1e59da8
                          type: Double
                          createTime: 2015-09-10T11:22:06.000+0200
                          removalTime: null
                          rootProcessInstanceId: aRootProcessInstanceId
                          value: 123
                          valueInfo: {}
                        - clauseId: clause2
                          clauseName: Invoice Category
                          decisionInstanceId: 67ea2c3f-579d-11e5-9848-f0def1e59da8
                          errorMessage: null
                          id: 67ea2c40-579d-11e5-9848-f0def1e59da8
                          type: String
                          createTime: 2015-09-10T11:22:06.000+0200
                          removalTime: null
                          rootProcessInstanceId: aRootProcessInstanceId
                          value: Misc
                          valueInfo: {}
                      outputs:
                        - clauseId: clause3
                          clauseName: Approver Group
                          decisionInstanceId: 67ea2c3f-579d-11e5-9848-f0def1e59da8
                          errorMessage: null
                          id: 67ea2c42-579d-11e5-9848-f0def1e59da8
                          ruleId: DecisionRule_1of5a87
                          ruleOrder: 1
                          type: String
                          createTime: 2015-09-10T11:22:06.000+0200
                          removalTime: null
                          rootProcessInstanceId: aRootProcessInstanceId
                          value: accounting
                          valueInfo: {}
                          variableName: result
                      processDefinitionId: invoice:1:4c6e3197-579d-11e5-9848-f0def1e59da8
                      processDefinitionKey: invoice
                      processInstanceId: 67e98fec-579d-11e5-9848-f0def1e59da8
                      rootProcessInstanceId: f8259e5d-ab9d-11e8-8449-e4a7a094a9d6
                      caseDefinitionId: null
                      caseDefinitionKey: null
                      caseInstanceId: null
                      tenantId: null
                      userId: null
                      rootDecisionInstanceId: null
                      decisionRequirementsDefinitionId: null
                      decisionRequirementsDefinitionKey: null
          description: Request successful.
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ExceptionDto'
          description: >-
            Returned if some of the query parameters are invalid, for example if
            a `sortOrder`

            parameter is supplied, but no `sortBy`. See the

            [Introduction](https://docs.camunda.org/manual/7.22/reference/rest/overview/#error-handling)

            for the error response format.
components:
  schemas:
    HistoricDecisionInstanceDto:
      type: object
      properties:
        id:
          type: string
          nullable: true
          description: The id of the decision instance.
        decisionDefinitionId:
          type: string
          nullable: true
          description: >-
            The id of the decision definition that this decision instance
            belongs to.
        decisionDefinitionKey:
          type: string
          nullable: true
          description: >-
            The key of the decision definition that this decision instance
            belongs to.
        decisionDefinitionName:
          type: string
          nullable: true
          description: >-
            The name of the decision definition that this decision instance
            belongs to.
        evaluationTime:
          type: string
          format: date-time
          nullable: true
          description: >-
            The time the instance was evaluated. 

            [Default
            format](https://docs.camunda.org/manual/7.22/reference/rest/overview/date-format/)
            `yyyy-MM-dd'T'HH:mm:ss.SSSZ`.
        removalTime:
          type: string
          format: date-time
          nullable: true
          description: >-
            The time after which the instance should be removed by the History
            Cleanup job.

            [Default
            format](https://docs.camunda.org/manual/7.22/reference/rest/overview/date-format/)
            `yyyy-MM-dd'T'HH:mm:ss.SSSZ`.
        processDefinitionId:
          type: string
          nullable: true
          description: >-
            The id of the process definition that this decision instance belongs
            to.
        processDefinitionKey:
          type: string
          nullable: true
          description: >-
            The key of the process definition that this decision instance
            belongs to.
        processInstanceId:
          type: string
          nullable: true
          description: >-
            The id of the process instance that this decision instance belongs
            to.
        caseDefinitionId:
          type: string
          nullable: true
          description: >-
            The id of the case definition that this decision instance belongs
            to.
        caseDefinitionKey:
          type: string
          nullable: true
          description: >-
            The key of the case definition that this decision instance belongs
            to.
        caseInstanceId:
          type: string
          nullable: true
          description: The id of the case instance that this decision instance belongs to.
        activityId:
          type: string
          nullable: true
          description: The id of the activity that this decision instance belongs to.
        activityInstanceId:
          type: string
          nullable: true
          description: >-
            The id of the activity instance that this decision instance belongs
            to.
        tenantId:
          type: string
          nullable: true
          description: The tenant id of the historic decision instance.
        userId:
          type: string
          nullable: true
          description: >-
            The id of the authenticated user that has evaluated this decision
            instance without

            a process or case instance.
        inputs:
          type: array
          nullable: true
          items:
            $ref: '#/components/schemas/HistoricDecisionInputInstanceDto'
          description: >-
            The list of decision input values. **Only exists** if
            `includeInputs`

            was set to `true` in the query.
        outputs:
          type: array
          nullable: true
          items:
            $ref: '#/components/schemas/HistoricDecisionOutputInstanceDto'
          description: >-
            The list of decision output values. **Only exists** if
            `includeOutputs`

            was set to `true` in the query.
        collectResultValue:
          type: number
          format: double
          nullable: true
          description: >-
            The result of the collect aggregation of the decision result if
            used. `null` if no

            aggregation was used.
        rootDecisionInstanceId:
          type: string
          nullable: true
          description: >-
            The decision instance id of the evaluated root decision. Can be
            `null` if this

            instance is the root decision instance of the evaluation.
        rootProcessInstanceId:
          type: string
          nullable: true
          description: >-
            The process instance id of the root process instance that initiated
            the evaluation

            of this decision. Can be `null` if this decision instance is not

            evaluated as part of a BPMN process.
        decisionRequirementsDefinitionId:
          type: string
          nullable: true
          description: >-
            The id of the decision requirements definition that this decision
            instance belongs

            to.
        decisionRequirementsDefinitionKey:
          type: string
          nullable: true
          description: >-
            The key of the decision requirements definition that this decision
            instance belongs

            to.
    ExceptionDto:
      title: ExceptionDto
      type: object
      properties:
        type:
          type: string
          nullable: true
          description: An exception class indicating the occurred error.
        message:
          type: string
          nullable: true
          description: A detailed message of the error.
        code:
          type: number
          description: >-
            The code allows your client application to identify the error in an
            automated fashion.

            You can look up the meaning of all built-in codes and learn how to
            add custom codes

            in the [User
            Guide](https://docs.camunda.org/manual/7.22/user-guide/process-engine/error-handling/#exception-codes).
    HistoricDecisionInputInstanceDto:
      type: object
      properties:
        id:
          type: string
          nullable: true
          description: The id of the decision input value.
        decisionInstanceId:
          type: string
          nullable: true
          description: The id of the decision instance the input value belongs to.
        clauseId:
          type: string
          nullable: true
          description: The id of the clause the input value belongs to.
        clauseName:
          type: string
          nullable: true
          description: The name of the clause the input value belongs to.
        errorMessage:
          type: string
          nullable: true
          description: >-
            An error message in case a Java Serialized Object could not be
            de-serialized.
        type:
          type: string
          nullable: true
          description: The value type of the variable.
        createTime:
          type: string
          format: date-time
          nullable: true
          description: >-
            The time the variable was inserted. 

            [Default
            format](https://docs.camunda.org/manual/7.22/reference/rest/overview/date-format/)
            `yyyy-MM-dd'T'HH:mm:ss.SSSZ`.
        removalTime:
          type: string
          format: date-time
          nullable: true
          description: >-
            The time after which the entry should be removed by the History
            Cleanup job.

            [Default
            format](https://docs.camunda.org/manual/7.22/reference/rest/overview/date-format/)
            `yyyy-MM-dd'T'HH:mm:ss.SSSZ`.
        rootProcessInstanceId:
          type: string
          nullable: true
          description: >-
            The process instance id of the root process instance that initiated
            the process

            containing this entry.
        value:
          type: object
          description: |-
            The variable's value. Value differs depending on the variable's type
            and on the `disableCustomObjectDeserialization` parameter.
        valueInfo:
          type: object
          additionalProperties: true
          description: |-
            A JSON object containing additional, value-type-dependent
            properties.

            For variables of type `Object`, the following properties are
            returned:

            * `objectTypeName`: A string representation of the object's type
            name.

            * `serializationDataFormat`: The serialization format used to store
            the variable.
    HistoricDecisionOutputInstanceDto:
      type: object
      properties:
        id:
          type: string
          nullable: true
          description: The id of the decision output value.
        decisionInstanceId:
          type: string
          nullable: true
          description: The id of the decision instance the output value belongs to.
        clauseId:
          type: string
          nullable: true
          description: The id of the clause the output value belongs to.
        clauseName:
          type: string
          nullable: true
          description: The name of the clause the output value belongs to.
        ruleId:
          type: string
          nullable: true
          description: The id of the rule the output value belongs to.
        ruleOrder:
          type: integer
          format: int32
          nullable: true
          description: The order of the rule the output value belongs to.
        errorMessage:
          type: string
          nullable: true
          description: >-
            An error message in case a Java Serialized Object could not be
            de-serialized.
        variableName:
          type: string
          nullable: true
          description: The name of the output variable.
        type:
          type: string
          nullable: true
          description: The value type of the variable.
        createTime:
          type: string
          format: date-time
          nullable: true
          description: >-
            The time the variable was inserted. 

            [Default
            format](https://docs.camunda.org/manual/7.22/reference/rest/overview/date-format/)
            `yyyy-MM-dd'T'HH:mm:ss.SSSZ`.
        removalTime:
          type: string
          format: date-time
          nullable: true
          description: >-
            The time after which the entry should be removed by the History
            Cleanup job.

            [Default
            format](https://docs.camunda.org/manual/7.22/reference/rest/overview/date-format/)
            `yyyy-MM-dd'T'HH:mm:ss.SSSZ`.
        rootProcessInstanceId:
          type: string
          nullable: true
          description: >-
            The process instance id of the root process instance that initiated
            the process

            containing this entry.
        value:
          type: object
          description: |-
            The variable's value. Value differs depending on the variable's type
            and on the `disableCustomObjectDeserialization` parameter.
        valueInfo:
          type: object
          additionalProperties: true
          description: |-
            A JSON object containing additional, value-type-dependent
            properties.

            For variables of type `Object`, the following properties are
            returned:

            * `objectTypeName`: A string representation of the object's type
            name.

            * `serializationDataFormat`: The serialization format used to store
            the variable.
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic

````