Setting up JWT tokens for self hosted low-level apis

I am struggling to get the JWT authentication working on my ubuntu server.

I am getting the error below in my prosody config and have tried the luarocks suggestions but I am either doing it wrong or it is not working.

Apr 05 22:12:02 modulemanager error Error initializing module ‘auth_token’ on ‘mydomain.cloud’: /usr/lib/prosody/util/startup.lua:145: module ‘basexx’ not found:No LuaRocks module found for basexx
no field package.preload[‘basexx’]
no file ‘/usr/lib/prosody/basexx.lua’
no file ‘/usr/local/share/lua/5.2/basexx.lua’
no file ‘/usr/local/share/lua/5.2/basexx/init.lua’
no file ‘/usr/local/lib/lua/5.2/basexx.lua’
no file ‘/usr/local/lib/lua/5.2/basexx/init.lua’
no file ‘/usr/share/lua/5.2/basexx.lua’
no file ‘/usr/share/lua/5.2/basexx/init.lua’
no file ‘/var/lib/prosody/.luarocks/share/lua/5.2/basexx.lua’
no file ‘/var/lib/prosody/.luarocks/share/lua/5.2/basexx/init.lua’
no file ‘/usr/lib/prosody/basexx.so’
no file ‘/usr/local/lib/lua/5.2/basexx.so’
no file ‘/usr/lib/x86_64-linux-gnu/lua/5.2/basexx.so’
no file ‘/usr/lib/lua/5.2/basexx.so’
no file ‘/usr/local/lib/lua/5.2/loadall.so’
no file ‘/var/lib/prosody/.luarocks/lib/lua/5.2/basexx.so’
stack traceback:
[C]: in function ‘_real_require’
/usr/lib/prosody/util/startup.lua:145: in function ‘require’
/usr/share/jitsi-meet/prosody-plugins/token/util.lib.lua:4: in main chunk
(…tail calls…)
/usr/share/jitsi-meet/prosody-plugins/mod_auth_token.lua:8: in main chunk
[C]: in function ‘xpcall’
/usr/lib/prosody/core/modulemanager.lua:183: in function ‘do_load_module’
/usr/lib/prosody/core/modulemanager.lua:261: in function ‘load’
/usr/lib/prosody/core/usermanager.lua:67: in function ‘?’
/usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75>
(…tail calls…)
/usr/lib/prosody/core/hostmanager.lua:108: in function ‘activate’
/usr/lib/prosody/core/hostmanager.lua:58: in function ‘?’
/usr/lib/prosody/util/events.lua:79: in function </usr/lib/prosody/util/events.lua:75>
(…tail calls…)
/usr/lib/prosody/util/startup.lua:337: in function ‘prepare_to_start’
/usr/lib/prosody/util/startup.lua:558: in function ‘f’
/usr/lib/prosody/util/async.lua:139: in function ‘func’
/usr/lib/prosody/util/async.lua:127: in function </usr/lib/prosody/util/async.lua:125>

basexx module is missing

Thanks, it has been a painful couple days but I now have the low level api working with JWT tokens.