Legrand / Raritan Xerus™ JSON-RPC API for Remote Access Devices like KX4-101, KX3G2

Loading...
Searching...
No Matches
Smtp.idl
1/* SPDX-License-Identifier: BSD-3-Clause */
2/*
3 * Copyright 2010 Raritan Inc. All rights reserved.
4 */
5
6/**
7 * Device Settings
8 */
9module devsettings {
10
11 /** SMTP settings interface */
12 interface Smtp {
13
14 constant int ERR_INVALID_PARAMS = 1; ///< Invalid parameters
15
16 /** SMTP server configuration */
17 structure Configuration {
18 string host; ///< SMTP server host name or IP address
19 int port; ///< SMTP server port
20 boolean useTls; ///< Enforce TLS usage
21 boolean allowOffTimeRangeCerts; ///< allow expired and not yet valid TLS certificates
22 string caCertChain; ///< TLS CA certificate chain
23 string sender; ///< Sender email address
24 boolean useAuth; ///< SMTP server requires authentication
25 string username; ///< Authentication user name
26 string password; ///< Password; write-only, empty to leave unchanged
27 int retryCount; ///< Number of attempts at sending the email
28 int retryInterval; ///< Sending retry interval in minutes
29 };
30
31 /**
32 * Retrieve the SMTP server configuration.
33 *
34 * @return SMTP server configuration
35 */
36 Configuration getConfiguration();
37
38 /**
39 * Set the SMTP server configuration.
40 *
41 * @param cfg New SMTP server settings
42 *
43 * @return 0 if OK
44 * @return 1 if any parameters are invalid
45 */
46 int setConfiguration(in Configuration cfg);
47
48 /** Result of SMTP configuration test */
49 structure TestResult {
50 int status; ///< Status code; 0 if OK
51 string message; ///< Status message
52 };
53
54 /**
55 * Test an SMTP server configuration. The active server configuration
56 * is not changed.
57 *
58 * @param cfg SMTP server settings to test
59 * @param recipients Recipient email addresses
60 *
61 * @result Result of configuration test
62 */
63 TestResult testConfiguration(in Configuration cfg, in vector<string> recipients);
64
65 };
66
67}
devsettings::Smtp
SMTP settings interface.
Definition Smtp.idl:12
devsettings::Smtp::testConfiguration
TestResult testConfiguration(in Configuration cfg, in vector< string > recipients)
Test an SMTP server configuration.
devsettings::Smtp::getConfiguration
Configuration getConfiguration()
Retrieve the SMTP server configuration.
devsettings::Smtp::ERR_INVALID_PARAMS
constant int ERR_INVALID_PARAMS
Invalid parameters.
Definition Smtp.idl:14
devsettings::Smtp::setConfiguration
int setConfiguration(in Configuration cfg)
Set the SMTP server configuration.
devsettings
Device Settings.
Definition Smtp.idl:9
devsettings::Smtp::Configuration
SMTP server configuration.
Definition Smtp.idl:17
devsettings::Smtp::Configuration::retryCount
int retryCount
Number of attempts at sending the email.
Definition Smtp.idl:27
devsettings::Smtp::Configuration::allowOffTimeRangeCerts
boolean allowOffTimeRangeCerts
allow expired and not yet valid TLS certificates
Definition Smtp.idl:21
devsettings::Smtp::Configuration::port
int port
SMTP server port.
Definition Smtp.idl:19
devsettings::Smtp::Configuration::useTls
boolean useTls
Enforce TLS usage.
Definition Smtp.idl:20
devsettings::Smtp::Configuration::username
string username
Authentication user name.
Definition Smtp.idl:25
devsettings::Smtp::Configuration::useAuth
boolean useAuth
SMTP server requires authentication.
Definition Smtp.idl:24
devsettings::Smtp::Configuration::password
string password
Password; write-only, empty to leave unchanged.
Definition Smtp.idl:26
devsettings::Smtp::Configuration::retryInterval
int retryInterval
Sending retry interval in minutes.
Definition Smtp.idl:28
devsettings::Smtp::Configuration::host
string host
SMTP server host name or IP address.
Definition Smtp.idl:18
devsettings::Smtp::Configuration::sender
string sender
Sender email address.
Definition Smtp.idl:23
devsettings::Smtp::Configuration::caCertChain
string caCertChain
TLS CA certificate chain.
Definition Smtp.idl:22
devsettings::Smtp::TestResult
Result of SMTP configuration test.
Definition Smtp.idl:49
devsettings::Smtp::TestResult::status
int status
Status code; 0 if OK.
Definition Smtp.idl:50
devsettings::Smtp::TestResult::message
string message
Status message.
Definition Smtp.idl:51