searchProfiles

get

/ccagent/v1/profiles

Search Profiles. Get profiles by the search criteria entered. The search criteria include First Name, Last Name, Email, Postal Code, Phone Number .

Request

Supported Media Types
  • application/json
Query Parameters
fields
Type: string
This controls which fields are returned in the response body. Applicable when queryFormat=SCIM
limit
Type: integer
This is the field to specify the number of records to be fetched per REST call. Applicable when queryFormat=SCIM
offset
Type: integer
This field specifies the offset/starting index from which data to be fetched. Applicable when queryFormat=SCIM
q
Type: string
Required: true
Search criteria - Following are the fields supported by this param: |Field|Type|Description| |------------------|------------------|------------------| |firstName|string|First name of the profile| |lastName|string|Last name of the profile| |phoneNumber|string|The phone Number of the shipping address.| |pageNumber|integer|The page number for pagination| |postalCode|string|The postal Code of the shipping address| |limit|integer|The batch size of the order records to be fetched together.| |email|string|email of the profile| Search criteria in SCIM Format should be as: firstName co "Kim". Searching with custom properties: For Text Search, add prefix "dynProps_" (case sensitive) to the name of custom property being searched. For example: For a custom property with name as isVipCustomer, use search criteria field as dynProps_isVipCustomer. For SCIM Search, use the custom property name as the search criteria field without any prefix. For example: For a custom property with name as isVipCustomer, use search criteria field as isVipCustomer.
queryFormat
Type: string
Should be SCIM if we are searching using SCIM query format
sort
Type: string
This field specifies the sort order of the list to be fetched. Applicable when queryFormat=SCIM
totalResults
Type: boolean
Indicates if the total results should be included in the response. Applicable when queryFormat=SCIM

Response

Supported Media Types
  • application/json
200 Response
Following model is returned when operation succeeds.
Body
Root Schema : searchProfiles_response
Nested Schema : items
Type: array
List of customer profiles. SCIM query response contains this property.
Nested Schema : profileList
Type: array
List of profiles. Non-SCIM query response contains this property.
Nested Schema : sort
Type: array
An array that specifies the sort order. SCIM query response contains this property.
Nested Schema : items
Type: object
Nested Schema : parentOrganization
Type: object
The parent Organization associated with the B2B customer profile.
Nested Schema : secondaryOrganizations
Type: array
The secondary organizations associated with the B2B customer profile.
Nested Schema : shippingAddress
Type: object
Details of the customer's shipping address.
Nested Schema : items
Type: object
Nested Schema : items
Type: object
Nested Schema : profileDetail
Type: object
Details of the customer profile
Nested Schema : shippingAddress
Type: object
Details of the customer's shipping address.
Nested Schema : items
Type: object
Example application/json

{
    "profileList":[
        {
            "profileDetail":{
                "firstName":"Kim",
                "lastName":"Anderson",
                "repositoryId":"se-570031",
                "shippingAddress":{
                    "phoneNumber":"212-555-1977",
                    "postalCode":"13202",
                    "repositoryId":"se-980031"
                },
                "id":"se-570031",
                "parentOrganization":null,
                "email":"kim@example.com"
            },
            "numberOfOrders":43,
            "latestOrderId":"o10042",
            "hasIncompleteOrder":false
        }
    ],
    "hasMore":false,
    "links":[
        {
            "rel":"self",
            "href":"http://localhost:9080/ccagentui/v1/profiles?q=%7BfirstName=kim%2ClastName=%22%22%2Climit=20%2CpageNumber=0%2CrequireCount=false%7D"
        }
    ],
    "totalNoOfProfiles":1
}
Default Response
The error response. The following are the internal error codes thrown by this API when the request processing fails in Oracle Commerce Cloud: Below is the list of error codes specific to Text Search: |Error Code|Description| |------------------|------------------| |100001|Search client internal error.| |100002|Invalid date format| |100003|No pagination info passed in the search reuqest.| |100004|Invalid search criteria passed in search request.| |100006|Invalid boolean value.| |100013|Text search configuration is not enabled. Please enable text search to fetch the records Below is the list of error codes specific to SCIM Search: |Error Code|Description| |------------------|------------------| |85003|Invalid attribute in query
Body
Root Schema : errorModel
Type: object
Nested Schema : errors
Type: array
An optional list of errors if multiple errors were encountered
Nested Schema : items
Type: object

Examples

Sample Response Payload returned by endpoint:

{
  "profileList": [{
    "profileDetail": {
      "firstName": "Kim",
      "lastName": "Anderson",
      "repositoryId": "se-570031",
      "shippingAddress": {
        "phoneNumber": "212-555-1977",
        "postalCode": "13202",
        "repositoryId": "se-980031"
      },
      "id": "se-570031",
      "parentOrganization": null,
      "email": "kim@example.com"
    },
    "numberOfOrders": 43,
    "latestOrderId": "o10042",
    "hasIncompleteOrder": false
  }],
  "hasMore": false,
  "links": [{
    "rel": "self",
    "href": "http://localhost:9080/ccagentui/v1/profiles?q=%7BfirstName=kim%2ClastName=%22%22%2Climit=20%2CpageNumber=0%2CrequireCount=false%7D"
  }],
  "totalNoOfProfiles": 1
}