The Code Assistant in Sitecore CDP is your AI-powered code companion that turns natural language ideas into production-ready JavaScript. Whether you’re exporting audiences, creating complex conditions, or managing session traits, the Code Assistant generates the exact JavaScript you need. This lets you spend less time on code syntax and focus more on impactful marketing.
Deliver stronger marketing outcomes, faster
Instant code generation - ask the Code Assistant what you need using natural language, and it will deliver precise, context-aware JavaScript.
Seamlessly contextual - the Code Assistant understands your editor’s current code combined with your underlying data schema and adapts the output accordingly. Your new JavaScript will be created using CDP’s supported entities and functions.
Built specifically for CDP - the Code Assistant can generate code in the following areas of CDP:
Audience export computations - compute the exact audience data you need for your next marketing campaign.
Conditional audience filtering - write robust, rule-based filters to target the right audience at the right time.
Session traits management - store session-based values to better understand your customer.
Privacy and security are top priority - we never use your prompts or code context to train our LLM. Your proprietary logic, brand details, and customer insights remain private.
Get started
Open your JavaScript editor in CDP to launch the Code Assistant.
Enter your natural language prompt or choose an example from our documentation.
Instantly receive clean, ready-to-run JavaScript.
We’re excited for you to use the Code Assistant to unlock new marketing possibilities!