sp_site | R Documentation |
Pulls the site or drive (if given) or returns the stored default. Useful if you need to use methods that aren't currently wrapped by tntpr
sp_site(site = NULL)
sp_drive(drive = NULL, site = NULL)
site |
Site identifier. Can be the site name, id, URL, or an ms_site object. If no site identifier is provided, uses the stored default site if it exists. |
drive |
Drive identifier. Can be the drive name, id, or an ms_drive object. If site is provided but drive is not, uses the first drive of the provided site. If neither is provided, uses the stored default drive if it exists. |
A Microsoft365R site object or drive object
Microsoft365R::ms_site, Microsoft365R::ms_drive
# Get current default site or drive
x <- sp_site()
y <- sp_drive()
# Get specified site or drive
x <- sp_site("Data Analytics")
y <- sp_drive("Documents") # Uses stored default site
y <- sp_drive("Documents", site = "Data Analytics") # Use provided site
# Use additional methods in the site/drive objects
x$get_lists()
y$get_item_properties("Analysis Tools.docx")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.