Using email to update SQL database - mysql

Is it possible to use email to update mysql table?
for example I have someone send email which have today article with the image as an attachment and it have to send to particular email address (eg: abc#something.org) to be able to process data to sql table, other address will not work for updating.
Once it receive, it automatically proceed and update sql from the article it receive.
How is it work?
is there any open source that may help this process

Not by sql, you have to involve some sort of programming language which have a subset of methods to communicate with the database and that can receive and send email.

Take a look at Sendgrid (at http://sendgrid.com): they have a parse API (see http://wiki.sendgrid.com/doku.php?id=parse_api for details) that basically lets you convert an email into an HTTP POST. So if you already have a web page that can update the MySQL database you can just modify it to comply with their spec, set up a sub domain that forwards to Sendgrid and then setup a Sendgrid endpoint that takes any email to that sub domain and posts it to your web page.

It depends on your application. If you're using a framework like Wordpress, there are plenty of plugins available to integrate (e.g. Postie). If you have your own custom application, you may find an open source script to download the new messages, but you'll have to implement your own code to update your database.

Related

E-mail templates with Json

Working on a project for my employer. They are searching for a solution to connect JSON to a email template.
For now, I look for a solution where the system who has the JSON, loads the JSON script on a server. Then, we connect that server with a marketing automation system, for example Marketo. We like to create an email template which loads the JSON.
The developer we found, says it is not possible and it will not work in gmail, outlook or any other client. For what I know, it is possible to create a email template with JSON right? Just to be sure, because when it is possible, our problem is not the system, but the developer.
Like to hear your thoughts on this subject. Suggestions are welcome.
So, this can be done, but you're going to need to do some custom development.
Marketo's API includes a request campaign endpoint for triggering Smart Campaigns, including those which send emails. As part of the request campaign payload, you can send {{my.token}} values for the campaign.
If you can set up some middleware between your JSON output that renders the HTML for your email, you can push that rendered HTML as a token in the campaign request, allowing for on-demand email creation based on your JSON content.
There are two caveats with this approach:
You will have to dynamically send the email using Request Campaign. That means if you need to send unique content to multiple folks, you'll be using one API call per email.
Due to the nature of Request Campaign triggers, you will not be able to batch and send using Marketo's controls; however, this should be straightforward to set up on the API side.
You can build an email using dynamic data, e.g. from an API that sends JSON.
However, you cannot send an email that calls dynamic data. The final email that gets sent must be static. That may be what your developer is getting at. Email software will strip out scripts.

Can I / Should I integrate DocuSign with MS Access

I need to implement electronic signatures from an Access database without using a signature pad. I do not have an actual document that needs to be signed - just a field on an Access form. We currently use a Topaz signature pad but are needing to get away from that.
Thanks in advance,
Karen
Yes, you can. There are several .net api to access DocuSign.
You can use them to create the DocuSign envelope. You will also need to implement something to retrieve the signed envelopes. There are two options:
a cron job that calls DocuSign to get all the updated envelopes since the last call
a REST service that DocuSign will call to inform your application of every event that happens on your envelopes.
If you want to use the second option, your REST service should be open to Internet (you can find the subnet to open in the DocuSign documentation).
DocuSign is used to sign documents, not data. Since your database is holding a form's worth of data, I suggest that you:
Create a template in DocuSign that represents the Access form
When you make the Envelopes: Create call to DocuSign, populate the template's data fields with the data from the Access db.
The result will be a signing request that looks like the form in your database.
Once the document is signed in DocuSign, you can record the envelope ID in Access. It can then be used to view the signed document. Or you can download the signed documents and store them locally.
Ask further questions here if you have any difficulties.

How to get notified by mail when rows are inserted into table?

I made an online store coded in JSP and tables stored in MysQl. I'm using servlet and classes. I would like to get notify by mail at admin#domain.com when an order is inserted in the database.
Likewise, the customer should receive the order confirmation to the email they entered when they submit the form.
I would like to get feedback on how to do such a task. What's the best practice? I hope to not get back fire with this question because I`m aware there are several answers possible.
Basically, I`m just looking for the easiest and fastest implementation without too much hassle!
The form contains very sensitive and confidential data like address and such. But, since our customers can track their orders on the site, the data should not be sent, for security purposes. Just a message to confirm the reception of their order.
Please guide me in the right direction.
If you are using Hibernate i would recommend you using an entity listener, specially with a #PostPersist callback. You can read about it in Chapter 6. Entity listeners and Callback methods.
The email part can be done using the JavaMail API.
You can check an example of sending an email in Sending an Email using the JavaMail API.
Hope it helps!

Securely registering a new Wordpress user with a custom Zapier action (via JSON API?)

I want to use Zapier to register a new Wordpress user — the trigger will be a new purchase on Gumroad.
This plugin — https://wordpress.org/plugins/json-api-user/ — allows you to register users using a public JSON interface, eg by hitting
https://example.com/api/user/register/?username={{email}}&email={{email}}&nonce=blahblahblah
I'm new to all this, but know that I can get Zapier to insert the purchaser's email from Gumroad into {{email}}.
My question is, how can I do this in a secure way?
(At the moment anyone can hit example.com.com/api/get_nonce/?controller=user&method=register and get the key they need)
And maybe it can even be done without using Zapier?
I'm assuming that the nonce is only good for a short period of time, like a couple minutes? If so, what you want to do is lock down the /api/get_nonce/ endpoint to require a password. That way only authenticated users can get a nonce, which can then be used to create the user.
As for how Zapier fits in, it's a bit complicated to custom build a two-request process like this. You would have to make your own app on the Developer Platform do the nonce call and then the user creation.
I use the following plugin to create users (via Zapier) on my WordPress sites after someone signed up on my Teachable school: WP Webhooks Pro
This plugin allows me to either POST the data to my WordPress site via JSON, XML or a simple form data. In my case, I don't need a nonce, since the plugin generates API keys that I can use to push my data to.

send database info to email

I was wondering if sanyone could help me with the following:
I have some info inserted into mysql database on a couple of pages. After this is done I retrieve these info (in a new page) from the database and want to send them via email to various emails including one from the info from database.
I have built the email() function and "SELECT" all the info from the database (have them into some HIDDEN fields).
I am not sure how to go about getting these info sent via email.
I have tried, but all I get is an empty email with no info from database.
Hope I explained my problem and someone can give me clue about this.
Many thanks
Francesco
MySQL does not include a feature for sending email. So you'll need to write additional software to handle the job for you.
One issue to decide, how will the email be requested? -- How will the process be initiated?
You could have your web page (written in PHP or any other language), which shows the information on the screen also send the email. See sending email from php.
A better performing idea is to first queue up your requests for sending emails. That way you won't slow down your web server. Then have a background job process each of the requests, reading the database and sending off the emails. Google for "php background processing" for help or ask more questions on StackOverflow.
Also, remember to check that your email is not being treated as spam.
Re: using the data from the database for sending the email--that's easy, just read the database, then use the information for creating the email's to, cc, subject and other fields.