REST API OCST - Get Customer List

URI

/customers

Http Method

GET

Short Description

Retrieves a fixed maximum number of customers based on the query parameters given

Query Parameters

Defined query fields:

SingleSearchField -Search for Last Name, EMail & Customer Number
CustomerNo - Customer number
FirstName - First name
LastName - Last name
Birthday - Birthday (supported patterns: "yyyy-MM-dd", "MM/dd/yyyy", "dd.MM.yyyy")
EMail - EMail address
PhoneNo - Searches all Phone No fields: Phone Home, Phone Business Phone Mobile
PostCode - Postal/ZIP code
City - City
Country - Country name or country code e.g. "DE"
Channel - comma separated list of channels to search the customers for

At least one of the following fields: SingleSearchField, EMail, LastName, CustomerNo must be set.
Empty fields are ignored.
If no channel is specified, all sales channels of the current organization will be used.

Example Requests

/customers?SingleSearchField=Meyer&Channel=PrimeTech-PrimeTechBusiness,PrimeTech-PrimeTechSpecials

/customers?LastName=Mayer&Channel=PrimeTech-PrimeTechSpecials

/customers?CustomerNo=10005

HTTP Status Codes

200 OK

400 Bad Request

401 Authorization Required

Description

Gets a fixed maximum number of customers that match the specified search parameters. The search parameters are attached to the request as query parameters.

Cartridge

app_sf_contactcenter_rest

Application

ContactCenter

Product Version

7.5.1

Product To Version

Status

final

JSON

Request Data Format

Request related java object

com.intershop.application.contactcenter.capi.rest.resource.CustomerListResource

Request Example

 

Response Data Format

application/json

Response related java object

com.intershop.application.contactcenter.capi.rest.resource.CustomerListResource
com.intershop.component.rest.capi.resourceobject.LinkRO

Response Example

{
    "elements":
    [
        {
            "type": "Link",
            "uri": "ContactCenter/-/customers/cokKCgoKKaEAAAE_4SIKfNMG",
            "title": "Patricia Miller",
            "attributes":
            [
                {
                    "name": "channel",
                    "type": "String",
                    "value": "PrimeTech-PrimeTechSpecials"
                },
                {
                    "name": "birthday",
                    "type": "String",
                    "value": "1985-12-31"
                },
                {
                    "name": "lastName",
                    "type": "String",
                    "value": "Miller"
                },
                {
                    "name": "email",
                    "type": "String",
                    "value": "pmiller@intershop.com"
                },
                {
                    "name": "street",
                    "type": "String",
                    "value": "5th Rd. Blue Ash"
                },
                {
                    "name": "customerNo",
                    "type": "String",
                    "value": "123456789"
                },
                {
                    "name": "firstName",
                    "type": "String",
                    "value": "Patricia"
                },
                {
                    "name": "country",
                    "type": "String",
                    "value": "USA"
                },
                {
                    "name": "city",
                    "type": "String",
                    "value": "Detroit"
                }
            ]
        },
        {
            "type": "Link",
            "uri": "ContactCenter/-/customers/moklCgjKKaEApAE_4S8KfNMG",
            "title": "Karl Fischer",
            "attributes":
            [
                {
                    "name": "channel",
                    "type": "String",
                    "value": "PrimeTech-PrimeTechSpecials"
                },
                {
                    "name": "birthday",
                    "type": "String",
                    "value": "1980-11-21"
                },
                {
                    "name": "lastName",
                    "type": "String",
                    "value": "Fischer"
                },
                {
                    "name": "email",
                    "type": "String",
                    "value": "kfischer@intershop.com"
                },
                {
                    "name": "street",
                    "type": "String",
                    "value": "7th Rd. Blue Ash"
                },
                {
                    "name": "customerNo",
                    "type": "String",
                    "value": "623426730"
                },
                {
                    "name": "firstName",
                    "type": "String",
                    "value": "Karl"
                },
                {
                    "name": "country",
                    "type": "String",
                    "value": "USA"
                },
                {
                    "name": "city",
                    "type": "String",
                    "value": "Detroit"
                }
            ]
        }
    ],
    "type": "ResourceCollection",
    "name": "customers"
}

XML

XML Request Data Format

XML Request Java Objects

com.intershop.application.contactcenter.capi.rest.resource.CustomerListResource

XML Request Example

 

XML Response Data Format

text/xml

XML Response Java Objects

com.intershop.application.contactcenter.capi.rest.resource.CustomerListResource
com.intershop.component.rest.capi.resourceobject.LinkRO

XML Response Example

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ResourceCollection name="customers" type="ResourceCollection">
    <elements>
        <Link type="Link">
            <attributes>
                <ResourceAttribute name="channel" type="String">
                    <value>PrimeTech-PrimeTechSpecials</value>
                </ResourceAttribute>
                <ResourceAttribute name="birthday" type="String">
                    <value>1985-12-31</value>
                </ResourceAttribute>
                <ResourceAttribute name="lastName" type="String">
                    <value>Miller</value>
                </ResourceAttribute>
                <ResourceAttribute name="email" type="String">
                    <value>pmiller@intershop.com</value>
                </ResourceAttribute>
                <ResourceAttribute name="street" type="String">
                    <value>5th Rd. Blue Ash</value>
                </ResourceAttribute>
                <ResourceAttribute name="customerNo" type="String">
                    <value>123456789</value>
                </ResourceAttribute>
                <ResourceAttribute name="firstName" type="String">
                    <value>Patricia</value>
                </ResourceAttribute>
                <ResourceAttribute name="country" type="String">
                    <value>USA</value>
                </ResourceAttribute>
                <ResourceAttribute name="city" type="String">
                    <value>Detroit</value>
                </ResourceAttribute>
            </attributes>
            <title>Patricia Miller</title>
            <uri>ContactCenter/-/customers/cokKCgoKKaEAAAE_4SIKfNMG</uri>
        </Link>
        <Link type="Link">
            <attributes>
                <ResourceAttribute name="channel" type="String">
                    <value>PrimeTech-PrimeTechSpecials</value>
                </ResourceAttribute>
                <ResourceAttribute name="birthday" type="String">
                    <value>1980-11-21</value>
                </ResourceAttribute>
                <ResourceAttribute name="lastName" type="String">
                    <value>Fischer</value>
                </ResourceAttribute>
                <ResourceAttribute name="email" type="String">
                    <value>kfischer@intershop.com</value>
                </ResourceAttribute>
                <ResourceAttribute name="street" type="String">
                    <value>7th Rd. Blue Ash</value>
                </ResourceAttribute>
                <ResourceAttribute name="customerNo" type="String">
                    <value>623426730</value>
                </ResourceAttribute>
                <ResourceAttribute name="firstName" type="String">
                    <value>Karl</value>
                </ResourceAttribute>
                <ResourceAttribute name="country" type="String">
                    <value>USA</value>
                </ResourceAttribute>
                <ResourceAttribute name="city" type="String">
                    <value>Detroit</value>
                </ResourceAttribute>
            </attributes>
            <title>Karl Fischer</title>
            <uri>ContactCenter/-/customers/moklCgjKKaEApAE_4S8KfNMG</uri>
        </Link>
    </elements>
</ResourceCollection>


Disclaimer

The information provided in the Knowledge Base may not be applicable to all systems and situations. Intershop Communications will not be liable to any party for any direct or indirect damages resulting from the use of the Customer Support section of the Intershop Corporate Web site, including, without limitation, any lost profits, business interruption, loss of programs or other data on your information handling system.

Customer Support
Knowledge Base
Product Resources
Support Tickets