Getting started with CPQ DevKit™ for Salesforce (QCP in VS Code)
CPQ DevKit™ for Salesforce is a VS Code extension focused on Salesforce CPQ Quote Calculator Plugin (QCP) development. It replaces the browser edit loop with a local workflow: edit in src/, sync to SBQQ__CustomScript__c, and diff changes like normal code.
Prerequisites
- VS Code + the extension installed (
CPQConsultant.cpq-devkit-sf) - A Salesforce org with Salesforce CPQ installed
- QCP enabled in CPQ package settings (so your custom script records are used)
Key folders and files
src/*.ts— your local QCP scripts (saved as.tsfor editor help, but you must write valid JavaScript, not TypeScript).cpqdevkit/sfcpq/qcp-config.json— encrypted org auth + file/record mappings (keep out of Git).cpqdevkit/sfcpq/qcp-log.json— optional sync logs
1) Initialize the project and authenticate
- Open an empty folder in VS Code (or an existing repo).
- Run
CPQ DevKit™ for Salesforce: Initialize Project. - Pick your org type (Sandbox / Dev / Prod / Custom) and complete the OAuth login flow.
Once authenticated, the extension stores credentials encrypted under .cpqdevkit/sfcpq/ and updates .gitignore so you don’t commit them.
2) Create or pull QCP scripts
After initialization, bring scripts into your workspace:
CPQ DevKit™ for Salesforce: Pull QCP records from Salesforce(pulls all scripts)CPQ DevKit™ for Salesforce: Create example QCP files in your project(adds samples intosrc/)
3) Quick sanity check
Run CPQ DevKit™ for Salesforce: Validate org credentials are valid to confirm you can connect and query the org.
Important note about “TypeScript”
Files are stored as .ts, but they are not compiled before being pushed back to Salesforce. Avoid TypeScript-only syntax (types, enums, interfaces, as, decorators, etc.)—keep it ES6-compatible JavaScript.
