A bundle ID, such as com.apple.Safari, is the unique name macOS uses for an app. Settings for clipboard managers, MDM profiles and defaults commands often ask for it.
With osascript
osascript -e 'id of app "Safari"'
Replace Safari with the app’s name as it appears in Applications.
With mdls
mdls -name kMDItemCFBundleIdentifier -r /Applications/Safari.app
From the app itself
Right-click the app in Finder, choose Show Package Contents, open Contents, then Info.plist. The value next to CFBundleIdentifier is the bundle ID.
What you might use it for
In NotchMind, which I make, you exclude apps from clipboard history by bundle ID, for example a password manager that isn’t on the built-in list. See exclude apps from the clipboard.
NotchMind