Adds a new custom object to a NeonCRM system.
When you create a new custom object, you will define the object’s properties as well as the first column to be created in the object’s database table. You can then use the Create Custom Object Field method to add additional columns to your object.
Endpoint
https://api.neoncrm.com/neonws/services/api/customObject/createCustomObject
Request
https://api.neoncrm.com/neonws/services/api/customObject/createCustomObject?userSessionId=[session id]&customObject.objectLabel=Museum Visits&customObject.objectDescription=Tracks constituent visits to our museum&customObject.objectRecordName=Visit&customObject.ObjectRecordStartNumber=1&customObject.objectRecordDisplayFormat={0}&customObject.objectRecordDataType=AUTO_NUMBER
Response
{
"createCustomObjectResponse": {
"operationResult": "SUCCESS",
"responseDateTime": "2017-05-18T21:00:26.246+0000",
"customObject": {
"objectId": 2,
"objectName": "Museum_Visits",
"objectLabel": "Museum_Visits",
"objectApiName": "Museum_Visits_c",
"objectDescription": "Tracks constituent visits to our museum",
"objectRecordName": "Visit",
"objectRecordStartNumber": 1,
"objectRecordDisplayFormat": "{0}",
"allowActivity": false,
"allowReport": false,
"objectRecordDataType": AUTO_NUMBER,
"isActive": false
}
}
}
Request Parameters
Parameter |
Required |
Description |
customObject.objectLabel |
Required |
This is the unique name used to identify the Custom Object in the Custom Objects list as well as in the left menu (if the object is added to the left menu). |
customObject.objectDescription |
|
Optional description or notes about this Custom Object. |
customObject.objectRecordName |
Required |
This is a non-unique Field Name for the First Record that appears in page layouts, key lists, related lists, lookups, and search results. This is the first column to be created in your table. In most cases, this will be your table’s primary key. |
customObject.objectRecordDataType |
Required |
Possible values: TEXT or AUTO_NUMBER. This controls the data type for the column you created with the “customObject.objectRecordName” parameter. In most cases, you will want to use a value of AUTO_NUMBER. |
customObject.ObjectRecordStartNumber |
|
Required if customObject.objectRecordDataType = AUTO_NUMBER. Must be an integer. Specify which number should be used as the starting point for your Auto-Number field. |
customObject.objectRecordDisplayFormat |
|
Please refer to our guide: Custom Object Number Formats |
customObject.AllowActivity |
|
Possible values: TRUE, FALSE. If this is turned on, this Custom Object will be available for use in Activities. |
customObject.AllowReport |
|
Possible values: TRUE, FALSE. If this is turned on, this Custom Object will be exposed to the NeonCRM reporting interface. |
customObject.addToNeonLeftMenu |
|
Possible values: TRUE, FALSE. If this is turned on, this Custom Object will be added to NeonCRM’s main navigation bar. |
customObject.createWebhook |
|
Format: Valid URL. When a new record is created, Neon will pass the record as JSON to this URL. |
customObject.updateWebhook |
|
Format: Valid URL. When a record is updated, Neon will pass the record as JSON to this URL. |
customObject.deleteWebhook |
|
Format: Valid URL. When a record is deleted, Neon will pass the record ID as JSON to this URL. |
Response Parameters
Parameter |
Description |
customObject.objectId |
|
customObject.objectName |
|
customObject.objectLabel |
|
customObject.objectApiName |
This is the token used to identify the Custom Object when accessing it from the API. |
customObject.objectDescription |
|
customObject.objectRecordName |
|
customObject.objectRecordStartNumber |
|
customObject.objectRecordDisplayFormat |
|
customObject.allowActivity |
|
customObject.allowReport |
|
customObject.objectRecordDataType |
|
customObject.isActive |
|
Error Codes
Code |
Text |
Description |
20008 |
Object label name is required. |
|
20009 |
Object label name is invalid. |
|
20010 |
Object record name is requried. |
|
20011 |
Object record name is invalid. |
|
20012 |
Object record data type is required. |
|
20013 |
Object record data type is invalid. |
|
20014 |
Object record display format is required. |
|
20016 |
Object record start number is required. |
|
20017 |
Object record start number is invalid. |
|