All calls to Microsoft Graph are chained together starting with .api(), then chain query parameters and end with an action.
me/mehttps://graph.microsoft.com/v1.0/mehttps://graph.microsoft.com/beta/meme/events?$filter=startswith(subject, "Adventure")
Getting user details with async/await,
try{letres=awaitclient.api("/me").get();console.log(res);}catch(error){throwerror;}Getting user details with then/catch,
client.api("/me").get().then((res)=>{console.log(res);}).catch((err)=>{console.log(err);});Getting user details by passing callback,
client.api("/me").get((err,res)=>{console.log(res);});