Property does not exist in Contact API

contacts

#1

Hi I'm trying to update a contact with the Create or update a contact. This was working well for all field until this one.

I can see the field when I do https://api.hubapi.com/contacts/v1/contact/vid/123138570/profile?hapikey={{hapikey}}

		"legal_consent.subscription_type_541": {
			"value": "",
			"versions": [
				{
					"value": "",
					"source-type": "API",
					"source-id": null,
					"source-label": null,
					"timestamp": 1537661556621,
					"selected": false
				}
			]
		},

The request to update this field that I'm doing is :

https://api.hubapi.com/contacts/v1/contact/createOrUpdate/email/bducharme@mirego.com?hapikey={{hapikey}}

As for the body, I tried a lot of different combinaisons, none working:

{
	"properties": [
		{
			"property": "LEGAL_CONSENT.subscription_type_541",
			"value": true
		}
	]
}

Some of the others combinaisons I tried:

"property": "legal_consent.subscription_type_541",
"value": true

"property": "LEGAL_CONSENT",
"value": "subscription_type_541"

"property": "legal_consent",
"value": "subscription_type_541"

The error is always:

{
	"status": "error",
	"message": "Property values were not valid",
	"correlationId": "b10d2269-fd84-4f78-998b-d96ac9bdbafe",
	"validationResults": [
		{
			"isValid": false,
			"message": "Property \"legal_consent\" does not exist",
			"error": "PROPERTY_DOESNT_EXIST",
			"name": "legal_consent"
		}
	],
	"requestId": "c3e62fc688a17f7d2e2402ab536d7b59"
}

or

{
	"status": "error",
	"message": "Property values were not valid",
	"correlationId": "4c77d764-75ac-44c1-b127-01cde0e6572d",
	"validationResults": [
		{
			"isValid": false,
			"message": "Property \"legal_consent.subscription_type_541\" does not exist",
			"error": "PROPERTY_DOESNT_EXIST",
			"name": "legal_consent.subscription_type_541"
		}
	],
	"requestId": "e9b4d5be67d9de1f53af055d8c9dfedf"
}

Others fields are working, any ideas what could be missing for this one?

Thanks!


#2

Are you using the internal name ?

Is this property a dropdown property or text property and what are the values in the dropdown