Custom Attributes

List custom attributes definitions

List all custom attributes in an organization.

SecurityApiKeyAuth
Responses
200

The list of configured custom attributes

400

Invalid value extracted from request context

500

Internal failure during request processing

get/beta/custom-attributes
Request samples
Response samples
application/json
{
  • "data": [
    • {
      • "id": "c43fc767-f89b-443a-9c98-90f53f940bd7",
      • "entityType": "Conversation",
      • "identifier": "parcel_id",
      • "label": "Parcel ID",
      • "inputDefinition": {
        • "placeholder": "1234",
        • "_type": "Text"
        },
      • "description": "Id of the parcel",
      • "createdAt": "2023-01-01T08:23:54.246Z[GMT]",
      • "updatedAt": "2023-01-11T12:25:23.837Z[GMT]",
      • "isRequired": false,
      • "isArchived": false,
      • "isDeactivated": false
      },
    • {
      • "id": "db5f673b-1c40-41e7-b71f-caab342f0607",
      • "entityType": "Conversation",
      • "identifier": "contact_reason",
      • "label": "Contact Reason",
      • "inputDefinition": {
        • "options": [
          • {
            • "id": "5e2be744-cc2b-4bda-8c76-feb7b28f2970",
            • "label": "Payment",
            • "value": "payment",
            • "nestedOptions": [
              • {
                • "id": "666de4d5-0c6e-421c-a25e-d53073070af4",
                • "label": "Card",
                • "value": "card",
                • "nestedOptions": [ ],
                • "isDeactivated": false,
                • "orderIndex": 2
                },
              • {
                • "id": "db26964a-5a88-4689-ad34-8a5f21cd9cd6",
                • "label": "Bank Transfer",
                • "value": "bank_transfer",
                • "nestedOptions": [ ],
                • "isDeactivated": false,
                • "orderIndex": 3
                }
              ],
            • "isDeactivated": false,
            • "orderIndex": 1
            },
          • {
            • "id": "05d43b25-32a4-49e2-97c0-8723dc73f7bb",
            • "label": "Access",
            • "value": "access",
            • "nestedOptions": [ ],
            • "isDeactivated": false,
            • "orderIndex": 4
            }
          ],
        • "_type": "Select"
        },
      • "description": "Reason for contacting",
      • "createdAt": "2023-01-05T06:42:31.532Z[GMT]",
      • "isRequired": true,
      • "isArchived": false,
      • "isDeactivated": false
      },
    • {
      • "id": "66121f54-98ee-4727-a4e7-1a373d411ccf",
      • "entityType": "Contact",
      • "identifier": "location",
      • "label": "Location",
      • "inputDefinition": {
        • "options": [
          • {
            • "id": "6c5efa22-8b49-4205-bb7c-52e86af3a369",
            • "label": "Denmark",
            • "value": "denmark",
            • "nestedOptions": [
              • {
                • "id": "ac4e65ea-7b84-4889-a3b5-b957926178c6",
                • "label": "Copenhagen",
                • "value": "copenhagen",
                • "nestedOptions": [ ],
                • "isDeactivated": false,
                • "orderIndex": 6
                },
              • {
                • "id": "35fa047e-c1f2-4d8d-be54-2adb7d326781",
                • "label": "Aarhus",
                • "value": "aarhus",
                • "nestedOptions": [ ],
                • "isDeactivated": false,
                • "orderIndex": 7
                }
              ],
            • "isDeactivated": false,
            • "orderIndex": 5
            }
          ],
        • "_type": "Select"
        },
      • "description": "End user's known city",
      • "createdAt": "2023-01-01T08:25:50.246Z[GMT]",
      • "updatedAt": "2023-02-01T09:01:52.2Z[GMT]",
      • "isRequired": false,
      • "isArchived": false,
      • "isDeactivated": false
      }
    ]
}

Patch conversation custom attributes

Patch custom attributes of a conversation

SecurityApiKeyAuth
Request
path Parameters
conversationId
required
integer <int64>
Request Body schema: application/json
required

The custom attributes of an conversation to be patched. This should map the custom attribute id to the desired attribute value. Format: Map[UUID, Option[AttributeValue].

additional property
Array of strings or string

AttributeValue values: String[] if the type of the custom attribute is Select or String if the type of the custom attribute is Text

Responses
200

The patched conversation attributes

400

Invalid value for: path parameter conversationId, Invalid value extracted from request context, Invalid value for: body, Invalid input for patching

401

The user who issued the access token used in the request is not authorized to perform the operation

404

An entity in this request could not be found

patch/beta/conversations/{conversationId}/custom-attributes
Request samples
application/json
{
  • "2f5515b6-7e98-4f4d-9010-bfd2a27d4f35": "012345",
  • "e14708a6-eed9-495c-9d88-c72331e9e247": [
    • "str1",
    • "str2"
    ]
}
Response samples
application/json
{
  • "data": [
    • {
      • "id": "2f5515b6-7e98-4f4d-9010-bfd2a27d4f35",
      • "name": "Conversation attribute",
      • "identifier": "conversation_attribute",
      • "value": "012345"
      },
    • {
      • "id": "e14708a6-eed9-495c-9d88-c72331e9e247",
      • "name": "Conversation attribute 2",
      • "identifier": "conversation_attribute_2",
      • "value": [
        • "str1",
        • "str2"
        ]
      }
    ]
}

Patch end user custom attributes

Patch custom attributes of an end user

SecurityApiKeyAuth
Request
path Parameters
userId
required
string <uuid>
Request Body schema: application/json
required

The custom attributes of an end user to be patched. This should map the custom attribute id to the desired attribute value. Format: Map[UUID, Option[AttributeValue].

additional property
Array of strings or string

AttributeValue values: String[] if the type of the custom attribute is Select or String if the type of the custom attribute is Text

Responses
200

The patched end user attributes

400

Invalid value for: path parameter userId, Invalid value extracted from request context, Invalid value for: body, Invalid input for patching

401

The user who issued the access token used in the request is not authorized to perform the operation

404

An entity in this request could not be found

patch/beta/endusers/{userId}/custom-attributes
Request samples
application/json
{
  • "274e5a2c-be0d-42c0-b725-3dd533729f68": "abcdef",
  • "befae0d9-9679-42b9-af76-e76f64e28429": [
    • "example1",
    • "example2"
    ]
}
Response samples
application/json
{
  • "data": [
    • {
      • "id": "274e5a2c-be0d-42c0-b725-3dd533729f68",
      • "name": "End user attribute",
      • "identifier": "end_user_attribute",
      • "value": "abcdef"
      },
    • {
      • "id": "befae0d9-9679-42b9-af76-e76f64e28429",
      • "name": "End user attribute 2",
      • "identifier": "end_user_attribute_2",
      • "value": [
        • "example1",
        • "example2"
        ]
      }
    ]
}