Skip to content

Latest commit

 

History

History
21 lines (15 loc) · 655 Bytes

drive.getLastModified.md

File metadata and controls

21 lines (15 loc) · 655 Bytes

drive.getLastModified(id)

Gets the last modified time of the the file. Unlike many functions in Gootenberg, this one returns a Date object.

  • id <String>: The Id for a Google Drive file (see here)

Example

import Gootenberg from 'gootenberg';
import credentials from './credentials.json'

async function myFunc(){
  const goot = new Gootenberg();
  await goot.auth.jwt(credentials);

  const lastModifiedDatetime = await goot.drive.getLastModified('MY_FILE_ID');
  console.log(lastModifiedDatetime);
}

myFunc();