Skip to main content

I am using a curl command to edit a custom property to test something out. Unfortunately I keep getting this error : {"errors"::{"id":"b7c5d32b-8a1e-4ea4-aae0-c9c9db9dc4c5","status":400,"code":"invalid","title":"Invalid input.","detail":"The payload provided in the request is invalid.","source":{"pointer":"/data"},"links":{},"meta":{}}]}%

 

This is the code I am running: 

curl --request PATCH \
     --url https://a.klaviyo.com/api/profiles/{profile_id}/ \
     --header 'Authorization: Klaviyo-API-Key your-api-key' \
     --header 'accept: application/json' \
     --header 'content-type: application/json' \
     --header 'revision: 2024-06-15' \
     --data '{"data": {"properties":{"Pesticides":r"Acephate","Tetraconazole","Endrin","Pyrimethanil","Penthiopyrad"]}}}'
 

I used a private API key with full access and the profile ID has Pesticides as a property although I don’t think that should matter. I honestly am lost on what is going wrong.

Hello @hkhan317 

According to the Update Profile API documentation the highlight attributes are required. Try adding type and id in the payload
 

 


Reply