Collections

Collection Object

Collections are represented as JSON object with the following properties

Name
Type
Description

id

integer

The ID of the collection.

name

string

The name of the collection.

created_by

string

ID of the user who created the collection.

config

object

emoji_config

object

ticketing_config

object

csat_config

object

created_at

string

The creation timestamp of the request

updated_at

string

The update timestamp of the request

Config Object

Config is represented as JSON object with the following properties

Name
Type
Description

story_detection

boolean

Indicates if story detection is enabled

force_story_request

boolean

Indicates if forcing story request is enabled

auto_assign

object

Object containing auto assign information

responders

array

Array of responder objects. The following two types of objects are possible :

Emoji Config Object

Emoji Config is represented as JSON objects with the following properties

Name
Type
Description

emoji_names

object

Object containing config for all emojis that are setup at the collection level. It has the following properties. For all emojis setup, there'll be a key with the same emoji_name, and value as the config object for the same emoji.

Name

Type

Description

emoji_name

object

Object containing action and config info for the emoji

action: Type of action (assign or solved)

enabled: Indicates if the action is enabled

Ticketing Config Object

Ticket Config is represented as JSON object with the following properties

Name
Type
Description

enabled

boolean

Indicates if the feature is enabled

integration

string

The integration being used

method

object

Object containing method information. emoji: Name of the emoji used (if method is emoji) type: Type of method ("emoji" or "automatic")

CSAT Config Object

CSAT Config is represented as JSON object with the following properties

Name
Type
Description

enabled

boolean

Indicates if the feature is enabled

trigger_rules

array

Array of trigger rules. If there are no rules selected, then CSAT will be triggerred for all REQUESTS. Current possible rules are : {"name" : "tickets_only"}

trigger_type

string

Type of trigger (automatic or manual)

survey_config

object

Object containing survey configuration information survey_type: Type of survey (e.g., five_point_rating)

Channel Object

A channel monitored in a collection is represented as a JSON object with the following properties. It is included in the API when the include query parameter is passed with the value channels.

Name
Type
Description

id

string

Id of the monitored channel

owner

string

User Id of the primary individual responsible for the channel

name

string

Type of trigger (automatic or manual)

status

enum

Denotes the status of the channel in the collection

Status

Description

active

Channel belongs to the collection and is being actively monitored.

processing

Channel was added to the collection and last few messages of the channel are being processed.

inactive

Channel belongs to the collection but is not being monitored.

Get Collections

GET https://api.clearfeed.app/v1/rest/collections

Get all collections in your account

Query Parameters

Name
Type
Description

include?

Use include query parameter to include more data for each collection.

{
  "collections": [
    {
      "id": 1,
      "name": "premium customers",
      "created_by": "U05HGPBRZJN",
      "created_at": "2023-01-01T00:00:00.000Z",
      "updated_at": "2023-01-01T00:00:00.000Z",
      "config": {
        "story_detection": false,
        "force_story_request": true,
        "auto_assign": {
          "enabled": false
        },
        "responders": [
          {
            "responder_type": "users",
            "value": [
              "U038DHU0J6A"
            ]
          }
        ]
      },
      "emoji_config": {
        "emoji_names": {
          "eyes": {
            "action": "assign",
            "enabled": true,
            "action_config": {
              "apply_on_request_channel": true
            }
          },
          "white_check_mark": {
            "action": "solved",
            "enabled": true,
            "action_config": {
              "apply_on_request_channel": true
            }
          }
        }
      },
      "csat_config": {
        "enabled": true,
        "trigger_rules": [],
        "trigger_type": "automatic",
        "survey_config": {
          "survey_type": "five_point_rating"
        }
      },
      "ticketing_config": {
        "enabled": true,
        "integration": "zendesk",
        "method": {
          "emoji": "ticket",
          "type": "emoji"
        }
      },
      "channels": [
        {
          "id": "C06ASRDC6R0",
          "owner": "U038DHU0J6A",
          "name": "clearfeed-google",
          "status": "active"
        }
      ]
    }
  ]
}

Add Channels to a Collection

POST https://api.clearfeed.app/v1/rest/collections/:id/channels

Start monitoring channels by adding them to a collection.

Name
Type
Description

id

string

Id of the channel that needs to be added to the collection

owner

string

User Id of the primary individual responsible for the channel

Example

{
 "id" : "C01AB2CD1T", 
 "owner": "U038DHU0J6A" 
}

Request Body

Name
Type
Description

channels*

Array

Last updated