Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

support for fromname #629

Closed
AlbertHambardzumyan opened this issue Nov 23, 2017 · 7 comments · Fixed by #768
Closed

support for fromname #629

AlbertHambardzumyan opened this issue Nov 23, 2017 · 7 comments · Fixed by #768
Labels
difficulty: easy fix is easy in difficulty status: work in progress Twilio or the community is in the process of implementing type: docs update documentation change not affecting the code

Comments

@AlbertHambardzumyan
Copy link

const sendGridMail = require('@sendgrid/mail')
sendGridMail.setApiKey(process.env.SEND_GRID_API_KEY)

sendGridMail.send({
        to: email,
        from: FROM,
        templateId: process.env.TEMPLATE_ID,
        substitutionWrappers: ['-', '-'],
        substitutions: {
          'username': email
        }
      }, callback)

The above example works fine. However, I need to set from name.
Is there a way to set fromname ?

@luisvinicius167
Copy link

+1

@thinkingserious thinkingserious added status: help wanted requesting help from the community type: question question directed at the library labels Nov 28, 2017
@thinkingserious
Copy link
Contributor

Hello @AlbertHambardzumyan, @luisvinicius167,

Here are the various ways to set the name field.

I hope that helps.

Thanks!

With Best Regards,

Elmer

@AlbertHambardzumyan
Copy link
Author

Works nice.

I do believe its a bit not obvious in doc. Have scrolled the entire doc 3 times and haven't noticed (perhaps because of example to).

Thanks for the tip.

Best Regards,

Albert

@thinkingserious
Copy link
Contributor

Thanks for the additional feedback @AlbertHambardzumyan.

I'm going to leave this issue open until we update the docs to make this feature obvious.

@thinkingserious thinkingserious added difficulty: easy fix is easy in difficulty up-for-grabs type: docs update documentation change not affecting the code and removed type: question question directed at the library labels Mar 5, 2018
@OrthoDex
Copy link
Contributor

hey @thinkingserious , can I issue a PR to update the docs for this?

I am thinking adding commented code in the doc link should make the feature clear.

@thinkingserious thinkingserious added status: work in progress Twilio or the community is in the process of implementing hacktoberfest and removed help wanted status: help wanted requesting help from the community labels Oct 2, 2018
@thinkingserious
Copy link
Contributor

thinkingserious commented Oct 2, 2018

It's all yours @OrthoDex :)

Thank you!

@OrthoDex
Copy link
Contributor

OrthoDex commented Oct 7, 2018

Ah, I see @valerianpereira already put in a PR for this. Maybe we could add some guidelines to reduce duplicate work in PRs?

thinkingserious added a commit that referenced this issue Oct 10, 2018
#629 Documentation updated for `from` field
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
difficulty: easy fix is easy in difficulty status: work in progress Twilio or the community is in the process of implementing type: docs update documentation change not affecting the code
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants