neoSmtp2Go
Use SMTP2GO services to send emails and SMS directly from your app. More info:
https://smtp2go.com
IMPORTANT: In order to use this plugin, you need to configure your sender domain as explained in Smtp2Go site and create an API key.
Description
The neoSmtp2Go plugin for VisualNEO Web allows applications to send emails and SMS messages using the SMTP2GO service, offering reliable communication features directly within the app. This plugin supports text and HTML emails with optional attachments and callback functions for success or error handling, making it ideal for notifications, confirmations, and automated messaging. Here’s an overview of its main functionalities:
Setting Up SMTP2GO API Key: Before sending emails or SMS, use neoSmtp2GoSetApiKey to configure the SMTP2GO API key, essential for authenticating the plugin with SMTP2GO services.
- Command: neoSmtp2GoSetApiKey
- Syntax: neoSmtp2GoSetApiKey "theKey"
- theKey: The API key provided by SMTP2GO.
Example:
neoSmtp2GoSetApiKey "your_api_key"
This sets the necessary API key to enable email and SMS functionalities.
Sending Text Emails
The neoSmtp2GoSendText command sends a plain text email, with fields for recipients, sender, subject, and body text, along with optional callbacks.
- Command: neoSmtp2GoSendText
- Syntax: neoSmtp2GoSendText "theTo" "theSender" "theReplyTo" "theSubject" "textBody" successCallback errorCallback
- theTo: Recipient email address.
- theSender: Sender’s email address.
- theReplyTo: Optional reply-to email.
- theSubject: Subject of the email.
- textBody: Body text of the email.
- successCallback and errorCallback: Optional subroutines for handling success or error responses.
Example:
neoSmtp2GoSendText "user@example.com" "info@yourapp.com" "support@yourapp.com" "Welcome!" "Thank you for signing up!" "onSuccess" "onError"
This sends a welcome email to the user, with callbacks for handling the response.
Sending HTML Emails and Attachments
For HTML-formatted emails, use neoSmtp2GoSendHtml, and if an attachment is needed, neoSmtp2GoSendHtmlWithAttachment supports adding files in Base64 format.
- Commands:
- neoSmtp2GoSendHtml: Sends an HTML email.
- Syntax: neoSmtp2GoSendHtml "theTo" "theSender" "theReplyTo" "theSubject" htmlBody successCallback errorCallback
- neoSmtp2GoSendHtmlWithAttachment: Sends an HTML email with an attachment.
- Syntax: neoSmtp2GoSendHtmlWithAttachment "theTo" "theSender" "theReplyTo" "theSubject" htmlBody "theFileName" theMimeType "theBase64Data" successCallback errorCallback
Example with Attachment:
neoSmtp2GoSendHtmlWithAttachment "user@example.com" "info@yourapp.com" "support@yourapp.com" "Your Document" "<p>See attached document</p>" "document.pdf" "application/pdf" "[base64encodedfiledata]" "onSuccess" "onError"
This sends an HTML email with an attached PDF document.
Sending SMS Messages
The neoSmtp2GoSendSMS command enables SMS messaging to specified phone numbers, with fields for text content and optional callbacks.
- Command: neoSmtp2GoSendSMS
- Syntax: neoSmtp2GoSendSMS "destNumber" "theText" successCallback errorCallback
- destNumber: Recipient phone number (e.g., +1234567890).
- theText: Message content for the SMS.
- successCallback and errorCallback: Optional subroutines for result handling.
Example:
neoSmtp2GoSendSMS "+1234567890" "Your appointment is confirmed." "onSMSSuccess" "onSMSError"
This sends a confirmation SMS to the specified phone number, with success and error handling.
Practical Applications
The neoSmtp2Go plugin is ideal for:
- User Notifications: Sending signup confirmations, password resets, or appointment reminders.
- Promotional Messages: Email campaigns or SMS updates for new products or events.
- Automated Support: Sending support responses or information to users without manual intervention.
By leveraging SMTP2GO’s email and SMS services, neoSmtp2Go equips VisualNEO Web applications with essential messaging features that enhance user engagement and communication.
neoSmtp2GoSetApiKey
|
Purpose: |
Set Smtp2Go Api Key |
|
Category: |
neoSmtp2Go |
|
Syntax: |
neoSmtp2GoSetApiKey "theKey"
theKey Smtp2Go Api Key |
neoSmtp2GoSendHtml
|
Purpose: |
Send an email using SMTP2GO services. |
|
Category: |
neoSmtp2Go |
|
Syntax: |
neoSmtp2GoSendHtml "theTo" "theSender" "theReplyTo" "theSubject" htmlBody successCallback errorCallback
theTo To (ie: 'John Wayne ') theSender From (ie: 'Peter Parker ') theReplyTo Reply to (optional) (ie: 'Info ') theSubject Subject htmlBody Email body (HTML) successCallback Success callback subroutine (optional) errorCallback Error callback subroutine (optional) |
neoSmtp2GoSendHtmlWithAttachment
|
Purpose: |
Send an HTML email with a fike attachment using SMTP2GO services. |
|
Category: |
neoSmtp2Go |
|
Syntax: |
neoSmtp2GoSendHtmlWithAttachment "theTo" "theSender" "theReplyTo" "theSubject" htmlBody "theFileName" theMimeType "theBase64Data" successCallback errorCallback
theTo To (ie: 'John Wayne ') theSender From (ie: 'Peter Parker ') theReplyTo Reply to (optional) (ie: 'Info ') theSubject Subject htmlBody Email body (HTML) theFileName File attachment file name theMimeType Mime type theBase64Data File content in Base64 format successCallback Success callback subroutine (optional) errorCallback Error callback subroutine (optional) |
neoSmtp2GoSendText
|
Purpose: |
Send an email using SMTP2GO services. |
|
Category: |
neoSmtp2Go |
|
Syntax: |
neoSmtp2GoSendText "theTo" "theSender" "theReplyTo" "theSubject" "textBody" successCallback errorCallback
theTo To (ie: 'John Wayne ') theSender From (ie: 'Peter Parker ') theReplyTo Reply to (optional) (ie: 'Info ') theSubject Subject textBody Email body (text) successCallback Success callback subroutine (optional) errorCallback Error callback subroutine (optional) |
neoSmtp2GoSendSMS
|
Purpose: |
Send an SMS using SMTP2GO services. |
|
Category: |
neoSmtp2Go |
|
Syntax: |
neoSmtp2GoSendSMS "destNumber" "theText" successCallback errorCallback
destNumber Destination number (ie: +34666666666) theText Text to send successCallback Success callback subroutine (optional) errorCallback Error callback subroutine (optional) |
Created with the Personal Edition of HelpNDoc: Easy Qt Help documentation editor