Please enable JavaScript to view this site.

iService API Documentation

Navigation: iService API Forms > Customer Info

Searching contacts (api=search)

Scroll Prev Top Next More

Purpose

 

The Search API is used to search for Contacts. The search interface support searching by various parameters, including all of your contact properties and the bounced status of logins. Search results are limited to the segments to which the user has been granted Segment Access.

 

UI Reference: The API is called when the Search button is clicked on the Search Contacts page.

 

URI:- webapp-api-custinfo?api=search

 

Access Rights Required:  All agent types are allowed to use this endpoint.

 

 

Request

 

Request Parameters

Name

Type

Description

fields

Object

Object containing the search groups that are logically combined with an AND operator.

fields.groups

Array

An array of fields that are grouped together with an AND operator.

fields.groups[].fields

Array

An array of fields that are grouped together with an OR operator.

fields.groups[].fields[].where

String

This parameter specifies where to match values. Values must be "anywhere", "start", "end", or "entire".

fields.groups[].fields[].fieldID

String

This parameter represents field to search for a value. Can be a number or list of values.

fields.groups[].fields[].searchString

String

This parameter represents the value to look for when searching.

 

 

Request payload Example

{
  "fields": {
    "groups": [
      {
        "fields": [
          {
            "where": "anywhere",
            "fieldID": "login",
            "searchString": "customer11"
          }
        ]
      }
    ]
  }
}

 

 

 

Response

 

Response Parameters

Name

Type

Description

errors

Array

An array of strings. Returns the error message if an error is encountered, otherwise a blank array if there is no error.

errorDetails

Array

An array of strings. Provides detailed information about the error encountered, otherwise returns a blank array if no error is encountered.

contacts

Array

An array of objects for each contact search result.

contacts[].ID

String

The ID of the contact.

contacts[].name

String

The name of the contact. If the contact has no name, their email address is displayed.

contacts[].logins

Array

An array of logins objects. See the Login API chapter for details.

contacts[].logins[].name

String

The vale for the contacts' login.

contacts[].logins[].type

String

The type of login (blank, email, bounced, or Google).

contacts[].firstname

Array

An array of property values. See the Properties for display page for the description of the property value structure.

contacts[].lastname

Array

An array of property values. See the Properties for display page for the description of the property value structure.

contacts[].address1

Array

An array of property values. See the Properties for display page for the description of the property value structure.

contacts[].address2

Array

An array of property values. See the Properties for display page for the description of the property value structure.

contcts[].customertype

Array

An array of property values. See the Properties for display page for the description of the property value structure.

contacts[].postalcode

Array

An array of property values. See the Properties for display page for the description of the property value structure.

contacts[].city

Array

An array of property values. See the Properties for display page for the description of the property value structure.

contacts[].country

Array

An array of property values. See the Properties for display page for the description of the property value structure.

contacts[].state

Array

An array of property values. See the Properties for display page for the description of the property value structure.

contacts[].email

String

The login marked as email is displayed here. Only a single value is displayed.

contacts[].phone

String

The contacts' phone number is displayed here. Only a single value is displayed.

contacts[].company

String

The contacts' company is displayed here. Only a single value is displayed.

contacts[].address

String

The contacts' address is displayed here. Only a single value is displayed.

contacts[].propertySummary

Array

Array of property data for the contact. See Properties for display.

resultCount

String

The number of contacts returned from the search.

 

 

Response Payload Example

{
  "errors": [],
  "errorDetails": [],
  "contacts": [
    {
      "id": "466",
      "name": "Deer, John",
      "logins": [
        {
          "name": "customer11@1to1service.com",
          "type": "Email"
        }
      ],
      "firstname": [
        {
          "description": null,
          "value": "John",
          "valueDate": null,
          "valueDatetime": null,
          "valueInt": null,
          "valueNumber": null
        }
      ],
      "lastname": [
        {
          "description": null,
          "value": "Deer",
          "valueDate": null,
          "valueDatetime": null,
          "valueInt": null,
          "valueNumber": null
        }
      ],
      "address1": [],
      "address2": [],
      "customertype": [],
      "postalcode": [],
      "city": [],
      "country": [],
      "state": [],
      "email": "customer11@1to1service.com",
      "phone": "",
      "company": "",
      "address": "",
      "propertySummary": [
        {
          "propertyID": "1",
          "values": [
            {
              "description": null,
              "value": "John",
              "valueDate": null,
              "valueDatetime": null,
              "valueInt": null,
              "valueNumber": null
            }
          ]
        },
        {
          "propertyID": "3",
          "values": [
            {
              "description": null,
              "value": "Deer",
              "valueDate": null,
              "valueDatetime": null,
              "valueInt": null,
              "valueNumber": null
            }
          ]
        },
        {
          "propertyID": "23",
          "values": [
            {
              "description": null,
              "value": "Musical Instruments",
              "valueDate": null,
              "valueDatetime": null,
              "valueInt": null,
              "valueNumber": null
            }
          ]
        }
      ]
    }
  ],
  "resultCount": "1"
}

 

© 2008 - 2022 One-to-One Service.com, Inc. All rights reserved.