0

I am getting an internal server error when trying to save a contact in Marketing Cloud with Rest API.

The body of my request is:

{
    "contactKey": "[email protected]",
    "attributeSets": [
        {
            "name": "Email Addresses",
            "items": [
                {
                    "values": [
                        {
                            "name": "Email Address",
                            "value": "[email protected]"
                        }
                    ]
                }
            ]
        }
    ]
}

My end point is: https://XXXXXXXXXXXXXXXXXXXXX.rest.marketingcloudapis.com/contacts/v1/contacts

I use postman for tests, and I am getting this error:

{
    "documentation": "https://developer.salesforce.com/docs/atlas.en-us.mc-apis.meta/mc-apis/error-handling.htm",
    "errorcode": 0,
    "message": "Internal Server Error"
} 

Thank for your answers.

1
  • 1
    Try with a different email address
    – EazyE
    Feb 21, 2020 at 20:29

1 Answer 1

0

Assuming you already got the Access token from your SFMC integration App

Please Use below and replace YOUR_SUBDOMAIN and YOUR_ACCESS_TOKEN values with your values

Host: https://YOUR_SUBDOMAIN.rest.marketingcloudapis.com
POST /contacts/v1/contacts
Content-Type: application/json
Authorization: Bearer YOUR_ACCESS_TOKEN
{
    "contactKey": "[email protected]",
    "attributeSets": [{
                      "name": "Email Addresses",
                      "items": [{
                         "values": [{
                             "name": "Email Address",
                             "value": "[email protected]"
                                   }]
                              }]
                       }]
}
1
  • Hi Pardeep! I do it and I have the same error. Feb 22, 2020 at 12:58

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .