File: README.txt

package info (click to toggle)
ejabberd-contrib 0.2020.10.21~dfsg0-5
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 3,280 kB
  • sloc: erlang: 11,364; sql: 92; makefile: 90; sh: 41
file content (34 lines) | stat: -rw-r--r-- 755 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# mod_post_log - Logs messages to an HTTP API

*Homepage*: https://github.com/processone/ejabberd-contrib/tree/master/mod_post_log
*Author*: Tim Stewart, Mojo Lingo LLC
*Requirements*: ejabberd 14.07 or later

This module implements logging of all messages sent (chat and groupchat) via an HTTP API.


## CONFIGURATION

Add the module to your ejabberd.yml, in the modules section:

```yaml
modules:
  ...
  mod_post_log:
    url: http://foo.bar.com/messages
  ...
```

## API example

```
POST /messages HTTP/1.0
HTTP-X-MESSAGE-FROM: doo@dah.com
HTTP_X_MESSAGE_TO: foo@bar.com
Content-Type: application/xml
Content-Length: 122

<message to='foo@bar.com' from='doo@dah.com' type='chat'>
  <body xmlns='jabber:client'>Hello there Foo!</body>
</message>
```