summaryrefslogtreecommitdiff
path: root/Admin.md
blob: 0724ab82a91b92cf60df73d37daabd1f5f7a217e (plain) (blame)
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
35
36
37
38
39
40
41
42
# ircbot admin bot

Everything is supposed to be ran inside a remote IEx console: `./bin/lsg remote`.

## Connection management

### List Connections

    IRC.Connection.connections()

### Add Connection

    conn = %{nick: "nick", user: "user", name: "user", network: "netname", host: "irc.netname.org", tls: true, port: 6697}
    IRC.Connection.add_connection(conn)

### Start Connection

    IRC.Connection.start_connection(connection_id)

### Stop Connection

    IRC.Connection.stop_connection(connection_id)

### Delete Connection

    IRC.Connection.delete_connection(connection_id)

## Plugin management

### Enabled plugins

    IRC.Plugin.enabled()

### Enable or Disable a plugin

    IRC.Plugin.disable(plugin_module_or_name)
    IRC.Plugin.enable(plugin_module_or_name)
    IRC.Plugin.switch(plugin_module_or_name)

### Declare a plugin

    IRC.Plugin.declare(module)