获取工单详情
提供获取工单详情的功能.
地址
GET /v2/accounts/tickets/:ticket_id
鉴权
Authorization: Bearer base64(api_key:api_secret)
请求头
curl --request GET \
--url https://livedesk.engagelab.com/v2/accounts/tickets/:ticket_id \
--H "Content-Type: application/json" \
--H "Authorization: Bearer base64(api_key:api_secret)"
curl --request GET \
--url https://livedesk.engagelab.com/v2/accounts/tickets/:ticket_id \
--H "Content-Type: application/json" \
--H "Authorization: Bearer base64(api_key:api_secret)"
This code block in the floating window
路径参数
| 字段 | 类型 | 必填 | 描述 |
|---|---|---|---|
| ticket_id | String | 是 | 工单ID。 |
响应示例
{
"code": 0,
"message": "Success",
"data": {
"ticket_id": "tk_20251104_789abc",
"title": "打印机卡纸,无法打印",
"description": "客户反映A4纸卡在出纸口,急需处理。",
"attachments": [
{
"file_name": "error-photo.jpg",
"file_type": "image/jpeg",
"file_url": "https://example.com/files/error.jpg",
"file_size": 1220
}
],
"status": "open",
"priority": "high",
"ticket_type": "incident",
"requester": {
"euid": "contact_12345",
"name": "张三",
"email": "zhangsan@example.com",
"phone": "+8613900000000",
"channel_contacts": {
"channel_id": "inbox_100",
"contact_id": "-1001234567890",
"sub_contact_id": "23232323",
"followers": ["u_12345", "u_67890"]
}
},
"submitter": {
"id": "u_99999"
}
"assignment_team": {
"id": 5,
"name": "IT支持"
},
"custom_fields": {
"device_sn": "PRN-2024-001"
},
"conversation_list": [
{
"message_id": "msg_20251104_001",
"sender": {
"id": "u_12345",
"type": "internal_member",
"name": "客服小李"
},
"content": "我们已收到你的反馈,正在处理。",
"content_type": "text",
"attachments": [
{
"file_type": "image/jpeg",
"file_url": "https://example.com/files/progress.jpg"
},
{
"file_type": "application/pdf",
"file_url": "https://example.com/files/report.pdf"
}
],
"sent_at": "2025-11-19T05:55:25Z",
"is_internal": false
}
],
"status_changes": [
{
"to_status": "in_progress",
"changed_at": "2025-11-04T09:25:00+08:00",
"changed_by_type": "user",
"changed_by_id": "u_12345"
},
{
"to_status": "resolved",
"changed_at": "2025-11-04T10:30:00+08:00",
"changed_by_type": "system"
}
],
"tags": ["printer", "hardware"],
"sla": {
"first_response_due": "2025-11-04T10:00:00+08:00",
"resolution_due": "2025-11-05T18:00:00+08:00",
"first_response_at": "2025-11-04T09:20:00+08:00",
"breached": false
},
"followers": [
{"id": "u_12345"},
{"id": "u_67890"}
],
"satisfactions": {
"rating": 5,
"feedback": "处理很快",
"submitted_at": "2025-11-05T09:20:00+08:00"
},
"created_at": "2025-11-04T09:15:22+08:00",
"updated_at": "2025-11-04T09:18:45+08:00",
"resolved_at": null,
"closed_at": null
}
}
{
"code": 0,
"message": "Success",
"data": {
"ticket_id": "tk_20251104_789abc",
"title": "打印机卡纸,无法打印",
"description": "客户反映A4纸卡在出纸口,急需处理。",
"attachments": [
{
"file_name": "error-photo.jpg",
"file_type": "image/jpeg",
"file_url": "https://example.com/files/error.jpg",
"file_size": 1220
}
],
"status": "open",
"priority": "high",
"ticket_type": "incident",
"requester": {
"euid": "contact_12345",
"name": "张三",
"email": "zhangsan@example.com",
"phone": "+8613900000000",
"channel_contacts": {
"channel_id": "inbox_100",
"contact_id": "-1001234567890",
"sub_contact_id": "23232323",
"followers": ["u_12345", "u_67890"]
}
},
"submitter": {
"id": "u_99999"
}
"assignment_team": {
"id": 5,
"name": "IT支持"
},
"custom_fields": {
"device_sn": "PRN-2024-001"
},
"conversation_list": [
{
"message_id": "msg_20251104_001",
"sender": {
"id": "u_12345",
"type": "internal_member",
"name": "客服小李"
},
"content": "我们已收到你的反馈,正在处理。",
"content_type": "text",
"attachments": [
{
"file_type": "image/jpeg",
"file_url": "https://example.com/files/progress.jpg"
},
{
"file_type": "application/pdf",
"file_url": "https://example.com/files/report.pdf"
}
],
"sent_at": "2025-11-19T05:55:25Z",
"is_internal": false
}
],
"status_changes": [
{
"to_status": "in_progress",
"changed_at": "2025-11-04T09:25:00+08:00",
"changed_by_type": "user",
"changed_by_id": "u_12345"
},
{
"to_status": "resolved",
"changed_at": "2025-11-04T10:30:00+08:00",
"changed_by_type": "system"
}
],
"tags": ["printer", "hardware"],
"sla": {
"first_response_due": "2025-11-04T10:00:00+08:00",
"resolution_due": "2025-11-05T18:00:00+08:00",
"first_response_at": "2025-11-04T09:20:00+08:00",
"breached": false
},
"followers": [
{"id": "u_12345"},
{"id": "u_67890"}
],
"satisfactions": {
"rating": 5,
"feedback": "处理很快",
"submitted_at": "2025-11-05T09:20:00+08:00"
},
"created_at": "2025-11-04T09:15:22+08:00",
"updated_at": "2025-11-04T09:18:45+08:00",
"resolved_at": null,
"closed_at": null
}
}
This code block in the floating window
响应参数
| 字段 | 类型 | 必填 | 描述 |
|---|---|---|---|
| ticket_id | String | 是 | 工单唯一ID |
| title | String | 是 | 工单标题 |
| description | String | 是 | 工单详细描述(支持 Markdown |
| attachments | Array | 否 | 工单级附件列表 |
| status | String | 是 | 工单状态:open/in_progress/resolved/closed 等。 |
| priority | String | 否 | 优先级:low/medium/high/urgent。 |
| ticket_type | String | 否 | 工单类型:incident/question/problem/task |
| requester | Object | 是 | 请求人(客户)信息 |
| submitter | Object | 否 | 提交人工单的内部成员。 |
| assignment_team | Object | 否 | 分配团队信息。 |
| custom_fields | Object | 否 | 自定义字段(如设备序列号、订单号等)。 |
| conversation_list | Array | 是 | 工单内所有消息历史。 |
| status_changes | Array | 否 | 工单状态变更记录。 |
| tags | Array | 否 | 工单标签。 |
| sla | Object | 否 | SLA 服务水平协议信息。 |
| followers | Array | 否 | 关注者列表。 |
| satisfactions | Object | 否 | 满意度调查结果。 |
| created_at | String | 是 | 工单创建时间(ISO8601。 |
| updated_at | String | 是 | 工单最后更新时间。 |
| resolved_at | String | 否 | 解决时间(未解决为 null)。 |
| closed_at | String | 否 | 关闭时间(未关闭为 null)。 |
attachments
| 字段 | 类型 | 必填 | 描述 |
|---|---|---|---|
| file_name | String | 是 | 文件名。 |
| file_type | String | 是 | MIME。 |
| file_url | String | 是 | 文件地址。 |
| file_size | String | 是 | 大小。 |
requester
| 字段 | 类型 | 必填 | 描述 |
|---|---|---|---|
| euid | String | 否 | 联系人唯一ID。 |
| name | String | 否 | 姓名。 |
| String | 否 | 邮箱。 | |
| phone | String | 否 | 电话。 |
| channel_contacts | Object | 否 | 渠道联系人映射(与 euid 至少存在一个)。 |
submitter
| 字段 | 类型 | 必填 | 描述 |
|---|---|---|---|
| submitter.id | String | 是 | 提交者用户 ID 。 |
assignment_team
| 字段 | 类型 | 必填 | 描述 |
|---|---|---|---|
| id | Integer | 是 | 团队 ID 。 |
| name | String | 是 | 团队名称。 |
custom_fields
| 字段 | 类型 | 必填 | 描述 |
|---|---|---|---|
| device_sn | String | 是 | 关注者ID。 |
| location | String | 否 | 关注者名称。 |
conversation_list
| 字段 | 类型 | 必填 | 描述 |
|---|---|---|---|
| message_id | String | 是 | 消息唯一 ID。 |
| sender | Object | 是 | 发送者信息 |
| content | String | 否 | 消息文本内容 |
| content_type | String | 是 | 内容类型:text/image/file/audio/video |
| attachments | Array[Object] | 否 | 消息附件列表 |
| sent_at | String | 是 | 发送时间(ISO8601) |
| is_internal | boolean | 是 | 是否为内部消息(客户不可见) |
sender
| 字段 | 类型 | 必填 | 描述 |
|---|---|---|---|
| id | String | 是 | 发送者 ID 。 |
| type | String | 是 | 发送者类型:internal_member/system/bot。 |
| name | String | 否 | 发送者名称。 |
status_changes
| 字段 | 类型 | 必填 | 描述 |
|---|---|---|---|
| to_status | String | 否 | 关注者ID.变更后的状态(open/resolved 或自定义代码)。 |
| changed_at | String | 否 | 变更时间(ISO8601)。 |
| changed_by_type | String | 否 | 变更来源:user/system/bot。 |
| changed_by_id | String | 否 | 当 changed_by_type 为 user 时返回。 |
sla
| 字段 | 类型 | 必填 | 描述 |
|---|---|---|---|
| first_response_due | String | 否 | 首响截止时间。 |
| resolution_due | String | 否 | 解决截止时间。 |
| first_response_at | String | 否 | 实际首响时间。 |
| sla.breached | boolean | 否 | 是否违约。 |
satisfactions
| 字段 | 类型 | 必填 | 描述 |
|---|---|---|---|
| rating | Integer | 否 | 评分 1-5 。 |
| feedback | String | 否 | 文字反馈。 |
| submitted_at | String | 否 | 提交时间 。 |










