GeoGebra has some [Scripting commands](https://wiki.geogebra.org/en/Scripting) which don't return an object but modify the applet in other ways. It should be possible to give a script which runs when the applet has loaded.