SendGrid: Difference between revisions
Mbbellevue (talk | contribs) |
Mbbellevue (talk | contribs) |
||
Line 102: | Line 102: | ||
</syntaxhighlight> |
</syntaxhighlight> |
||
=== WEB API === |
=== WEB API === |
||
SendGrids web API is extensive, which allows developers to send email, as well as get statistics, bounces, spam reports, unsubscribes, and other information. The web API is not RESTful, and only uses GET and POST HTTP verbs. The web API allows both XML and JSON requests and provides responses, both error and success, in the same format you post in. |
|||
'''XML Error''' |
|||
<syntaxhighlight lang="xml"> |
|||
<result> |
|||
<message>error</message> |
|||
<errors> |
|||
... |
|||
<error>... error messages ...</error> |
|||
... |
|||
</errors> |
|||
</result> |
|||
</syntaxhighlight> |
|||
'''JSON Error''' |
|||
<syntaxhighlight lang="javascript"> |
|||
{"message":"error","errors":[..."error messages"...]} |
|||
</syntaxhighlight> |
|||
'''XML Success''' |
|||
<syntaxhighlight lang="xml"> |
|||
<result> |
|||
success |
|||
</result> |
|||
</syntaxhighlight> |
|||
'''JSON Success''' |
|||
<syntaxhighlight lang="javascript"> |
|||
{"message":"success"} |
|||
</syntaxhighlight> |
|||
When calling the web API, you can send several parameters to customize the message being sent to the users, such as to, toname, subject, text and/or html, from, bcc, replyto, date, files, as well as others. |
|||
'''Send to Single Recipient''' |
|||
sendgrid.com/enwiki/api/mail.send.json?api_user=youremail@domain.com&api_key=secureSecret&to=destination@example.com&toname=Destination&subject=Example%20Subject&text=testingtextbody&from=info@domain.com |
|||
'''Send to multiple recipients''' |
|||
sendgrid.com/enwiki/api/mail.send.json?api_user=youremail@domain.com&api_key=secureSecret&to[]=destination@example.com&toname[]=Destination&to[]=destination2@example.com&toname[]=Destination2&subject=Example%20Subject&text=testingtextbody&from=info@domain.com |
|||
The web API also includes custom parameters to be sent through x-smtpapi parameter. The format is the same as the SMTP API custom parameters using JSON formatted key/value pair combinations. |
|||
== Competitors == |
== Competitors == |
Revision as of 02:52, 11 November 2012
This sandbox is in the article namespace. Either move this page into your userspace, or remove the {{User sandbox}} template.
Type of business | Private |
---|---|
Founded | 2009 |
Headquarters | , |
Key people | Isaac Saldana (Co-founder, President), Tim Jenkins (Co-founder, CTO), Jose Lopez (Co-founder, Web Architect) |
Industry | Information Technology |
URL | Sendgrid.com |
SendGrid is a cloud-based infrastructure for processing large quantities of email, both sending and receiving. SendGrid takes on the responsibility of security, scalability, deliverability, and analytics to keep the cost and complexity to a minimum for customers. SendGrid's infrastructure is accessible through an SMTP API, Web API, or Event API. The SMTP API uses the SMTP protocol, while the Web API and Event API use the HTTP protocol.
As of June 2012, SendGrid has sent over 45 Billion emails for 60,000 businesses. They deliver more than 4 billion emails each month to companies like Airbnb, Twilio, Foursquare, Pandora, and Pinterest[1].
History
SendGrid was founded in July of 2009 and based in Boulder, Colorado after they graduated from the TecStars program. The founders were Isaac Saldana, Tim Jenkins, and Jose Lopez. They are backed by the Foundry Group, Highway 12 Ventures, Bessemer Venture Partners, and others. Since their inception, they have continued to grow in the amount of emails sent, employees, and finally customers.
Date | Messages Sent | # Employees | # Customers |
---|---|---|---|
Q4 2009 | 268M | 4 | 1000 |
Q4 2010 | 2.1B | 19 | 12000 |
Q4 2011 | 6.9B | 70 | 37000 |
Funding
SendGrid has gone through several iterations of funding, starting at their inception in 2009 when they received seed funding. They have completed searies A, A-1, and B funding, since their inception through January of 2012. They have raised a total of $22,762,000 since inception.
Date | Amount USD | Funding Type |
---|---|---|
08/2009 | 12k | Seed Funding |
12/08/2009 | 750k | Series A Funding |
04/20/2010 | 5M | Series A-1 Funding |
01/17/2012 | 17M | Series B Funding |
Technology
SendGrid is built using Ruby, PHP, Python, Gearman, ZeroMQ, Rails, Symfony, Twisted, Bootstrap, JQuery, GIT, as well a other technologies. It primarily runs on a Linux environment using service oriented architecture. SendGrid provides two ways to send emails, SMTP API or Web API, to allow flexibility to their customers.
SMTP API
The SMTP API is the recommended use by SendGrid, as it allows for more options and can process emails more efficiently. The SMTP API allows developers to customize the handling instructions for the email being sent. They use headers based on a JSON list of instructions and options. Example: To assign a category of "newuser", a header would be included on the SMTP request:
"X-SMTPAPI: {"category" : "newuser"}
In addition to assigning categories to emails, you can customize the emails using additional customized JASON header items. Others include:
- TO: Array of address to send messages to
{"to": ["Ben Golden <ben@sendgrid.com>", "Joe Scharf <joe@sendgrid.com>"]}
- Substition: An associative array of substitution tags, where each tag is associated with a list of replacement text for the tag in the body text. Each Substitution value corresponds to an email in the “To” section of the JSON string.
{"sub":{"%name%": ["Ben", "Joe"], "%role%": ["%sellerSection%", "%buyerSection%"]}}
- Section: Sections can be used to simplify substitution values that are common to many recipients. This is an associative array of sections that can be used in substitution values.
{"section":{"%sellerSection%": "Seller information for: %name%", "%buyerSection%": "Buyer information for: %name%"}}
- Unique Arguments: An associative array of arguments and their values to be applied to all emails sent in this SMTP API transaction.
{"unique_args": {"orderNumber": "12345", "eventID": "6789"}}
- Apps: An associative array of filters and their settings, used to override filter settings already setup for your account. Settings are an associative array of the setting names and their values.
{"filters": {"footer": {"settings": {"enable":1,"text/plain": "Thank you for your business"}}}}
All of the above examples can then be combined into one larger JSON string placed in a header named X-SMTPAPI.
X-SMTPAPI: {
"to": [
"ben@sendgrid.com",
"joe@sendgrid.com"
],
"sub": {
"%name%": [
"Ben",
"Joe"
],
"%role%": [
"%sellerSection%",
"%buyerSection%"
]
},
"section": {
"%sellerSection%": "Seller information for: %name%",
"%buyerSection%": "Buyer information for: %name%"
},
"category": "Orders",
"unique_args": {
"orderNumber": "12345",
"eventID": "6789"
},
"filters": {
"footer": {
"settings": {
"enable": 1,
"text/plain": "Thank you for your business"
}
}
}
}
WEB API
SendGrids web API is extensive, which allows developers to send email, as well as get statistics, bounces, spam reports, unsubscribes, and other information. The web API is not RESTful, and only uses GET and POST HTTP verbs. The web API allows both XML and JSON requests and provides responses, both error and success, in the same format you post in.
XML Error
<result>
<message>error</message>
<errors>
...
<error>... error messages ...</error>
...
</errors>
</result>
JSON Error
{"message":"error","errors":[..."error messages"...]}
XML Success
<result>
success
</result>
JSON Success
{"message":"success"}
When calling the web API, you can send several parameters to customize the message being sent to the users, such as to, toname, subject, text and/or html, from, bcc, replyto, date, files, as well as others.
Send to Single Recipient
sendgrid.com/enwiki/api/mail.send.json?api_user=youremail@domain.com&api_key=secureSecret&to=destination@example.com&toname=Destination&subject=Example%20Subject&text=testingtextbody&from=info@domain.com
Send to multiple recipients
sendgrid.com/enwiki/api/mail.send.json?api_user=youremail@domain.com&api_key=secureSecret&to[]=destination@example.com&toname[]=Destination&to[]=destination2@example.com&toname[]=Destination2&subject=Example%20Subject&text=testingtextbody&from=info@domain.com
The web API also includes custom parameters to be sent through x-smtpapi parameter. The format is the same as the SMTP API custom parameters using JSON formatted key/value pair combinations.