0

I'm trying to create an API event through REST API, event is created but it appears as Contact Event not APIEvent inside SFMC, which is problematic

Request body sent is :

Is there something I'm missing ? "pi" is a Javascript variable passed to the request by the way

{
    "type": "APIEvent",
    "name": "YOO",
    "mode": "Production",
    "eventDefinitionKey": pi,
    "dataExtensionName": "DE-"+pi,
    "sourceApplicationExtensionId":"7db2f972-f8c7-49b6-91b5-fa218e13953d",
    "isVisibleInPicker": true,
    "schema": {
        "sendableCustomObjectField": "contactKey",
        "SendableSubscriberField": "contactKey",
        "fields": [
          {
            "name": "firstName",
            "dataType": "text",
            "maxLength": "100",
            "isNullable": false,
            "defaultValue": ""
          },
          {
            "name": "contactKey",
            "dataType": "text",
            "maxLength": "100",
            "isNullable": false,
            "defaultValue": ""
          },
          {
            "name": "Tiekkd",
            "dataType": "text",
            "maxLength": "100",
            "isNullable": false,
            "defaultValue": ""
          }
       ]
    }
  }

Those are examples of Event created with API ( in red ), others created manually ( in green )

enter image description here

But all of them have same type

Any help would be much appreciated

0

Your Answer

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

Browse other questions tagged or ask your own question.