listProfiles

get

/ccadmin/v1/profiles

List Profiles. This operation is used to get the collection of customer profiles from Oracle Commerce Cloud. Optionally takes the x-ccasset-language header to get translated content in another language. It can also be used to return the list on a searched string and in a sorted order against various properties of profile.

Request

Supported Media Types
  • application/json
Query Parameters
limit
Type: string
This is the field to determine number of records to be fetched per REST call.
offset
Type: string
This field determines the offset/starting index from which data to be fetched.
preview
Type: string
If true, then preview profiles will be searched..
q
Type: string
Query string built as per the SCIM standards that helps to search entered string across contact properties, 'firstName', 'lastName', 'email', 'parentOrganization' and 'profileType' and also dynamic contact properties.
sort
Type: string
This field determines the sort order of the list to be fetched.
useAdvancedQParser
Type: boolean
This field determines the parser to be used. Default parser has limitations and nested queries or complex queries cannot be executed using this default parser. It is recommended to use this flag as true.
Header Parameters
X-CCAsset-Language
Type: string
The asset language of the request

Response

Supported Media Types
  • application/json
200 Response
Following model is returned when operation succeeds.
Body
Root Schema : listProfiles_response
Nested Schema : items
Type: array
list of shopper profiles
Nested Schema : items
Type: object
Nested Schema : billingAddress
Type: object
Default billing address of the profile
Nested Schema : derivedPriceListGroup
Type: object
The derived price list group from the user's parent organization
Nested Schema : derivedSalePriceList
Type: object
The derived sale price list from the user's parent organization
Nested Schema : derivedShippingSurchargePriceList
Type: object
The derived shipping surcharge price list from the user's parent organization
Nested Schema : dynamicInternalOnlyProperty
Type: object
The value of the internalOnly dynamic property
Nested Schema : dynamicProperty
Type: object
the value of the dynamic property
Nested Schema : loyaltyPrograms
Type: array
Loyalty Programs Information
Nested Schema : parentOrganization
Type: object
This attribute is added for 'Account Based Commerce', this is required only in case of 'Account Based Commerce', this is the id of organization to which user is associated
Nested Schema : priceListGroup
Type: object
The associated price list group for this user
Nested Schema : roles
Type: array
List of user roles.
Nested Schema : secondaryOrganizations
Type: array
List of secondary organizations associated to profile. It will be empty always. Secondary Organizations associated to the profile can be fetched using organization endpoints
Nested Schema : shippingAddress
Type: object
Default shipping address of the profile
Nested Schema : shippingAddresses
Type: array
List of shipping addresses associated with profile.
Nested Schema : shippingSurchargePriceList
Type: object
The shipping surcharge price list for this user
Nested Schema : translations
Type: array
List of available locales for the user
Nested Schema : items
Type: object
Nested Schema : billingAddress
Type: object
Default billing address of the profile
Nested Schema : secondaryAddresses
Type: array
List of shipping addresses associated with profile.
Nested Schema : shippingAddress
Type: object
Default shipping address of the profile
Nested Schema : items
Type: object
Nested Schema : items
Type: object
Nested Schema : relativeTo
Type: object
Organization ID of the role.
Nested Schema : items
Type: object
Nested Schema : billingAddress
Type: object
Default billing address of the profile
Nested Schema : secondaryAddresses
Type: array
List of shipping addresses associated with profile.
Nested Schema : shippingAddress
Type: object
Default shipping address of the profile
Nested Schema : items
Type: object
Nested Schema : items
Type: object
Nested Schema : items
Type: object
Example application/json

