Initialize the ai package
-
Complete the SDK quick start.
In the quick start, you initialize the Marketplace SDK
clientpackage, which is required for every Marketplace app.
The Marketplace SDK ai package is optional by default, but you must initialize it if your app needs to interact with AI skills APIs. AI skills APIs provide LLM-powered capabilities grounded in SitecoreAI data.
To initialize the ai package:
-
If you haven't installed the package yet, install it by running the following command in your terminal:
-
In the
useMarketplaceClient.tshook, importAIfrom the package: -
In the same file, in the
getMarketplaceClientfunction, in theconfigvariable, addAIto the list of modules, then save your changes:
You can now start making queries and mutations that require access to AI skills APIs, for example, make a Brand Review API request. For a full list of operations, refer to the reference documentation.