Skip to main content
Users
CloudPortalLogin
  • Powered byPowered by
Developing with Sitecore CDP
Data privacy
Before you start sending data
Integrating with Sitecore CDP
Stream API
Batch API
REST APIs
Data lake export service
  • Sitecore CDP for developers
  • Stream API
  • Sitecore Engage SDK reference
  • Troubleshooting

Troubleshooting

This topic describes the most common errors and solutions when integrating using the Engage SDK.

Errors in the console or terminal

401 Unauthorized

This error occurs when the value for the clientKey attribute is incorrect. To fix the error, set the value to the correct client key.

404 Not Found

This error occurs in the following cases:

  • The browser ID was not stored as a cookie in the web browser. This happens when, for example, the value for the cookieDomain is incorrect, a user of your app rejects cookies, or the web browser is blocking cookies. To send events, use the correct cookie domain and make sure that the browser ID is stored as a cookie in the web browser.

  • The value for the targetURL attribute is the wrong URL from the available URLs for the Stream API. To fix the error, set the value to the correct Stream API target endpoint.

Cookie has been rejected for invalid domain

This error occurs when the value for the cookieDomain is incorrect. To fix the error, set the value to the correct cookie domain.

Cross-origin request blocked

This error occurs when the value for the targetURL attribute is different than the available URLs for the Stream API. To fix the error, set the value to the correct Stream API target endpoint.

IE errors

IE errors are related to initializing the Engage SDK. You must resolve these errors for the Engage SDK to function properly.

Code

Description

Note

IE-0001

The window object is not available on the server side. Use the window object only on the client side, and in the correct execution context.

This error can occur when you call Engage functions on the server.

Make sure to call Engage functions where the window object is present.

IE-0002

Cannot retrieve the cookie from the server.

See a code sample for setting cookies from the server.

IE-0003

Timeout exceeded. The server did not respond within the allotted time.

This error occurs when you call a function with the timeout parameter, then the function makes a network request to the server, but the server doesn't respond in time.

When you use timeout, use try-catch blocks to handle errors.

IE-0004

Unable to set the cookie because the browser ID could not be retrieved from the server. Try again later, or use try-catch blocks to handle this error.

This error can occur when there are network issues or the Sitecore CDP server is down when the Engage.initServer.handleCookie(req, res) function is running.

When you use the initServer.handleCookie() function, you should use try-catch blocks to handle errors.

IV errors

IV errors are related to incorrect values and wrongly formatted objects in the event data.

Code

Description

Note

IV-0001

Incorrect value for targetURL. Set the value to a valid URL string.

Set the value to the correct Stream API target endpoint.

IV-0002

Incorrect value for dob.

Format the value according to ISO 8601.

See examples of correctly formatted data.

IV-0003

Incorrect value for email. Set the value to a valid email address.

IV-0004

Incorrect value for expiryDate.

Format the value according to ISO 8601.

IV-0005

This event supports maximum {{max}} attributes. Reduce the number of attributes.

IV-0006

Incorrect value for the timeout parameter. Set the value to an integer greater than or equal to 0.

N/A

MV errors

MV errors are related to missing values in the event data.

Code

Description

Note

MV-0001

clientKey is required.

Set the value to your client key.

MV-0002

targetURL is required.

Set the value to the correct Stream API target endpoint.

MV-0003

pointOfSale is required.

Set the value to the name of your point of sale.

MV-0004

identifiers is required.

See examples of correctly formatted data.

MV-0009

pointOfSale cannot be empty.

Set the value to the name of your point of sale.

Events not appearing in Sitecore CDP

This issue occurs if you sent an event to Sitecore CDP and your web browser console contains no errors, but the value for the pointOfSale attribute is incorrect.

To fix the error:

  1. In your script, locate your pointOfSale attributes. Usually, they are either in your settings object or your event data objects, or both.

  2. For every pointOfSale attribute, specify the correct name of a point of sale.

Events related to orders are failing in Sitecore CDP

This issue occurs if an ADD, CONFIRM, or CHECKOUT event is set up incorrectly.

To fix the error:

  • Make sure that the event data objects for the ADD, CONFIRM, and CHECKOUT events are correctly formatted.

  • Make sure to send the events in the correct sequence.

  • For each item ID included in an object in the product array of the CONFIRM event data object, there must be a preceding ADD event data object where the product item ID is specified in product.item_id.

    See examples.

Do you have some feedback for us?

If you have suggestions for improving this article,

Privacy policySitecore Trust CenterCopyright © 1999-2026 Sitecore