/// <summary> /// Returns a stream with the recording of the provided Ding Id of a doorbot /// </summary> /// <param name="dingId">Id of the doorbot history event to retrieve the recording for</param> /// <returns>Stream containing contents of the recording</returns> public async Task <Stream> GetDoorbotHistoryRecording(string dingId) { if (!IsAuthenticated) { throw new Exceptions.SessionNotAuthenticatedException(); } var connectedStream = await HttpUtility.DownloadFile( new Uri(RingApiBaseUrl, $"dings/{dingId}/recording?auth_token={AuthenticationToken}&api_version=9"), null, DoorbotFileRequest); return(connectedStream); }