First: This question belongs on the -users list, not the -dev list. The
-dev list is for development of Greasemonkey itself, not for users of GM
(including those users who are writing scripts). I've cc:ed the -users
list, if you reply, please do so there.
Second: You have written an _extension_. A plugin is a different beast
altogether.
> ... but it seems that this is not allowed in greasemonkey. I'd like
> to translate my plugin to greasemonkey, but at this point I have no
> idea what to do.
Stop trying. Greasemonkey does not in any way attempt to solve this
problem. It is for scripting of content pages, and has very little to
do with extensions.
Given absolutely zero knowledge of what your extension does, I can't
offer any further advice. There are indeed some extensions which
concentrate on altering the content of a page, which is indeed what GM
is for, but this is certainly not the general case.
Looks like you probably just want "document.body.textContent", and
"GM_xmlhttpRequest()".