{
    "total":3,
    "totalResults":3,
    "offset":0,
    "limit":3,
    "links":[
        {
            "rel":"self",
            "href":"http://localhost:9080/ccadmin/v1/profiles?limit=20&offset=0&sort=email:asc&q=lastName%20co%20%22test%22%20or%20email%20co%20%22test%22%20and%20profileType%20eq%20%22b2b_user%22%20and%20parentOrganization%20eq%20%22null%22%20and%20roles.function%20eq%20%22buyer%22"
        }
    ],
    "sort":[
        {
            "property":"email",
            "order":"asc"
        },
        {
            "property":"firstName",
            "order":"asc"
        },
        {
            "property":"lastName",
            "order":"asc"
        }
    ],
    "items":[
        {
            "derivedPriceListGroup":null,
            "lastName":"jetu#$%^&test",
            "gender":"female",
            "catalog":null,
            "roles":[
                {
                    "function":"buyer",
                    "repositoryId":"100006"
                }
            ],
            "locale":"en",
            "parentOrganization":null,
            "shippingSurchargePriceList":null,
            "profileType":"b2b_user",
            "translations":{
            },
            "id":"120015",
            "email":"test&@test.com",
            "daytimeTelephoneNumber":null,
            "derivedSalePriceList":null,
            "taxExempt":false,
            "receiveEmail":"yes",
            "active":true,
            "priceListGroup":null,
            "dateOfBirth":null,
            "firstName":"jetu&",
            "repositoryId":"120015",
            "shippingAddress":null,
            "lastActivity":"2017-01-09T19:21:39.000Z",
            "userType":null,
            "billingAddress":null,
            "derivedShippingSurchargePriceList":null,
            "secondaryOrganizations":[
            ],
            "shippingAddresses":[
            ]
        },
        {
            "derivedPriceListGroup":null,
            "lastName":"!@#$%^&*",
            "gender":"female",
            "catalog":null,
            "roles":[
                {
                    "function":"buyer",
                    "repositoryId":"100006"
                }
            ],
            "locale":"en",
            "parentOrganization":null,
            "shippingSurchargePriceList":null,
            "profileType":"b2b_user",
            "translations":{
            },
            "id":"130000",
            "email":"test1@abc.com",
            "daytimeTelephoneNumber":null,
            "derivedSalePriceList":null,
            "taxExempt":false,
            "receiveEmail":"yes",
            "active":true,
            "priceListGroup":null,
            "dateOfBirth":null,
            "firstName":"test1",
            "repositoryId":"130000",
            "shippingAddress":null,
            "lastActivity":"2017-01-09T19:21:39.000Z",
            "userType":null,
            "billingAddress":null,
            "derivedShippingSurchargePriceList":null,
            "secondaryOrganizations":[
            ],
            "shippingAddresses":[
            ]
        },
        {
            "derivedPriceListGroup":null,
            "lastName":"Test",
            "gender":"female",
            "catalog":null,
            "roles":[
                {
                    "function":"buyer",
                    "repositoryId":"100006"
                }
            ],
            "locale":"en",
            "parentOrganization":null,
            "shippingSurchargePriceList":null,
            "profileType":"b2b_user",
            "translations":{
            },
            "loyaltyPrograms":[
                {
                    "programName":"XTRAREWARDS",
                    "repositoryId":100001,
                    "membershipId":"abc123",
                    "programId":"prog1",
                    "status":"Enrolled"
                },
                {
                    "programName":"XTRAMILES",
                    "repositoryId":100002,
                    "membershipId":"xyz123",
                    "programId":"prog2",
                    "status":"Enrolled"
                }
            ],
            "id":"120008",
            "email":"test@test.com",
            "daytimeTelephoneNumber":null,
            "derivedSalePriceList":null,
            "taxExempt":false,
            "receiveEmail":"yes",
            "active":true,
            "priceListGroup":null,
            "dateOfBirth":null,
            "firstName":"test",
            "repositoryId":"120008",
            "shippingAddress":null,
            "lastActivity":"2017-01-09T19:21:39.000Z",
            "userType":null,
            "billingAddress":null,
            "derivedShippingSurchargePriceList":null,
            "secondaryOrganizations":[
            ],
            "shippingAddresses":[
            ]
        }
    ]
}
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: |Error Code|Description| |------------------|------------------| |100070|Invalid Query Expression.| |22000|If the profile id passes is null or empty| |22001|If there was any internal error while getting the profile| |10002|The value x for parameter 'y' is invalid. 'y' can be 'limit', 'offset' or 'sort'.| |22002|If there was no profile found with the given id| |22039|If there was any internal error while listing the profiles|
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:

