onMusicChartsResult
Callback after retrieving music charts.
@CalledByNative void onMusicChartsResult(String requestId, MusicChartInfo[] list, int reason);
This callback is triggered after calling getMusicCharts.
Trigger Timing
This callback is triggered after calling the getMusicCharts method.
Parameters
- requestId
- Request ID, used to uniquely identify this request.
- list
- List of currently playable music charts. See MusicChartInfo.
- reason
- Request status code from Music Content Center:
MUSIC_CONTENT_CENTER_STATE_REASON_OK(0): Request successful.MUSIC_CONTENT_CENTER_STATE_REASON_ERROR(1): General error, no specific reason.MUSIC_CONTENT_CENTER_STATE_REASON_GATEWAY(2): Gateway error. Possible reasons include:- The current token has expired. Please regenerate the token.
- The provided token is invalid. Please ensure you are using an RTM token.
- Network error. Please check your network connection.
MUSIC_CONTENT_CENTER_STATE_REASON_PERMISSION_AND_RESOURCE(3): Permission error or music resource not found. Please ensure your project has enabled access to Agora Music Content Center. Contact technical support if needed.MUSIC_CONTENT_CENTER_STATE_REASON_INTERNAL_DATA_PARSE(4): Internal data parsing error. Please contact technical support.MUSIC_CONTENT_CENTER_STATE_REASON_MUSIC_LOADING(5): Error occurred while loading music resource. Please contact technical support.MUSIC_CONTENT_CENTER_STATE_REASON_MUSIC_DECRYPTION(6): Error occurred while decrypting music resource. Please contact technical support.MUSIC_CONTENT_CENTER_STATE_REASON_HTTP_INTERNAL(7): Internal HTTP error. Please try again later.