- I have configured the YML file of Ejabberd 23.04.
- I am able to see the Ejabberd dashboard in Firefox when I enter the username and password (screenshot attached below).
- Using the IP address and Port number of Ubuntu, I can see the Ejabberd dashboard in my Windows Chrome browser (same screenshot as above).
Then I have created a sample helloworld program using Erlang language in Intellij with rebar3 as a build tool. Now my main intention is to connect this project to Ejabberd. So I need to know what libraries and packages are required for connecting XMPP Ejabberd Connection in the Erlang project. How to get those packages? How to write a code that connects to the Ejabberd server?
I tried to connect my Erlang project to Ejabberd, but I am not able to get the proper output:
-module(hello).
-author("Mubin Nandavar").
-include_lib("package/exmpp/include/exmpp.hrl").
%% API
-export([ start/0]).
-import(ejabberd_client, []).
start() ->
io:fwrite("hello").
What should I add to this code in order to get connected to the Ejabberd server?