{
  "total": 3,
  "totalResults": 3,
  "offset": 0,
  "limit": 3,
  "links": [{
    "rel": "self",
    "href": "http://localhost:9080/ccadmin/v1/profiles?limit=20&offset=0&sort=email:asc&q=lastName%20co%20%22test%22%20or%20email%20co%20%22test%22%20and%20profileType%20eq%20%22b2b_user%22%20and%20parentOrganization%20eq%20%22null%22%20and%20roles.function%20eq%20%22buyer%22"
  }],
  "sort": [
    {
      "property": "email",
      "order": "asc"
    },
    {
      "property": "firstName",
      "order": "asc"
    },
    {
      "property": "lastName",
      "order": "asc"
    }
  ],
  "items": [
    {
      "derivedPriceListGroup": null,
      "lastName": "jetu#$%^&test",
      "gender": "female",
      "catalog": null,
      "roles": [{
        "function": "buyer",
        "repositoryId": "100006"
      }],
      "locale": "en",
      "parentOrganization": null,
      "shippingSurchargePriceList": null,
      "profileType": "b2b_user",
      "translations": {},
      "id": "120015",
      "email": "test&@test.com",
      "daytimeTelephoneNumber": null,
      "derivedSalePriceList": null,
      "taxExempt": false,
      "receiveEmail": "yes",
      "active": true,
      "priceListGroup": null,
      "dateOfBirth": null,
      "firstName": "jetu&",
      "repositoryId": "120015",
      "shippingAddress": null,
      "lastActivity": "2017-01-09T19:21:39.000Z",
      "userType": null,
      "billingAddress": null,
      "derivedShippingSurchargePriceList": null,
      "secondaryOrganizations": [],
      "shippingAddresses": []
    },
    {
      "derivedPriceListGroup": null,
      "lastName": "!@#$%^&*",
      "gender": "female",
      "catalog": null,
      "roles": [{
        "function": "buyer",
        "repositoryId": "100006"
      }],
      "locale": "en",
      "parentOrganization": null,
      "shippingSurchargePriceList": null,
      "profileType": "b2b_user",
      "translations": {},
      "id": "130000",
      "email": "test1@abc.com",
      "daytimeTelephoneNumber": null,
      "derivedSalePriceList": null,
      "taxExempt": false,
      "receiveEmail": "yes",
      "active": true,
      "priceListGroup": null,
      "dateOfBirth": null,
      "firstName": "test1",
      "repositoryId": "130000",
      "shippingAddress": null,
      "lastActivity": "2017-01-09T19:21:39.000Z",
      "userType": null,
      "billingAddress": null,
      "derivedShippingSurchargePriceList": null,
      "secondaryOrganizations": [],
      "shippingAddresses": []
    },
    {
      "derivedPriceListGroup": null,
      "lastName": "Test",
      "gender": "female",
      "catalog": null,
      "roles": [{
        "function": "buyer",
        "repositoryId": "100006"
      }],
      "locale": "en",
      "parentOrganization": null,
      "shippingSurchargePriceList": null,
      "profileType": "b2b_user",
      "translations": {},
      "loyaltyPrograms": [
        {
          "programName": "XTRAREWARDS",
          "repositoryId": 100001,
          "membershipId": "abc123",
          "programId": "prog1",
          "status": "Enrolled"
        },
        {
          "programName": "XTRAMILES",
          "repositoryId": 100002,
          "membershipId": "xyz123",
          "programId": "prog2",
          "status": "Enrolled"
        }
      ],
      "id": "120008",
      "email": "test@test.com",
      "daytimeTelephoneNumber": null,
      "derivedSalePriceList": null,
      "taxExempt": false,
      "receiveEmail": "yes",
      "active": true,
      "priceListGroup": null,
      "dateOfBirth": null,
      "firstName": "test",
      "repositoryId": "120008",
      "shippingAddress": null,
      "lastActivity": "2017-01-09T19:21:39.000Z",
      "userType": null,
      "billingAddress": null,
      "derivedShippingSurchargePriceList": null,
      "secondaryOrganizations": [],
      "shippingAddresses": []
    }
  ]
}