Workflow Instance Logs Query APIAPI Explorer

Introduction

Workflow Instance Logs Query API enables you to query the sequence of steps or actions taken during the processing of a workflow. This includes details such as the initiator of the workflow and the actions performed at each step. Currently, the system can only return the workflow instance log that contains approval comments.

API Version

API Version

Updated Time

Version Description

V1

2024.01.26

Initial version

API Calling

This API enables you to query the sequence of steps or actions taken during the processing of a workflow.

Request URL: https://api.jodoo.com/api/v1/workflow/instance/logs

Request Frequency: 30 times/second

Request Method: POST

URL Parameter:

Parameter

Required

Type

Description

instance_id

Yes

string

The instance ID is the same as the data ID.

types

Yes

string[]

The types of log to be returned.

Approval comment: “comment”

limit

No

number

Pagination parameter specifying the default page size of 100 logs, with a maximum of 100 logs.

skip

No

number

Pagination parameter specifying the number of logs to skip before returning results, with a default value of 0.

Sample Request:

{
    "instance_id": "659cba93489a49c06f7d4281",
    "types": [
        "comment"
    ],
    "skip": 0,
    "limit": 10
}

Response Parameter:

Parameter

Type

Description

logs

object[]

Loh list

logs[].flow_id

number

Node ID

logs[].flow_name

string

Node name

logs[].create_action

string

Create a workflow task

logs[].create_time

Date

Start time

logs[].finish_action

string

Complete a workflow task

logs[].finish_time

Date

End time

logs[].comment

string

Approval comment

logs[].signature

object

Signature

logs[].signature.url

string

Signature URL (validity: 6 days)

logs[].attachments

object[]

Attachment list

logs[].attachments[].name

string

Attachment name

logs[].attachments[].size

number

Attachment size

logs[].attachments[].mime

string

Attachment type

logs[].attachments[].url

string

Attachment URL (validity: 6 days)

logs[].operator

object

Approver/operator information. The structure of the returned data is the same as that in the Member Entity Structure.

Sample Response:

{
    "logs": [
        {
            "flow_id": 1,
            "flow_name": "Signature required",
            "create_time": "2024-01-09T03:16:35.447Z",
            "create_action": "forward",
            "finish_time": "2024-01-09T03:17:03.239Z",
            "finish_action": "forward",
            "operator": {
                "username": "Jodoo",
                "name": "Jodoo",
                "departments": [
                    1
                ],
                "type": 0,
                "status": 1
            },
            "comment": "Approval comment",
            "signature": {
                "url": "https://files.jodoo.com/FtMNaGofTPeLMFW5_5SCs8w2mX8h?e=1595347199&token=bM7UwVPyBBdPaleBZt21SWKzMylqPUpn-05jZlas:iac5fKQqYDZkF1YyvJUm4YRDPzg="
            },
            "attachments": [
                {
                    "name": "Image.jpeg",
                    "size": 74935,
                    "mime": "image/jpeg",
                    "url": "https://files.jodoo.com/FtMNaGofTPeLMFW5_5SCs8w2mX8h?e=1595347199&token=bM7UwVPyBBdPaleBZt21SWKzMylqPUpn-05jZlas:iac5fKQqYDZkF1YyvJUm4YRDPzg="
                },
                {
                    "name": "6b2cc009-141d-44c4-b5fc-5d01667ee0f8.jpg",
                    "size": 33174,
                    "mime": "image/jpeg",
                    "url": "https://files.jodoo.com/FtMNaGofTPeLMFW5_5SCs8w2mX8h?e=1595347199&token=bM7UwVPyBBdPaleBZt21SWKzMylqPUpn-05jZlas:iac5fKQqYDZkF1YyvJUm4YRDPzg="
                },
                {
                    "name": "24x24.png",
                    "size": 34281,
                    "mime": "image/png",
                    "url": "https://files.jodoo.com/FtMNaGofTPeLMFW5_5SCs8w2mX8h?e=1595347199&token=bM7UwVPyBBdPaleBZt21SWKzMylqPUpn-05jZlas:iac5fKQqYDZkF1YyvJUm4YRDPzg="
                }
            ]
        }
    ]
}

Was this information helpful?
Yes
NoNo
Need more help? Contact support