Genesys Cloud - Main

 View Only

Discussion Thread View
  • 1.  Best Practices for Finding and Deleting Unused WebRTC Phones

    Posted 14 days ago

    Hi everyone,

    I hope you're all doing well! I'm currently working on cleaning up our Genesys Cloud environment and need some advice on the best way to find and delete unused WebRTC phones.

    Context:

    • Environment: Genesys Cloud
    • Objective: Identify and delete WebRTC phones that are no longer in use to maintain a clean and efficient setup.

    Questions:

    1. Finding Unused WebRTC Phones:

      • What are the best methods or tools to identify WebRTC phones that are not being used?
      • Are there any specific reports or APIs that can help with this?
    2. Deleting Unused WebRTC Phones:

      • Once identified, what is the most efficient way to delete these unused phones?
      • Are there any bulk delete options or scripts that can automate this process?

    Additional Information:

    • We have a large number of WebRTC phones, so manual checking is not feasible.
    • We are open to using APIs, scripts, or any other tools that can help streamline this process.

    Any insights, tips, or best practices would be greatly appreciated!

    Thank you in advance for your help!


    #Telephony

    ------------------------------
    Eric Callagher
    Telephony Engineer
    ------------------------------


  • 2.  RE: Best Practices for Finding and Deleting Unused WebRTC Phones

    Posted 13 days ago
    Edited by Jerold Paris 13 days ago

    Hi Eric,

    Is your webrtc phone setup 1 is to 1? A user named User1 can only have one phone named User1?

    If yes, then I think the API query GET /api/v2/telephony/providers/edges/phones works. (Make sure to add field = webRtcUser)
    The webrtcuser field will show if a user is assigned that phone or not. 

    Note: That is assuming that your userIDs are already deleted prior because it will show blank on webrtc user of that phone. If you haven't deleted the userID, that's another scenario you check on Agent Status Report.

    For #2, the DELETE /api/v2/telephony/providers/edges/phones/{phoneId} can be used after you collected the phoneIds from #1.



    ------------------------------
    Jerold Paris
    ------------------------------



  • 3.  RE: Best Practices for Finding and Deleting Unused WebRTC Phones

    Posted 13 days ago

    Thank you. Yes, we build named phones for each WebRTC User; we now have a couple thousand of these and want to delete many of those.

    I'm glad we have APIs that can help.  Robert below also mentioned Trigger for user status change.  I may explore this.



    ------------------------------
    Eric Callagher
    Telephony Engineer
    ------------------------------



  • 4.  RE: Best Practices for Finding and Deleting Unused WebRTC Phones
    Best Answer

    Posted 13 days ago

    Hi @Eric Callagher,

    I can recommend using the API /api/v2/telephony/providers/edges/phones to get all phones.
    You may add some parameters to get more information, like /api/v2/telephony/providers/edges/phones?expand=properties&fields=webRtcUser

    Then you can filter the result list for empty "WebRTCUser".
    With
    /api/v2/telephony/providers/edges/phones/{phoneId} you can delete the phones one-by-one.

    I am using this in a scheduled job to get rid of this kind unused WebRTC phones.

    There is maybe also some kind of trigger for inactivated/deleted users at Admin -> Architect -> Triggers hat you can use to remove the WebRTC phone directly when the user activity state change.

    BR, Robert



    ------------------------------
    Robert Herms
    NA
    ------------------------------



  • 5.  RE: Best Practices for Finding and Deleting Unused WebRTC Phones

    Posted 13 days ago

    Thank you for your answer.  Can I ask - How do you create a scheduled job? 

    It'd be handy to be able to clean phones - going forward on termination/transfer; while (current unused phones) could be cleaned up with a recon. 



    ------------------------------
    Eric Callagher
    Telephony Engineer
    ------------------------------



  • 6.  RE: Best Practices for Finding and Deleting Unused WebRTC Phones

    Posted 13 days ago
    Edited by Vaun McCarthy 13 days ago

    Hi Eric, if you're already aware of the CLI and somewhat familiar with things like PowerShell you can try taking a look here.  

    https://github.com/MyPureCloud/quick-hits-cli/tree/main/telephony



    ------------------------------
    Vaun McCarthy
    ------------------------------



Need Help finding something?

Check out the Genesys Knowledge Network - your all-in-one access point for Genesys resources