Contact Filters

Note: This page has not yet been converted to the new developer portal format. Please use Swagger to test this API.

Contact Filters

Contact Filter Fields

FieldData Type (Length)Required?Read OnlyNotes
idlongnxThe internal ID for a contact filter. It is visible on the URI in the UI.
namestring (100)yThe name of the filter.
contactFilterTypestringnConstant ContactRule.
contactFilterRulescontactFilterRule[]yAn array of contactFilterrules.
createdDatelongnxUnix epoch date/time when the filter was created.
createdIdlongnxInternal ID of the user that created this filter.
createdNamestringnxFirst and last name of the user that created this filter.
lastModifiedDatelongnxUnix epoch date/time when the filter was last modified.
lastModifiedIdlongnxThe internal ID of the user that last modified this filter.
lastModifiedNamestringnxThe first and last name of the user that last modified this filter.
lastModifiedTimelongnxUnix epoch date/time when the filter was last modified.
lastSynchronizedTimelongnxUnix epoch date/time when the filter was last synchronized.
accountIdlongnxThe ID of the account that owns this resource.
statusstringnxThe status of the object. All records returned by the API should have a status of 'A' indicating that the record is active and has not been deleted.
Deleted records of any type are invisible to the API.
resourceBundleIdlongnxThe ID of the Role which owns this resource.
organizationIdlongnxThe ID of the organization to which this filter belongs.
dirtybooleannxWhether the contacts of this group have been updated and need to refresh map layer data.

Contact Filter Rule Fields

NameData Type (Length)Required?Description
idlongxThe internal ID for a contact.
contactFieldIdlongRequired if type is SYSTEM, SYSTEM_OBJECT or SYSTEM_ARRAY
columnNamestringRequired if type is SYSTEM, SYSTEM_OBJECT or SYSTEM_ARRAY
columnValueDepends on field type (string, date, number)Required if type is SYSTEM, SYSTEM_OBJECT or SYSTEM_ARRAY
attributeIdlongRequired if type is CUSTOM or CUSTOM_ARRAY
attributeValuesstring[]The values the filter is looking for. Required if type is CUSTOM or CUSTOM_ARRAY
typestringOne of:
◊ SYSTEM
◊ CUSTOM
◊ SYSTEM_OBJECT
◊ SYSTEM_ARRAY
◊ CUSTOM_ARRAY
◊ SYSTEM_SCHEDULING
◊ SYSTEM_EXPECTED_OBJECT
dataTypestringOne of:
◊ STRING
◊ NUMBER
◊ DATE
◊ BOOLEAN
operatorstringString
◊ STARTWITH
◊ ENDWITH (ends with)
◊ E (equal to)
◊ NE (not equal to)
◊ LIKE (contains)
◊ NLIKE (does not contain)
◊ GT (greater than)
◊ LT (less than)
◊ GTE (greater than or equal to)
◊ LTE (less than or equal to)

Number
◊ E (equal to)
◊ NE (not equal to)
◊ GT (greater than)
◊ LT (less than)
◊ GTE (greater than or equal to)
◊ LTE (less than or equal to)

Date field
◊ E (equal to)
◊ LT (is before)
◊ LTE (is equal to or before)
◊ GT (is after)
◊ GTE (is equal to or after)
◊ BETWEEN (between two dates)

Single select list
◊ E (equal to)
◊ NE (not equal to)

Multiple choice list
◊ IN (contains)
◊ NIN (does not contain)
contactFilteroptionstringSame as operator

Details below:

