Community
Showing results for 
Search instead for 
Do you mean 
Reply

400 bad request on PATCH

Copper Contributor
Posts: 127
Country: Netherlands

400 bad request on PATCH

[ Edited ]

I'd like to do a PATCH request on a yes/no customField. But when I send this to a 1.0.236.0 api:

 

PATCH /api/contacts/9a107707-8720-49c3-b126-be09c26b3747

body:

{

"customFields": {
"ishoofdcontact": true

}
}

 

I get back a 400 Bad request with empty response body.

Why?

Greetings,

ACT Certified Consultants
TendenZ
the Netherlands
Employee
Posts: 61
Country: USA

Re: 400 bad request on PATCH

[ Edited ]

Try including the id in the body as well.  It validate the id in the body with the id in the url.

 

PATCH /api/contacts/9a107707-8720-49c3-b126-be09c26b3747

body:

{

    "id": "9a107707-8720-49c3-b126-be09c26b3747",
    "customFields": {
        "ishoofdcontact": true
    }
}