Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

gmail-api-parse-message-ts

Package Overview
Dependencies
Maintainers
1
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gmail-api-parse-message-ts - npm Package Compare versions

Comparing version 2.2.6 to 2.2.7

2

package.json
{
"name": "gmail-api-parse-message-ts",
"version": "2.2.6",
"version": "2.2.7",
"description": "Parses Gmail API's GET method to iGmail object. Typescript",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

[![npm][npm]][npm-url]
# gmail-api-parse-message typescript
## forked from https://github.com/EmilTholin/gmail-api-parse-message v2.1
Parses Gmail API's GET message method, and returns a IGmail object
## Parses Gmail API's GET message method, and returns a IGmail object
forked from https://github.com/EmilTholin/gmail-api-parse-message v2.1

@@ -26,3 +26,3 @@ ## To install:

export class ParseEmailService {
/** fetch single email from Gmail, and also updates emails array (see paramenter 'emails' below from component) */
/** fetch single email from Gmail API */
async getGmail(id: string): Promise<gapi.client.gmail.Message> {

@@ -40,12 +40,12 @@ const email: gapi.client.gmail.Message = await gapi.client.gmail.users.messages.get({

const parse = new ParseGmailApi();
const gmailResponse = await getEmail('nm7ntsgm7tu1b6od')
const gmailResponse = await getEmail('[id of your gmail message]');
const iGmail = parse.parseMessage(gmailResponse);
console.log(iGmail) // which return an object of type iGmail with the following properties
console.log(iGmail); // see iGmail below
}
}
```
which return the following objects
running parseEmail() which returns an iGmail object
```ts
interface iGmail {

@@ -52,0 +52,0 @@ id: string;

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc