SOLVED

Programatically display user's relevant/recently visited SharePoint sites

%3CLINGO-SUB%20id%3D%22lingo-sub-315046%22%20slang%3D%22en-US%22%3EProgramatically%20display%20user's%20relevant%2Frecently%20visited%20SharePoint%20sites%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-315046%22%20slang%3D%22en-US%22%3E%3CP%3EHi%20All%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20am%20looking%20for%20a%20solution%20to%20list%20recently%20visited%20(relevant)%20SharePoint%20sites%20(modern%20team%20sites)%20for%20a%20user%20programatically.%20Similar%20to%20how%20SharePoint%20home%20page%20display%20cards%20for%20sites.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAny%20suggestion%20please.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ERegards%2C%3C%2FP%3E%3CP%3EVishwa%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-319956%22%20slang%3D%22en-US%22%3ERe%3A%20Programatically%20display%20user's%20relevant%2Frecently%20visited%20SharePoint%20sites%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-319956%22%20slang%3D%22en-US%22%3E%3CP%3EThank%20you%20Matti%2C%20very%20good%20suggestion%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-319254%22%20slang%3D%22en-US%22%3ERe%3A%20Programatically%20display%20user's%20relevant%2Frecently%20visited%20SharePoint%20sites%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-319254%22%20slang%3D%22en-US%22%3E%3CP%3EIf%20you%20are%20using%20SharePoint%20Online%2C%20check%20out%20SharePoint%20Starter%20Kit.%20There%20is%20already%20a%20web%20part%20for%20that.%3C%2FP%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2FSharePoint%2Fsp-starter-kit%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehttps%3A%2F%2Fgithub.com%2FSharePoint%2Fsp-starter-kit%3C%2FA%3E%3C%2FP%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2FSharePoint%2Fsp-starter-kit%2Fblob%2Fmaster%2Fdocumentation%2Fcomponents%2Fwp-recently-visited-sites.md%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehttps%3A%2F%2Fgithub.com%2FSharePoint%2Fsp-starter-kit%2Fblob%2Fmaster%2Fdocumentation%2Fcomponents%2Fwp-recently-visited-sites.md%3C%2FA%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-708531%22%20slang%3D%22en-US%22%3ERe%3A%20Programatically%20display%20user's%20relevant%2Frecently%20visited%20SharePoint%20sites%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-708531%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F66255%22%20target%3D%22_blank%22%3E%40Vishwanatha%20Nayak%3C%2FA%3E%26nbsp%3BI%20know%20you%20have%20an%20answer%20by%20now.%20Incase%20if%20anyone%20else%20is%20looking%20for%20similar%20requirements%20as%20we%20do%2C%20the%20solution%20is%20using%20insight%20api%20in%20Microsoft%20graph.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3Ethis%20api%20can%20give%20more%20options%20for%20showing%20user%20history%20(recent%20documents%2C%20sites%20or%20any%20objects%20which%20they%20are%20working%20on).%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%3Eme%2Finsights%2Fused%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%3Ethanks%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%3E-Praveen%2C%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E
Contributor

Hi All,

 

I am looking for a solution to list recently visited (relevant) SharePoint sites (modern team sites) for a user programatically. Similar to how SharePoint home page display cards for sites.

 

Any suggestion please.

 

Regards,

Vishwa

3 Replies
best response confirmed by Vishwanatha Nayak (Contributor)

Thank you Matti, very good suggestion

@Vishwanatha Nayak I know you have an answer by now. Incase if anyone else is looking for similar requirements as we do, the solution is using insight api in Microsoft graph. 

 

this api can give more options for showing user history (recent documents, sites or any objects which they are working on). 

 

me/insights/used

 

thanks

-Praveen,