| Tip of the day: The antirandom module can be a useful tool to block clients with random looking nicks. |
JSON-RPC:Message
Jump to navigation
Jump to search
JSON Methods
- rpc:
set_issuer,info,add_timer,del_timer - stats:
get - log:
send,list,subscribe,unsubscribe - user:
list,get,set_nick,set_username,set_realname,set_vhost,set_mode,set_snomask,set_oper - whowas:
get - server:
list,get,rehash,connect,disconnect - channel:
list,get,set_mode,set_topic,kick - server_ban:
list,get,add,del - server_ban_exception:
list,get,add,del - spamfilter:
list,get,add,del - name_ban:
list,get,add,del - message:
send_privmsg,send_notice,send_numeric,send_standard_reply
JSON Basics
The message.* JSON RPC calls allow you to send a messages to users.
API Calls
message.send_privmsg
This sends a PRIVMSG to a user.
Request arguments
Mandatory:
- nick: User to send the message to (Nick or UID)
- message: The message to send
Response
Returns true if the message was sent, or an error otherwise.
message.send_notice
This sends a NOTICE to a user.
Request arguments
Mandatory:
- nick: User to send the notice to (Nick or UID)
- message: The message to send
Response
Returns true if the message was sent, or an error otherwise.
message.send_numeric
This sends an IRC numeric to a user.
Request arguments
Mandatory:
- nick: User to send the message to (Nick or UID)
- numeric: Numeric to send (1-999)
- message: The message to send: all the text after the
:server XXX nick
Response
Returns true if the message was sent, or an error otherwise.
message.send_standard_reply
This sends an IRC standard reply to a user
Request arguments
Mandatory:
- nick: User to send the message to (Nick or UID)
- type: Type:
FAIL,WARNorNOTE - code: Machine-readable reply code representing the meaning of the message to client software
- context: Context (optional)
- description: Description of the reply which is shown to users.
Response
Returns true if the message was sent, or an error otherwise.