Before you get started
This topic describes what you need before you get started with the Cloud SDK and how to prepare your development environment.
Prerequisites
Check that you have the following, before getting started:
Some code examples, images, and UI labels may still use XM Cloud while engineering assets are being updated.
-
Sitecore subscriptions, depending on your application requirements.
-
Node.js 18.17 or later. Check your installed version by using the
node --versioncommand. -
A Content SDK application based on the starter kit, or a JSS application based on one of the XM Cloud Front End Application Starter Kits. For JSS, the version of your JSS app determines which version of the Cloud SDK to use.
ImportantAlthough this documentation also describes using the Cloud SDK in a standalone Next.js application, you need a Content SDK or JSS app connected to SitecoreAI to use the SDK.
Compatibility with JSS
The version of your JSS app determines which version of the Cloud SDK packages to install.
To make sure you install the correct version of Cloud SDK packages, check the version of the listed Cloud SDK dependencies in the package.json file of your JSS app. For example, the JSS 22.2.0 package.json file lists the Cloud SDK core package version 0.4.0 as a dependency:
In this case, make sure that all other Cloud SDK packages you install are also version 0.4.0. If you install a previous or later version of a Cloud SDK package, some functionality might not work.
Prepare your development environment
Enable debug logs
During development, we recommend that you enable debug logs for the Cloud SDK. This helps you trace code execution and diagnose errors, speeding up your work with the SDK.