cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
671
Views
1
Helpful
5
Replies

How to Retrieve Email Task Content

uzair.anwar
Level 1
Level 1

Hello,
I am working with the email media for Webex Contact Center and I am looking for an API that allows me to retrieve the content of an email task, including the subject, sender, and body content.

Can anyone guide me on which API or endpoint I should use to retrieve detailed email task content? Is there an API that allows retrieving details such as the email subject, sender, body, and attachments?

Any pointers or sample code would be greatly appreciated!

Thank you!

5 Replies 5

I think it depends on what you're looking to do. If you're looking for this within WebexCC, you may need to use an API like this one, which includes many but not all of the details you want. If you want this from Webex Connect perspective, you'd likely need to go another route.
https://developer.webex-cx.com/documentation/tasks/v1/get-tasks 

@bill.king1 

I have a web custom component for Webex CC.

In which I am receiving data through an event listener.
I need the email task’s body, subject, and related content within the event listener.

The API you mentioned provides a list of all open and closed tasks within a specific time frame.

I am looking for a method in the SDK or an API that allows me to fetch the content of incoming emails in real-time

gkovanis
Cisco Employee
Cisco Employee

Hello @uzair.anwar ,

Can you try using the Captures API and see if this contains all the information you need?
https://developer.webex-cx.com/documentation/captures/v1/list-captures

It is the API that will allow you to retrieve the body/transcript but I believe it won't contain all the information you need for your use case, so you may also need to use Search API to data dip on the reporting side to fetch any additional information.

 

{
    "error": {
        "key": 403,
        "message": [
            {
                "description": "Authorization failed: Forbidden"
            }
        ]
    },
    "trackingId": "6250190b-e642-41d4-8ef1-20b214f7550b"
}

https://developer.webex-cx.com/documentation/captures/v1/list-captures this api throwing me 403.

@uzair.anwar If you're checking via Try Now from Postman, are you using an admin? Alternatively, if you use a bot/integration, does it contain the necessary scopes, i.e. "Requires one of the following scopes cjp:config_read, cjp-analyzer:read."

In a quick test for me, Captures API works just fine, if you have still issues after ensuring proper scopes are set, you can raise a Support ticket.

200 Response


{
  "meta": {
    "orgId": "***",
    "urlExpiration": 30
  },
  "data": [
    {
      "taskId": "257e6f22-17bf-48b5-935d-069c8470e480",
      "recording": [],
      "transcription": [
        {
          "source": "chat",
          "provider": "CISCO",
          "id": "257e6f22-17bf-48b5-935d-069c8470e480",
          "fileName": "chatTranscript.json",
          "filePath": "https://cjp-ccone-produs1-media-storage-recording.s3.amazonaws.com/%2Fdigital/dynamic/***",
          "startTime": "1737497118633",
          "languageCode": "en",
          "configId": "CSRHEJ62CMWW05BU",
          "createTime": "1737497237449"
        }
      ]
    }
  ]
}