The Tigase server supports scripting languages from the version 4.3.1. These pages describe this feature in details how to create new scripts, upload them to the server and execute them. The guide also contains API description with code examples.
There is one thing I have to highlight before you start digging into the scripting stuff. The Tigase server is known for it very low memory consumption. It successfully runs with less then 10MB of RAM memory. However, if you added scripting support for any non-standard (default) language to the Tigase server it significantly increases memory requirements for the installation. You cannot expect the Tigase server to run on 10MB RAM system if you enabled Python, Scala or any other non-standard language.