Updating a profile’s Geographical unit updating-a-geographical-unit
- Perform a GET request on the geoUnitBase resource to retrieve the Geographical unit PKey.
- Perform a PATCH request on the profile PKey, with the desired Geographical unit PKey in the payload.
Sample request
Retrieve the list of Geographical units.
-X GET https://mc.adobe.io/<ORGANIZATION>/campaign/profileAndServicesExt/geoUnitBase/ \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer <ACCESS_TOKEN>' \
-H 'Cache-Control: no-cache' \
-H 'X-Api-Key: <API_KEY>'
It returns all Geographical units. Retrieve the PKey of the unit to which you want to assign the profile.
{
"PKey": "<PKEY>",
"created": "2019-04-06 22:36:19.089Z",
"desc": "",
"href": "https://mc.adobe.io/<ORGANIZATION>/campaign/profileAndServicesExt/geoUnitBase/<PKEY>",
"label": "Europe",
"lastModified": "2019-04-06 22:36:19.086Z",
"name": "eu",
"parentTitle": "All (all)",
"title": "Europe (eu)"
},
Perform a PATCH request on the profile, with the PKey of the desired Geographical unit in the payload.
-X PATCH https://mc.adobe.io/<ORGANIZATION>/campaign/profileAndServicesExt/profile/<PKEY> \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer <ACCESS_TOKEN>' \
-H 'Cache-Control: no-cache' \
-H 'X-Api-Key: <API_KEY>'
-i
-d {
-d "geoUnit":{
-d "PKey":"<PKEY>"
-d }
-d }
recommendation-more-help
3ef63344-7f3d-48f9-85ed-02bf569c4fff