PUT TrunkBaseSettings 400 Error

I am trying to update a specific property in one of my trunk base settings. I am testing the process through the API Explorer using the PUT request and this request body :
{
"name": "Azure Cloud Data Center",
"trunkMetabase": {
"id": "external_sip_pcv_byoc_carrier_verizon.json",
"name": "",
"selfUri": ""
},
"properties": {
"trunk_outboundIdentity_callingAddress": {
"instance": "1234567890"
}
},
"trunkType": "EXTERNAL"
}

I am receiving this error :

The request failed with response code: 400. Message: The request could not be understood by the server due to malformed syntax.

I have tried with various attempts in the request body, even including the entire list of properties, but receive the same error nonetheless. Would you be able to take a look and let me know where I am making a mistake in my syntax.

Thanks,

Sean Case

Hello,

An HTTP PUT method is meant to replace the object with the one provided in the body.
So you would have to send a PUT with all properties, version number, ...
What I would suggest is to do a GET on your trunk base settings, modify the response content with your new trunk_outboundIdentity_callingAddress value, and use this as the body of your PUT.

Regards,

This worked, appreciate the response. Might be helpful to include this in the API Explorer, because working through the fields provided there does not include all the fields.

Thanks!

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