It's not a guitar speaker. You could but your performance will not be optimal. The power input is 20 watts. The JBL K120 or E 120 would be optimal.
The JBL D123 is a 12’’ extended range speaker design for flush wall mounting between studs. See articles below:
Mike
https://www.lansingheritage.org/html/jbl/specs/home-comp/d123.htm
https://www.lansingheritage.org/html/jbl/specs/pro-comp/k-series.htm