columnNamedataTypetypeoperatorembeddedColumnName
firstNameSTRINGSYSTEMSTARTWITH,ENDWITH,E,NE,LIKE,NLIKE
lastNameSTRINGSYSTEMSTARTWITH,ENDWITH,E,NE,LIKE,NLIKE
middleInitialSTRINGSYSTEMSTARTWITH,ENDWITH,E,NE,LIKE,NLIKE
suffixSTRINGSYSTEMSTARTWITH,ENDWITH,E,NE,LIKE,NLIKE
externalIdSTRINGSYSTEMSTARTWITH,ENDWITH,E,NE,LIKE,NLIKE
countrySTRINGSYSTEMSTARTWITH,ENDWITH,E,NE,LIKE,NLIKE
recordTypeIdNUMBERSYSTEME,NE,LT,LTE,GT,GTE
userIdNUMBERSYSTEMISNULL,NOTNULL
individualAccountIdNUMBERSYSTEMISNULL,NOTNULL
lastModifiedDateDATESYSTEMBETWEEN,LT,LTE,GT,GTE
lastModifiedNameSTRINGSYSTEMSTARTWITH,ENDWITH,E,NE,LIKE,NLIKE
registedEmailSTRINGSYSTEMSTARTWITH,ENDWITH,E,NE,LIKE,NLIKE
registedDateDATESYSTEMBETWEEN,LT,LTE,GT,GTE
groupsNUMBERSYSTEM_ARRAYIN,NIN
valueSTRINGSYSTEM_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEpaths
locationNameSTRINGSYSTEM_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEaddress
streetAddressSTRINGSYSTEM_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEaddress
suiteSTRINGSYSTEM_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEaddress
citySTRINGSYSTEM_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEaddress
stateSTRINGSYSTEM_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEaddress
postalCodeSTRINGSYSTEM_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEaddress
countrySTRINGSYSTEM_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEaddress
address.gisLocation.lonNUMBERSYSTEMISNULL,NOTNULL
addressGeoCodingSourceSTRINGSYSTEM_OBJECTIN,NINaddress
locationIdNUMBERSYSTEM_OBJECTE,NE,LT,LTE,GT,GTE
floorNoSTRINGSYSTEM_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEaddress
floorNoSTRINGSYSTEM_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKElastKnownLocation
address.streetAddressBOOLEANSYSTEMISNULL,NOTNULL
gisLocation.latNUMBERSYSTEM_OBJECTE,NE,LT,LTE,GT,GTEaddress
gislocation.lonNUMBERSYSTEM_OBJECTE,NE,LT,LTE,GT,GTEaddress
pathIdNUMBERSYSTEM_OBJECTIN,NINpaths
createdDateDATESYSTEMBETWEEN,LT,LTE,GT,GTE
topicsNUMBERSYSTEMIN,NIN
systemRequirementSTRINGSYSTEM_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEpaths
calendarNUMBERSYSTEM_SCHEDULINGE
shiftNUMBERSYSTEM_SCHEDULINGE
shiftDateDATE*SYSTEM_SCHEDULINGBETWEEN
ssoIdentitySTRINGSYSTEMSTARTWITH,ENDWITH,E,NE,LIKE,NLIKE
smUserIdNUMBERSYSTEMISNULL,NOTNULL
expectedDateDATE*SYSTEM_EXPECTED_OBJECTBETWEEN,LT,LTE,GT,GTE, BETWEEN
locationNameSTRINGSYSTEM_EXPECTED_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEaddress
citySTRINGSYSTEM_EXPECTED_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEaddress
stateSTRINGSYSTEM_EXPECTED_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEaddress
countrySTRINGSYSTEM_EXPECTED_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEaddress
iataSTRINGSYSTEM_EXPECTED_OBJECTSTARTWITH,ENDWITH,E,NE,LIKE,NLIKEaddress
locationIdSTRINGSYSTEM_EXPECTED_OBJECTE,NE,LT,LTE,GT,GTEaddress

NOTE: columnValue(except sxpectedDate, shiftDate) depends on operator, if it is IN, NIN, BETWEEN, columnValue should be an array, otherwise as data type indicates.
expectedDate and shiftDate are special. Their value should be an array with three elements, and there are only two patterns: ["NOW",null,null] or ["BETWEEN", fromDate, toDate].

GET /contactFilters/{organizationId}

Description

Retrieve multiple contact filters.

Return type

contactFilter Object

Parameters

NameData TypeRequired?Description
credentialsstringyBasic Authorization header.
organizationIdlongyThe ID of the organization containing the contacts.
pageNumberintyThe page number of results to retrieve. Default is 1.
{
    "message": "OK",
    "firstPageUri": "https://api.everbridge.net/rest/contactFilters/892807736728255/?pageNumber=1",
    "nextPageUri": "https://api.everbridge.net/rest/contactFilters/{organizationId}/?pageNumber=2",
    "lastPageUri": "https://api.everbridge.net/rest/contactFilters/892807736728255/?pageNumber=1",
    "page": {
        "pageSize": 20,
        "start": 0,
        "data": [
            {
                "lastModifiedTime": 0,
                "accountId": 0,
                "resourceBundleId": 892807736730016,
                "contactFilterType": "ContactRule",
                "organizationId": 0,
                "id": 2457979718729733,
                "name": "Test calendar",
                "lastModifiedDate": 1650549036871,
                "lastModifiedId": 0,
                "createdId": 0,
                "lastSynchronizedTime": 0,
                "lastModifiedName": "Paulomi Mahidharia",
                "contactFilterRules": [
                    {
                        "contactFieldId": 200,
                        "type": "SYSTEM_SCHEDULING",
                        "operator": "E",
                        "dataType": "NUMBER",
                        "columnName": "calendar",
                        "contactFilterOption": "E",
                        "columnValue": 2457962538860545
                    },
                    {
                        "contactFieldId": 201,
                        "type": "SYSTEM_SCHEDULING",
                        "operator": "E",
                        "dataType": "NUMBER",
                        "columnName": "shift",
                        "contactFilterOption": "E",
                        "columnValue": 0
                    },
                    {
                        "contactFieldId": 202,
                        "type": "SYSTEM_SCHEDULING",
                        "operator": "BETWEEN",
                        "dataType": "DATE",
                        "columnName": "shiftDate",
                        "contactFilterOption": "BETWEEN",
                        "columnValue": [
                            "NOW",
                            null,
                            null
                        ]
                    }
                ],
                "dirty": true
            }
        ],
        "totalCount": 4,
        "totalPageCount": 1,
        "currentPageNo": 1
    }
}

