案例事件负载和架构 - Amazon Connect

本文属于机器翻译版本。若本译文内容与英语原文存在差异,则一律以英文原文为准。

案例事件负载和架构

当您请求在事件负载中包含案例数据时,数据反映了该特定编辑后的案例版本。

Amazon Connect Cases 的默认限制可保证有效负载小于 256KB( EventBus 事件的最大大小)。由于您可以自定义案例对象模型(例如,可以在案例对象上定义自定义字段以捕获业务特定信息),因此案例事件架构反映了对案例对象所做的自定义,如以下示例所示(例如,参见如何将客户特定的 UUID 用作 JSON 属性)。

案例资源的案例事件负载示例

// Given the limits on the "includedData" configuration // this payload is guaranteed to less than 256KB at launch. { "version": "0", "id": "event ID", "detail-type": "Amazon Connect Cases Event", "source": "aws.cases", "account": "your AWS account ID", "time": "2022-03-16T23:43:26Z", "region": "The AWS Region of your Amazon Connect instance", "resources": [ "arn:aws:cases:your Amazon Connect AWS Region:your AWS account ID:domain/case domain ID", "arn:aws:cases:your Amazon Connect AWS Region:your AWS account ID:domain/case domain ID/case/case ID" ], "detail": { "version": "0", "eventType": "CASE.UPDATED", //(or "CASE.CREATED" or "CASE.DELETED") "approximateChangeTime": "2022-03-16T23:16:57.893Z", // Can be used for ordering "changedFieldIds": ["status", "last_updated_datetime"], "case": { "caseId": "case ID", "templateId": "template ID", "createdDateTime": "2022-03-16T23:16:57.893Z", // This section contains only non-null field values for the // fields that customers have configured in the "includedData". // Field values included in this section reflects the case // after this particular change is applied. "fields": { "status": { "value": { "stringValue": "open" } }, "case_reason": { "value": { "stringValue": "Shipment lost" } }, "custom-field-uuid-1": { "value": { "stringValue": "Customer didn't receive the product" } } } } } }

相关物品资源的案例事件负载示例

// Given the limits on the "includedData" configuration // this payload is guaranteed to less than 256KB { "version": "0", "id": "event ID", "detail-type": "Amazon Connect Cases Event", "source": "aws.cases", "account": "your AWS account ID", "time": "2022-03-16T23:43:26Z", "region": "The AWS Region of your Amazon Connect instance", "resources": [ "arn:aws:cases:your Amazon Connect AWS Region:your AWS account ID:domain/case domain ID", "arn:aws:cases:your Amazon Connect AWS Region:your AWS account ID:domain/case domain ID/case/case ID/related-item/related-item ID" ], "detail": { "version": "0", "eventType": "RELATED_ITEM.CREATED", //(or "RELATED_ITEM.UPDATED" or "CASE.RELATED_ITEM.DELETED") "approximateChangeTime": "2022-03-16T23:16:57.893Z", // Can be used for ordering "changedAttributes": ["comment.commentText"], "relatedItem": { "relatedItemType": "Comment", // (OR Contact) "relatedItemId": "related-item ID", "caseId": "case id that this related item is a sub-resource of", "createdDateTime": "2022-03-16T23:16:57.893Z", // This section includes any attributes that customers have configured // in the "includedData" configuration. "comment": { "body": "Gave a $5 refund to customer to make them happy", }, // if the related item was of type contact. // "contact": { // "contactArn": ".......", // } } } }