Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

116
Views
Download an attachment using Gmail API - JavaScript

I'm trying to download an attachment using Gmail's API(JavaScript),

  1. So far I was able to get the messages including all of their properties. From a search I did, I understand that I need to access to: message-->payload-->parts[] and then to get some data, such as body.data, MIMEtype and some more. However, I don't understand the concept of the parts, it seems like every massage has a part, which is an array of 2 objects with the same properties, and I don't really know what data I need to retrieve.

  2. Let assume I got the required data from the message object, from my understanding, I should get an encrypted string which then needs to be converted to Base64 string, what's next? How do I download\read the attachment?

Thanks in advance.

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!