POST /contactFilters/{organizationId}

Description

Create a new contactFilter within an organization.

Return type

contactFilter Object

Parameters

NameData TypeRequired?Description
credentialsstringyBasic Authorization header.
organizationIdlongyThe ID of the organization containing the contacts.
contactFiltercontactFilterWrapperyThe JSON object describing the new contactFilter.

Example Request Body

{
  "name": "DBAs",
  "contactFilterRules": [
    {
      "attributeId": 3549227829428287,
      "type": "CUSTOM",
      "operator": "LIKE",
      "dataType": "STRING",
      "attributeValues": [
        "DBA"
      ],
      "contactFilterOption": "LIKE"
    },
    {
      "contactFieldId": 1,
      "type": "SYSTEM",
      "operator": "NLIKE",
      "dataType": "STRING",
      "columnName": "firstName",
      "contactFilterOption": "NLIKE",
      "columnValue": "Mike"
    }
  ]
}

Example Returns

{
  "message": "OK",
  "id": "{the internal id of the record just created}",
  "baseUri": "https://api.everbridge.net/rest/contactFilters/{organizationId}/",
  "instanceUri": "https://api.everbridge.net/rest/contactFilters/{organizationId}/{contactFilterId}"
}

GET /contactFilters/{organizationId}/{queryValue}

Description

Retrieve the specified contactFilter within an organization.

Return type

contactFilter Object

Parameters

NameData TypeRequired?Description
credentialsstringyBasic Authorization header.
organizationIdlongyThe ID of the organization containing the contacts.
queryValuestringyThe ID or name of the contactFilter.
queryTypestringyWhether to search by contactFilter.id or contactFilter.Name.

POST /contactFilters/{organizationId}/{contactFilterId}

Description

Retrieve a single contactFilter.

Parameters

None

Returns

{
  "id": 3083039194221618,
  "name": "Applications Primary On Call",
  "contactFilterType": "ContactRule",
  "contactFilterRules": [
    {
      "contactFieldId": 200,
      "type": "SYSTEM_SCHEDULING",
      "operator": "E",
      "dataType": "NUMBER",
      "columnName": "calendar",
      "contactFilterOption": "E",
      "columnValue": 3083034899251300
    },
    {
      "contactFieldId": 201,
      "type": "SYSTEM_SCHEDULING",
      "operator": "E",
      "dataType": "NUMBER",
      "columnName": "shift",
      "contactFilterOption": "E",
      "columnValue": 3083034899251335
    },
    {
      "contactFieldId": 202,
      "type": "SYSTEM_SCHEDULING",
      "operator": "BETWEEN",
      "dataType": "DATE",
      "columnName": "shiftDate",
      "contactFilterOption": "BETWEEN",
      "columnValue": [
        "NOW",
        null,
        null
      ]
    }
  ],
  "createdDate": 1407517981481,
  "createdId": 892807736721858,
  "createdName": "Mike Wallick",
  "lastModifiedDate": 1407518281577,
  "lastModifiedId": 892807736721858,
  "lastModifiedName": "Mike Wallick",
  "lastModifiedTime": 0,
  "lastSynchronizedTime": 0,
  "accountId": 1772417038942236,
  "status": "A",
  "resourceBundleId": 892807736721838,
  "organizationId": 892807736721854,
  "dirty": true
}

PUT /contactFilters/{organizationId}/{contactFilterId}

Description

Update a contactFilter within an organization.

Return type

contactFilter Object

Parameters

None

Example Request Body

The request body is identical to the POST method.

Example Returns

{
  "message": "OK",
  "id": "{the internal id of the record just updated}",
  "baseUri": "https://api.everbridge.net/rest/contactFilters/{organizationId}/",
  "instanceUri": "https://api.everbridge.net/rest/contactFilters/{organizationId}/{contactFilterId}"
}

DELETE /contactFilters/{organizationId}/{contactFilterId}

Description

Delete the specified contactFilter from an organization.

Return type

contactFilter Object

Parameters

NameData TypeRequired?Description
credentialsstringyBasic Authorization header.
organizationIdlongyThe ID of the organization containing the contactFilters.
contactFilterIdlongyThe ID or name of the contactFilter to delete.

Example Request Body

None

Example Returns

{
  "message": "OK",
  "id": "{the internal id of the record just deleted}",
  "baseUri": "https://api.everbridge.net/rest/contactFilters/{organizationId}/",
  "instanceUri": "https://api.everbridge.net/rest/contactFilters/{organizationId}/{contactFilterId}"
}