REST API Content builder updating assets results in 404 I'm trying to migrate to REST API and according to SFMC documentation in order to update of an asset using PATCH I should use https://my_sub_domain.rest.marketingcloudapis.com/asset/v1/content/assets/{id}. However, all requests end with
1string(747) "HTTP/1.1 404 Not Found x-mashery-message-id: 8c94a90d-ba59-4c88-9dd8-0e8be18f2b8c x-mashery-responder: 07-rt06 strict-transport-security: max-age=15552000; preload Content-Security-Policy: upgrade-insecure-requests x-xss-protection: 1; mode=block x-frame-options: DENY x-content-type-options: nosniff cache-control: no-cache, must-revalidate, max-age=0, no-store, private Referrer-Policy: strict-origin-when-cross-origin Vary: Origin, X-HTTP-Method-Override Content-Type: application/json; charset=utf-8 Content-Length: 147 Date: Mon, 04 May 2020 21:53:38 GMT Connection: keep-alive {"documentation":"https://developer.salesforce.com/docs/atlas.en-us.mc-apis.meta/mc-apis/error-handling.htm","errorcode":404,"message":"Not Found"}"
JSon request
[{"name":"Test","assetType":{"id":"4963","name":"Test"},"views":{"subjectline":{"content":"test subject"},"html":{"content":"test content"}}}]
My code:
curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json','Authorization: Bearer ' . $token ));
curl_setopt($ch, CURLOPT_HEADER, 1);
curl_setopt($ch,CURLOPT_URL,$url);
curl_setopt($curl, CURLOPT_CUSTOMREQUEST, 'PATCH');
curl_setopt($ch,CURLOPT_POSTFIELDS,$fields_string);
curl_setopt($ch,CURLOPT_RETURNTRANSFER,1);
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
$result = curl_exec($ch);
What do I miss?
Note: I'm able to retrieve the same asset with no issues
{id}
?