Monday, August 25, 2014

Bad Request 400: finesseLayout property value should not contain children

Referring to the Cisco Finesse API, at /finesse/api/Team/5000/LayoutConfig
If you receive a Bad Request 400 response to a PUT request on this API (i.e. you're trying to update the layout XML for a Team in Finesse), and the error message contains this line:
Exception converting class com.cisco.ccbu.finesse.api.team.TeamLayoutConfig : Property value should not contain children on type:com.cisco.ccbu.finesse.api.team.TeamLayoutConfig child: finesseLayout
It means you need to encode the < and > characters using &lt; and &gt; for everything inside the <layoutxml> tag.

On a related note, if you receive an HTTP 415 Unsupported Media Type error response, make sure you're setting your content type to 'application/xml' and not 'text/xml'. Or anything else.

1 comment:

Anonymous said...

7 years after, you have save my ass! Thanks a lot bro!