I migrated our OTRS CE 6.0.17 over to Znuny 6.1.2 a few days ago.
In our OTRS environment I have a php script which is triggered by the CMD option of a generic agent job each time, a TicketCreate event occurs. The php script is then sending a SOAP-request (containing the TicketNumber) to a SOAP webservice which will result in a NextCloud-share being created. I know that this is probably not the most elegant way to accomplish this, but this is working flawlessly for years.
As I was going over the Znuny 6.x release notes I learnt, that as of v6.3.x it will not be possible to run scripts this way anymore, the CMD - will then disappear. This was when I realized that I better learn how to implement a custom module.
Today is day 3 that I am trying to find any examples, documentation, recommendations on how to write a custom module, yet to no avail. I find it quite difficult as many websites that google comes up seem to be helpful at first but then link to some outdated or dead links in old and meanwhile unavailable OTRS forums. The developer documentation of Znuny doesn't contain what I am looking for either.
I have to admit that I am not a Perl professional but I think that if I had an example I could implement everything I need. The "how do I do the SOAP-request to my NextCloud" is not the issue - I figured that out already
![Wink ;)](./images/smilies/icon_wink.gif)
I would greatly appreciate if someone could point me into the right direction where and how to start. Any links to resources that could help me would be fine. My questions are in particular:
- What is the process when implementing a module? Does it have to be registered in any way?
- How would you debug your module? Currently my first attempts seem to sporadically not being properly processed but can't find out why.
- Is there any example module exist for the purpose of being used in the Generic Agent?
Thank you!