Skip to content

EVENT_DATAGRAM module

This is a module which provides a UNIX/UDP SOCKET transport layer implementation for the Event Interface.

The raised events will follow the following grammar:

  • event = event_name (argument ‘\n’)*
  • event_name = non-quoted_string’\n’
  • argument = ((arg_name ’::’)? arg_value)? | (arg_value)
  • arg_name = not-quoted_string
  • arg_value = not-quoted_string | ’”’ string ’”’
  • not-quoted_string = string - {’,”,\n,\r}

The event name can contain any non-quoted string character, but it is recommended to follow the syntax: E_MODULE_NAME_EXTRA_NAME

There are two types of sockets used by this module, based on the sockets type. An UNIX socket should follow this syntax: [‘unix:’] unix_socket_path

An UDP socket should follow this syntax: ‘udp:’ address ’:’ port

The following modules must be loaded before this module:

  • No dependencies on other OpenSIPS modules.

The following libraries or applications must be installed before running OpenSIPS with this module loaded:

  • none

No parameter exported by this module.

No function exported to be used from configuration file.

This is an example of an event raised by the pike module when it decides an ip should be blocked:

E_PIKE_BLOCKED event
E_PIKE_BLOCKED
ip::192.168.2.11
UNIX socket
unix:/tmp/opensips_event.sock
UDP socket
udp:127.0.0.1:8081

Q: Both UNIX and UDP type of socket can be used to notify the events?

Yes, you can use the both types.

Q: What is the maximum lenght of a datagram event?

The maximum length of a datagram event is 65457 bytes.

Q: Where can I find more about OpenSIPS?

Take a look at http://www.opensips.org/.

Q: Where can I post a question about this module?

First at all check if your question was already answered on one of our mailing lists:

E-mails regarding any stable OpenSIPS release should be sent to users@lists.opensips.org and e-mails regarding development versions should be sent to devel@lists.opensips.org.

If you want to keep the mail private, send it to users@lists.opensips.org.

Q: How can I report a bug?

Please follow the guidelines provided at: https://github.com/OpenSIPS/opensips/issues.

doc copyrights:

Top contributors by DevScore(1), authored commits(2) and lines added/removed(3)

#NameDevScoreCommitsLines++Lines—
1.Razvan Crainea (@razvancrainea)231485439
2.Liviu Chircu (@liviuchircu)531330
3.Stefan Darius (@dariusstefan)5216614
4.Bogdan-Andrei Iancu (@bogdan-iancu)4221

(1) DevScore = author_commits + author_lines_added / (project_lines_added / project_commits) + author_lines_deleted / (project_lines_deleted / project_commits)

(2) including any documentation-related commits, excluding merge commits

(3) ignoring whitespace edits, renamed files and auto-generated files

#NameCommit Activity
1.Stefan Darius (@dariusstefan)Jun 2026 - Jul 2026
2.Razvan Crainea (@razvancrainea)May 2011 - Jun 2026
3.Bogdan-Andrei Iancu (@bogdan-iancu)Oct 2014 - Jun 2018
4.Liviu Chircu (@liviuchircu)Mar 2014 - Jun 2018

(1) including any documentation-related commits, excluding merge commits

Last edited by: Razvan Crainea (@razvancrainea), Bogdan-Andrei Iancu (@bogdan-iancu), Liviu Chircu (@liviuchircu).

All documentation files (i.e. .md extension) are licensed under the Creative Common License 4.0