How can an Object's Background Color be set in JavaScript?

Diamaudix Audio Ltd.'s icon

am able to successfully instantiate a new graphical object in a patcher with the following line of code

this.patcher.newobject("toggle", x, y, size, 0);

How would one access and manipulate various attributes (most notably background color) without resorting to tools outside of javascript?

Help greatly appreciated