Toggle system preferences on touch bar

This may already be possible and I am not aware of it. There are several system preferences that I toggle frequently, such as Automatic Graphics Switching and Do Not Disturb. Toggling these at all would be awesome, but an even cooler feature would be a touch bar icon that visibly displays the status of the preference, and switches it on/off when tapped. Just a thought.

This could be helpful:

There are some System Preference panes that you can access with keyboard shortcuts.
Hold down option and click the F key the shows the system pane you want, for example, F3 for Mission Control. (Depending on how you have System Preferences set for F keys, you may need to use option fn F3, for example.)

Tabbing works in the System Preferences main window, but I don't see a way to then open the pane. You could simulate a double click in Keyboard Maestro.