Genesys Cloud - Main

 View Only

Discussion Thread View
  • 1.  POST or PATCH to an already existing internal Do Not Call List dncList

    Posted 02-10-2025 17:12

    Hi everyone,

    I'm trying to make a Data Action for updating our internal Master DNC List.

    I really thought POST was the way to go, however, If I use the POST method, then I got a 400 malformed error.

    If I use PATCH /api/v2/outbound/dncLists/${input.dncListId}/phonenumbers this works fine.

    If I use POST /api/v2/outbound/dncLists/${input.dncListId}/phonenumbers then I get a 400 malformed syntax error

    Execute: The request could not be understood by the server due to malformed syntax.

    • REST call for action execute failed. Message: Request to backend service failed. Response from web service: {"message":"The request could not be understood by the server due to malformed syntax.","code":"bad.request","status":400,

    For those that have worked with Data Actions, Is PATCH the preferred way ?  I just really thought I was supposed to use POST, but I can't seem to get that to work.

    Thanks in advance for any advice you have,

    Bill W


    #API/Integrations
    #Outbound

    ------------------------------
    William Wyszomirski
    Application Administrator
    ------------------------------


  • 2.  RE: POST or PATCH to an already existing internal Do Not Call List dncList
    Best Answer

    Posted 02-11-2025 10:24

    Hi William, 

    If you are trying to update with data actions, you will need to use PATCH. Which this sounds like what you are doing. POST is used to create a new dnc list with data actions.

    I found this developer forum thread that might help explain more. 

    Cheers,  



    ------------------------------
    Cameron
    Online Community Manager/Moderator
    ------------------------------



  • 3.  RE: POST or PATCH to an already existing internal Do Not Call List dncList

    Posted 02-11-2025 12:05

    Thank you Cameron,

    PATCH is just a new thing for me, which is why I was hesitant, but it looks like that's the right approach in my scenario.

    Thanks for the link as well.



    ------------------------------
    William Wyszomirski
    Application Administrator
    ------------------------------



Need Help finding something?

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