A custom field defines the name and type for an extra field of an API resource such as a contact, conversation, or account. Only listing all fields and updating the name and/or the description of a custom field is allowed. If you need a custom field to change its type, you need to create a new one with the correct type, as we validate the value of a custom field based on its type.
Each custom field has a specified data type. Ensure the data you submit when updating a custom field's value is formatted correctly:
Type | Example values | Description |
---|---|---|
String | "London, UK" | String values |
Boolean | true | Boolean true /false |
Datetime | 1525417200 | Epoch Timestamps |
Number | 90 | Integers |
Teammate | [email protected] | Email address of a teammate |
List of teammates | ["[email protected]", "[email protected]", "[email protected]"] | List of email addresses of teammates |
Inbox | "inb_55c8c149" | Inbox id |
Enum | [{"value": "firefighter", "label": "Firefighter"},...] | Array of values objects listing the possible enums |
Example Custom Field Object
{
"_links": {
"self": "https://api2.frontapp.com/conversations/fld_55c8c149"
},
"id": "fld_55c8c149",
"name": "job_title",
"description": "Job title",
"type": "string"
}
Example Custom Field Object of type enum
{
"_links": {
"self": "https://api2.frontapp.com/conversations/fld_55c8c149"
},
"id": "fld_55c8c149",
"name": "job_title",
"description": "Job title",
"type": "enum",
"values": [
{
"value": "firefighter",
"label": "Firefighter"
},
{
"value": "doctor",
"label": "Doctor"
},
{
"value": "airline_pilot",
"label": "Airline pilot"
},
]
}