> ## Documentation Index
> Fetch the complete documentation index at: https://docs.operata.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Dump Function - Amazon Connect

> Data is key to understanding why Operata does not sometimes collect all the data elements it should, this Dump Function captures all we need

This function captures all the data we need to trouble shoot data collection issues for Amazon Connect based softphone services.

To use it, launch your Amazon Connect based softphone and while its selected, right click and select **inspect**.

Select Console and paste this entire code block into the console, enter return and the response **\<- undefined** should be seen.

```
// connect versionasync function diagDump() {    return Promise.all([window.operataDataAdaptor.getRTCSession()._pc].map(async (peerConnection) => await (        {            id: peerConnection.__rtcStatsId,            isTrackedByOperata: window.operataDataAdaptor.getRTCSession()._pc.__rtcStatsId === peerConnection.__rtcStatsId,            peerConnectionDetails: {                signallingState: peerConnection.signallingState,                connectionState: peerConnection.connectionState,                iceConnectionState: peerConnection.iceConnectionState,                localStreams: peerConnection.getLocalStreams(),                remoteStreams: peerConnection.getRemoteStreams(),                receivers: peerConnection.getReceivers(),                senders: peerConnection.getSenders(),            },            // stats: await window.operataDataAdaptor.getRTCSession()?.getStats(),            configuration: peerConnection.getConfiguration(),            modernStats: Array.from((await peerConnection.getStats()).values()),            legacyStats: await (new Promise(function (resolve) {                peerConnection.getStats(function (rawStats) {                    resolve(rawStats);                });            }).then(a => a.result().map(                result => ({                    type: result.type,                    id: result.id,                    ...result.names().reduce((obj, n) => ({...obj, [n]: result.stat(n)}), {})                })            )))        }    )));}
```

Now make or take a call and once the call is established, paste the command below into the console, enter return and the console should return a **\[\{…}]** prompt.

```
await diagDump();
```

Finally, hover over the **\[\{…}]** prompt, right click and **copy object**

Paste the content into an email and send to Operata **[help@operata.com](mailto:help@operata.com)**
