Hi @Parth Kumar ,
It appears there is a incorrect date format in the callRecordingDisplayName
and the actual filename that got saved in OneDrive recordings folder.
-
/chats/{chat-id}/messages
it is returning the response in UTC DateTime offset format and in OneDrive it is getting saved as per the local time zone of users OneDrive.
Please use callRecordingUrl
from the above response with OneDrive SharingLinks,
GET /shares/{base64encoded-callRecordingUrl}/driveItem/content
below are the steps to get the same.
- In this case my callRecordingUrl
"callRecordingUrl": "https://tenant-my.sharepoint.com/:v:/g/personal/user@tenant.onmicrosoft.com/ETLxQCb9h9VEsRAlNRLVt2oBLs57HVWqNWOfmIRdxpi7FA?email=user%40tenant.onmicrosoft.com"
To encode a sharing URL, use the following logic:
- First, use base64 encode the URL.
- Convert the base64 encoded result to unpadded base64url format by removing
=
characters from the end of the value, replacing/
with_
and+
with-
. - Append
u!
to be beginning of the string.
- After encoding url with base64 and following above steps, will get a string in below format
u!aHR0cHM6Ly95djVicy1teS...................................................................9ubWljcm9zb2Z0LmNvbQ
- Using the example Access the shared item directly, can get the file content
GET /shares/{base64encoded-callRecordingUrl}/driveItem/content
Hope this helps.
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".