API - Recording Archive Update

I'm very new to API's and am trying to accomplish the following:

Update the Archive Date to a future time that is approximately 5 minutes from the sending of the request.

I have successfully been able to get the Recording ID which is apparently 1 of 3 pieces of required information, the other being the interaction ID. What I'm struggling with is the Parameter for "body" which is described as "recording", data type "recording", and is required...

  1. is this the right API for trying to get my recently restored recordings set back to archived (to free up my available retrieval requests) and
  2. if that is the correct API, how do I satisfy that Parameter? Is it looking for an actual recording to send back and overwrite?

Thanks in advance (and bear with me!).

Can you be specific about what API you're trying to use?

Hi Tim – thank you for replying.

I’m trying to use the API explorer with the following: /api/v2/conversations/{conversationId}/recordingmetadata

RecordingApi.getConversationRecordingmetadata() will give you the recording ID, assuming you already know the conversation ID. Once you have both IDs, use RecordingApi.putConversationRecording() with the body { "archiveDate": "2017-11-17T18:25:00+00:00" } to set the new archive date (using your own timestamp, of course). The archival process will be initiated "soon" after the archive date elapses; it can take 10+ minutes after the archive date until it becomes archived.

Thank you Tim - I'll give this a try now.

Juan

I got a successful reply - so thank you! It's been about 20 minutes since the request and I don't see the update, but hopefully it will trigger.

{
"id": "65a941b9-54cd-499c-9224-6e35b58598de",
"conversationId": "948d205d-1881-425a-adcc-53f8136afca8",
"media": "audio",
"fileState": "RESTORING",
"archiveDate": "2017-11-18T15:55:56.341Z",
"archiveMedium": "CLOUDARCHIVE",
"maxAllowedRestorationsForOrg": 100,
"remainingRestorationsAllowedForOrg": 22,
"selfUri": "/api/v2/conversations/948d205d-1881-425a-adcc-53f8136afca8/recordings/65a941b9-54cd-499c-9224-6e35b58598de"
}

Should I have changed the state to "ARCHIVED" as part of this request?

No, the state is a system-generated property. The only thing you need to do is set the archive date and the server will handle everything. If the state isn't transitioning to archived after a reasonable amount of time, please open a ticket with PureCloud Support to investigate (performance issues can't be investigated via the forum).

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.