About

This plugin sends mail

Commands

mail

check


usage: #bp.mail.check [-h]

check to make sure all settings are applied

optional arguments:
  -h, --help  show help (default: False)

password


usage: #bp.mail.password [-h] [password]

set the password for the mail account

positional arguments:
  password    the top level api to show (optional)

optional arguments:
  -h, --help  show help (default: False)

test


usage: #bp.mail.test [-h] [subject] [message]

send a test email

positional arguments:
  subject     the subject of the test email (optional) (default: Test subject
              from bastproxy)
  message     the message of the test email (optional) (default: Msg from
              bastproxy)

optional arguments:
  -h, --help  show help (default: False)

Base

api


usage: #bp.mail.api [-h] [api]

list functions in the api

positional arguments:
  api         api to get details of

optional arguments:
  -h, --help  show help (default: False)

help


usage: #bp.mail.help [-a] [-c] [-h]

show help info for this plugin

optional arguments:
  -a, --api       show functions this plugin has in the api (default: False)
  -c, --commands  show commands in this plugin (default: False)
  -h, --help      show help (default: False)

inspect


usage: #bp.mail.inspect [-m METHOD] [-o OBJECT] [-s] [-h]

inspect a plugin

optional arguments:
  -m METHOD, --method METHOD
                        get code for a method
  -o OBJECT, --object OBJECT
                        show an object of the plugin, can be method or
                        variable
  -s, --simple          show a simple output (default: False)
  -h, --help            show help (default: False)

reset


usage: #bp.mail.reset [-h]

reset the plugin

optional arguments:
  -h, --help  show help (default: False)

save


usage: #bp.mail.save [-h]

save the plugin state

optional arguments:
  -h, --help  show help (default: False)

set


usage: #bp.mail.set [-h] [name] [value]

change a setting in the plugin

if there are no arguments or 'list' is the first argument then
it will list the settings for the plugin

positional arguments:
  name        the setting name (default: list)
  value       the new value of the setting

optional arguments:
  -h, --help  show help (default: False)

stats


usage: #bp.mail.stats [-h]

show plugin stats

optional arguments:
  -h, --help  show help (default: False)

Settings

username


the username to connect as

from


the address to send mail from

ssl


set this to True if the connection will use ssl

server


the smtp server to send mail through

to


the address to send mail to

port


the port to use when sending mail

API

send


mail.send(subject, msg, mailto=None)
  send an email
    subject  = the subject of the message
    msg      = the msg to send
    mailto   = the email address to send to (default: the to
      setting of the mail plugin)

    this function returns no values

original defined in plugins/utils/mail.py