The Chrome DevTools Protocol (CDP) is the API that allows external tools and programs to communicate with and control Chrome's internal browser functions. Chrome DevTools itself uses CDP to inspect elements, profile performance, debug JavaScript, and read CSS data. Browser extensions can also request access to CDP for specific tasks.
CDP gives access to CSS layer information that isn't available through standard browser extension APIs. Some stylesheets load cross-origin (from a different domain than the page), and the standard CSS reading method can't fully resolve their layer data. CDP fills that gap.
Loupely Lens uses the CDP debugger permission specifically to read complete CSS cascade data during a capture, including from cross-origin stylesheets and @layer definitions. It uses this access only during an active capture on the element you clicked, only to read CSS rule information, and doesn't execute code on pages or run in the background. The permission Chrome asks for when you install Lens ("access to the debugger") refers to this CDP access.
