When you call Custom Field Service with POST method, you can create a custom field on next4biz CRM.
Your request body must be contain 4 properties.
tenant_slug This is your subdomain on selphiu URL. For example: if your selphiu domain is “acme.selpihu.com” then your tenant_slug is “acme”access_token next4biz CRM provide an access_token via access_token service. Every access_token expires after 15 minutes. Best Practice, you request a new access_token for each service request.channel This is bussines channel id. If you don’t know your bussiness_channels and there’s id numbers. You can learn via bussiness_channel service.custom_field This is an array includes objects as custom_field property is an object contain you want to create custom_field values. You must set id property. But others are arbitrary. You can sent 500 person each request.| Name | Value |
|---|---|
| REST-API METHOD | Create Custom Field |
| HTTP METHOD | POST |
| RESPONSE TYPE | JSON |
| URL | https://api.crm.next4biz.com/custom-field/ |
| REQUEST HEAD | Accept: application/json; Content-Type: application/json |
{
"tenant_slug": "acme",
"channel": "79",
"access_token": "[YOUR ACCESSTOKEN]",
"custom_field": [
{
"label": "text type custom field example",
"kind_id": 2,
"custom_field_type": {
"custom_field_type_id": "1"
},
"filterable": true,
"is_active": true,
"is_required": false
},
{
"label": "date type custom field example",
"kind_id": 2,
"custom_field_type": {
"custom_field_type_id": "2"
},
"filterable": true,
"is_active": true,
"is_required": false
},
{
"label": "date time type custom field example",
"kind_id": 2,
"custom_field_type": {
"custom_field_type_id": "3"
},
"filterable": true,
"is_active": true,
"is_required": false
},
{
"label": "date time type custom field example",
"kind_id": 2,
"custom_field_type": {
"custom_field_type_id": "3"
},
"filterable": true,
"is_active": true,
"is_required": false
},
{
"label": "number type custom field example",
"kind_id": 2,
"custom_field_type": {
"custom_field_type_id": "4"
},
"filterable": true,
"is_active": true,
"is_required": false
},
{
"label": "multiple list type custom field example",
"kind_id": 2,
"custom_field_type": {
"custom_field_type_id": "5"
},
"filterable": true,
"is_active": true,
"is_required": false,
"data": [
{
"text": "Multi Choice - 1"
},
{
"text": "Multi Choice - 2"
},
{
"text": "Multi Choice - 3"
},
{
"text": "Multi Choice - 4"
},
{
"text": "Multi Choice - 5"
}
]
},
{
"label": "list type custom field example",
"kind_id": 2,
"custom_field_type": {
"custom_field_type_id": "6"
},
"filterable": true,
"is_active": true,
"is_required": false,
"data": [
{
"text": "List Choice - 1"
},
{
"text": "List Choice - 2"
},
{
"text": "List Choice - 3"
},
{
"text": "List Choice - 4"
},
{
"text": "List Choice - 5"
}
]
}
]
}
{
"code": 200,
"status": "Success",
"result": [
{
"custom_field_id": 228,
"custom_field_type": {
"custom_field_type_id": 1,
"custom_field_type_name": "text"
},
"kind_id": "2",
"data": null,
"label": "text type custom field example",
"filterable": "true",
"is_active": "true",
"is_required": "false",
"order_number": 17,
"created_at": "2017-09-05 15:40",
"tenant": {
"tenant_id": 74,
"tenant_name": "acme",
"tenant_slug": "acme",
"created_at": "2017-09-05 11:53:41"
}
},
{
"custom_field_id": 229,
"custom_field_type": {
"custom_field_type_id": 2,
"custom_field_type_name": "date"
},
"kind_id": "2",
"data": null,
"label": "date type custom field example",
"filterable": "true",
"is_active": "true",
"is_required": "false",
"order_number": 18,
"created_at": "2017-09-05 15:40",
"tenant": {
"tenant_id": 74,
"tenant_name": "acme",
"tenant_slug": "acme",
"created_at": "2017-09-05 11:53:41"
}
},
{
"custom_field_id": 230,
"custom_field_type": {
"custom_field_type_id": 3,
"custom_field_type_name": "datetime"
},
"kind_id": "2",
"data": null,
"label": "date time type custom field example",
"filterable": "true",
"is_active": "true",
"is_required": "false",
"order_number": 19,
"created_at": "2017-09-05 15:40",
"tenant": {
"tenant_id": 74,
"tenant_name": "acme",
"tenant_slug": "acme",
"created_at": "2017-09-05 11:53:41"
}
},
{
"custom_field_id": 231,
"custom_field_type": {
"custom_field_type_id": 3,
"custom_field_type_name": "datetime"
},
"kind_id": "2",
"data": null,
"label": "date time type custom field example",
"filterable": "true",
"is_active": "true",
"is_required": "false",
"order_number": 20,
"created_at": "2017-09-05 15:40",
"tenant": {
"tenant_id": 74,
"tenant_name": "acme",
"tenant_slug": "acme",
"created_at": "2017-09-05 11:53:41"
}
},
{
"custom_field_id": 232,
"custom_field_type": {
"custom_field_type_id": 4,
"custom_field_type_name": "number"
},
"kind_id": "2",
"data": null,
"label": "number type custom field example",
"filterable": "true",
"is_active": "true",
"is_required": "false",
"order_number": 21,
"created_at": "2017-09-05 15:40",
"tenant": {
"tenant_id": 74,
"tenant_name": "acme",
"tenant_slug": "acme",
"created_at": "2017-09-05 11:53:41"
}
},
{
"custom_field_id": 233,
"custom_field_type": {
"custom_field_type_id": 5,
"custom_field_type_name": "multiple list"
},
"kind_id": "2",
"data": {
"index": 6,
"items": [
{
"id": 1,
"text": "Multi Choice - 1"
},
{
"id": 2,
"text": "Multi Choice - 2"
},
{
"id": 3,
"text": "Multi Choice - 3"
},
{
"id": 4,
"text": "Multi Choice - 4"
},
{
"id": 5,
"text": "Multi Choice - 5"
}
]
},
"label": "multiple list type custom field example",
"filterable": "true",
"is_active": "true",
"is_required": "false",
"order_number": 22,
"created_at": "2017-09-05 15:40",
"tenant": {
"tenant_id": 74,
"tenant_name": "acme",
"tenant_slug": "acme",
"created_at": "2017-09-05 11:53:41"
}
},
{
"custom_field_id": 234,
"custom_field_type": {
"custom_field_type_id": 6,
"custom_field_type_name": "list"
},
"kind_id": "2",
"data": {
"index": 6,
"items": [
{
"id": 1,
"text": "List Choice - 1"
},
{
"id": 2,
"text": "List Choice - 2"
},
{
"id": 3,
"text": "List Choice - 3"
},
{
"id": 4,
"text": "List Choice - 4"
},
{
"id": 5,
"text": "List Choice - 5"
}
]
},
"label": "list type custom field example",
"filterable": "true",
"is_active": "true",
"is_required": "false",
"order_number": 23,
"created_at": "2017-09-05 15:40",
"tenant": {
"tenant_id": 74,
"tenant_name": "acme",
"tenant_slug": "acme",
"created_at": "2017-09-05 11:53:41"
}
}
]
}