Skip to content

nylas-samples/ruby-email-read

Repository files navigation

ruby-email-read

This sample will show you to easily read your email with the Nylas Ruby SDK.

You can follow along step-by-step in our blog post "How to Read Email Inbox Data with the Nylas Ruby SDK".

Setup

System dependencies

  • Ruby v3.x

Gather environment variables

You'll need the following values:

ACCESS_TOKEN =
CLIENT_ID =
CLIENT_SECRET =

Add the above values to a new .env file:

$ touch .env # Then add your env variables

Install dependencies

$ gem install nylas
$ gem install dotenv

Usage

Run the script using the ruby command:

$ ruby ReadEmail.rb

When your message is successfully sent, you'll get the following output in your terminal:

[4/7/YYYY] Here's an email subject
[4/6/YYYY] Another subject

Learn more

Visit our Nylas Ruby SDK documentation to learn more.

Releases

No releases published

Packages

No packages published

Languages