ONLYOFFICE/DocumentBuilder

Is it possible to use docbuilder in a plugin for onlyoffice

default34 opened this issue · 6 comments

For example, I have a Helloworld plugin like that -
https://github.com/ONLYOFFICE/sdkjs-plugins/tree/master/helloworld
Is it possible to import docbuilder into this plugin and if so how to do it?

Could you describe your scenario in more details? What did you need to get in result?

DocumentBuilder is command line tool which use almost same syntax as plugins to generate document files.
Plugins are used to modification currently opened documents via DocumentServer.
So use cases of Plugins and DocBuilder are pretty different

I am writing a plugin for documents and I want to add a function to save the document in pdf format.
I found the builder.SaveFile ('pdf', 'Filename.pdf') method
But I didn't find a similar one for plugins in documentation.

@askonev Could you take a look, I'm not familiar with builder on that level

Hello @datexgo!
You are working with the desktop version of the onlyoffice editors?

Hey @askonev , I'm interested in a workflow fairly similar to @datexgo . I'm using the desktop version of onlyoffice editor, and trying to develop a plugin which can do things like save and export the current file as PDF or a series of bitmap images.

However since the DocBuilder APIs are only exposed via the docbuilder executable I'm hitting a wall trying to "escape" from javascript in my plugin code to call into docbuilder, and it's just not seeming feasible. A way to call the docbuilder APIs directly from plugin code would be ideal for this use case.

@default34 @TheOrbOfConfusion89
There are technical and architectural restrictions to running methods for the builder in plugins. But solving the problem with saving files using plugin methods is feasible. Opened a enhancenment #55419 in our private issue tracker