Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Content Items

  • Spotlights

  • Campaigns

  • Redirect Rules

  • Landing Pages

...

To access the REST API, the app follows the steps below:

  1. Obtain the authorization token using Salesforce Rest API

    Using post request https://login.salesforce.com/services/oauth2/token to endpoint with grant_type =  password

  2. Use authorization token provided in step 1 token to get products and categories CloudCraze REST APIs.

  3. The APP uses the REST API fetch method of the ccproduct object CCProduct sObject to get product data

    NOTE: Product REST API details for creating the app referenced from the wiki link https://cloudcraze.atlassian.net/wiki/spaces/CCRZDOCS49S/pages/392169161/Product+REST+API

    Code Block
    languagejson
    POST /services/apexrest/ccrz/ccproduct/v8/fetch
    
    {
    "storefront": "DefaultStore",
    "LIMIT":           "200",
    "OFFSET":      "0",
    "ISPRICED":   true
    }

  4. The APP uses the fetch method of the cccategory object to access the category data

    NOTE: Category REST API details for accessing the category data for the App were referenced from the wiki link https://cloudcraze.atlassian.net/wiki/spaces/CCRZDOCS49S/pages/392005269/Category+REST+API

    Code Block
    languagejson
    POST /services/apexrest/ccrz/cccategory/v8/fetch
    
    {
    "SIZING": {
        "product": {
            "LIMIT":     "200",
            "OFFSET":            "0",
            "sz_data": "sz_s"
            }
        }
    }


    The App loads Product and category data in batches using LIMIT parameter. For example if you have 1000 products and LIMIT is set to 200, the APP will make five requests to fetch product data from the REST API call. The maximum number of records is currently set to 200 for optimal performance.   The The limit can be changed from a parameter in the Hawksearch dashboard.

...