> ## 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.

# 根据Id获取

> Retrieves a historic decision instance by id, according to the 
`HistoricDecisionInstance` interface in the engine.



## OpenAPI

````yaml GET /history/decision-instance/{id}
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/{id}:
    get:
      tags:
        - Historic Decision Instance
      summary: Get Historic Decision Instance
      description: |-
        Retrieves a historic decision instance by id, according to the 
        `HistoricDecisionInstance` interface in the engine.
      operationId: getHistoricDecisionInstance
      parameters:
        - name: id
          in: path
          schema:
            type: string
          required: true
          description: The id of the historic decision instance to be retrieved.
        - 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.
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HistoricDecisionInstanceDto'
              examples:
                example-1:
                  summary: request including inputs and outputs
                  description: >-
                    GET
                    `/history/decision-instance/aDecisionInstId?includeInput=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.
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ExceptionDto'
          description: >-
            Historic decision instance with given id does not exist. 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

````