# Interface RemoteAudioTrackStats (/zh-CN/api-reference/rtc/web/interfaces/remoteaudiotrackstats)

> For AI agents: see the complete documentation index at [llms.txt](/llms.txt).

## Properties [#properties]

<a id="codectype"></a>

<a id="optional-codectype"></a>

### codecType [#codectype]

<ApiSignature labels="Optional">

codecType: "opus"|"aac"|"PCMU"|"PCMA"|"G722"

</ApiSignature>

音频的编码格式。

- `"opus"`: 音频编码格式为 OPUS。
- `"aac"`: 音频编码格式为 AAC。
- `"pcmu"`: 预留参数，暂不支持。
- `"pcma"`: 预留参数，暂不支持。
- `"g722"`: 预留参数，暂不支持。

> Firefox 上无法获取该值。

<a id="currentpacketlossrate"></a>

### currentPacketLossRate [#currentpacketlossrate]

<ApiSignature>

currentPacketLossRate: number

</ApiSignature>

接收的音频在 400ms 内的丢包率。

<a id="end2enddelay"></a>

### end2EndDelay [#end2enddelay]

<ApiSignature>

end2EndDelay: number

</ApiSignature>

音频端到端延迟（ms）。

从远端采集音频到本地播放音频的延迟。该延迟不包括发送端编码和接收端解码的时间。

<a id="freezerate"></a>

### freezeRate [#freezerate]

<ApiSignature>

freezeRate: number

</ApiSignature>

接收的音频卡顿率。

<a id="packetlossrate"></a>

### packetLossRate [#packetlossrate]

<ApiSignature>

packetLossRate: number

</ApiSignature>

接收的音频总丢包率。

<a id="publishduration"></a>

### publishDuration [#publishduration]

<ApiSignature>

publishDuration: number

</ApiSignature>

远端发布音频时长
 如果为 -1，说明暂时还无法获取发布时长

<a id="receivebitrate"></a>

### receiveBitrate [#receivebitrate]

<ApiSignature>

receiveBitrate: number

</ApiSignature>

接收的音频码率（bps）。

<a id="receivebytes"></a>

### receiveBytes [#receivebytes]

<ApiSignature>

receiveBytes: number

</ApiSignature>

接收的音频总字节数。

<a id="receivedelay"></a>

### receiveDelay [#receivedelay]

<ApiSignature>

receiveDelay: number

</ApiSignature>

接收音频延迟 (ms)。

从发送到接收端播放音频的延迟时间。

> Safari 和 Firefox 上该字段不准确。

<a id="receivelevel"></a>

### receiveLevel [#receivelevel]

<ApiSignature>

receiveLevel: number

</ApiSignature>

接收的音频音量等级，范围为 [0,32767]。

> 该值通过 WebRTC-Stats 获取，不能确保实时性。如果你想获取当前实时的音量等级，调用 [RemoteAudioTrack.getVolumeLevel](/zh-CN/api-reference/rtc/web/interfaces/iremoteaudiotrack#getvolumelevel)。

<a id="receivepackets"></a>

### receivePackets [#receivepackets]

<ApiSignature>

receivePackets: number

</ApiSignature>

接收的音频总包数。

<a id="receivepacketsdiscarded"></a>

### receivePacketsDiscarded [#receivepacketsdiscarded]

<ApiSignature>

receivePacketsDiscarded: number

</ApiSignature>

因过早或过晚到达抖动缓冲器而被丢弃的数据包数量。

<a id="receivepacketslost"></a>

### receivePacketsLost [#receivepacketslost]

<ApiSignature>

receivePacketsLost: number

</ApiSignature>

接收的音频总丢包数。

<a id="totalduration"></a>

### totalDuration [#totalduration]

<ApiSignature>

totalDuration: number

</ApiSignature>

接收的音频总时长，单位为秒。

<a id="totalfreezetime"></a>

### totalFreezeTime [#totalfreezetime]

<ApiSignature>

totalFreezeTime: number

</ApiSignature>

接收的音频总卡顿时长，单位为秒。

<a id="transportdelay"></a>

### transportDelay [#transportdelay]

<ApiSignature>

transportDelay: number

</ApiSignature>

传输延迟（ms)。

从远端发送音频到本地接收音频的延迟。
