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": "acruz@example.com",
    "attributeSets": [
        {
            "name": "Email Addresses",
            "items": [
                {
                    "values": [
                        {
                            "name": "Email Address",
                            "value": "acruz@example.com"
                        }
                    ]
                }
            ]
        }
    ]
}

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
    Try with a different email address – EazyE Feb 21 at 20:29
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": "acruz@example.com",
    "attributeSets": [{
                      "name": "Email Addresses",
                      "items": [{
                         "values": [{
                             "name": "Email Address",
                             "value": "acruz@example.com"
                                   }]
                              }]
                       }]
}
| improve this answer | |
  • Hi Pardeep! I do it and I have the same error. – herman bogning Feb 22 at 12:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.