{
"Payload": {
"resource_sid": "WK...",
"service_sid": "WS...",
"error_code": "45600"
},
"Level": "ERROR",
"Timestamp": "2024-11-04T15:31:10.479061Z",
"PayloadType": "application/json",
"AccountSid": "AC...",
"Sid": "NO..."
}
但对于相同的错误SID,我们可以在Twilio控制台中看到带有堆栈跟踪的完整JavaScript错误:
我们如何也可以在调试事件Webhook中收到完整的错误消息?
通过TwilioEvent流
的Flex UI错误(
45600)的完整错误消息。
示例:{
"specversion": "1.0",
"type": "com.twilio.error-logs.error.logged",
"source": "/v1/Alerts/NO...",
"id": "NO...",
"dataschema": "https://events-schemas.twilio.com/ErrorLogs.Error/1",
"datacontenttype": "application/json",
"time": "2025-02-07T21:27:20.288Z",
"data": {
"date_created": "2025-02-07T21:27:20.288204Z",
"payload": {
"error_code": 45600,
"message": "\n## Error: \"no active call\"\n\n### LOG LINE\n```\n2/7/2025, 4:27:20 PM - WorkerActions.AcceptTask: no active call\n```\n\n### STACK TRACE\n```\nError: no active call\n at new n (https://assets.flex.twilio.com/releases/flex-ui/2.10.1/twilio-flex.unbundled-react.min.js:387:4579826)\n at e.createAndProcessError (https://assets.flex.twilio.com/releases/flex-ui/2.10.1/twilio-flex.unbundled-react.min.js:387:4582940)\n at https://assets.flex.twilio.com/releases/flex-ui/2.10.1/twilio-flex.unbundled-react.min.js:387:4706673\n```\n\n### DETAILS\n```\n{\n \"message\": \"no active call\",\n \"type\": \"app\",\n \"context\": \"WorkerActions.AcceptTask\",\n \"severity\": \"normal\",\n \"twilioErrorCode\": 45600\n}\n```\n "
},
"request_sid": "RQ...",
"correlation_sid": "WK...",
"service_sid": "WS...",
"product_name": "Flex",
"account_sid": "AC...",
"error_code": "45600",
"sid": "NO...",
"level": "ERROR"
}
}