Quantcast
Channel: Topliners: Message List
Viewing all articles
Browse latest Browse all 3431

Custom Objects through REST API

$
0
0

I am looking to create a custom object through the rest API. The request details that I'm trying are as below:

 

POST

https://www02.secure.eloqua.com/API/REST/1.0/assets/customObject

 

Request Body:       

{

      "fields": {

            "displayType": "text",

            "dataType": "text",

            "defaultValue" : "TestCustomObj Data"

      },

      "name": "Test123",

      "displayNameFieldId": "M_CompanyName",

      "uniqueCodeFieldId": "100085"

}

 

I see that this results in a new custom object in the portal, but without any Fields (Custom Object Record Fields). The same can be achieved when done from portal in step 2 of the create custom object wizard, where we can add custom object record fields by clicking on the button in the top right corner.

 

How are we to achieve the same from API? The json data with key "fields" in the request body did not create it (as we perceived it to be). Are we missing something?


Viewing all articles
Browse latest Browse all 3431

Trending Articles