if (FALSE) {
# Create a client
client <- api_client$new(
host_url = "https://graph.microsoft.com"
)
# Create a resource with v1.0 API endpoint
resource_v1 <- api_resource$new(
client = client,
endpoint = "v1.0"
)
# Create a resource with beta API endpoint
resource_beta <- api_resource$new(
client = client,
endpoint = "beta"
)
# Make requests - the endpoint is automatically prepended
response <- resource_v1$.fetch(
path = "/me",
req_method = "get"
)
}
Run the code above in your browser using DataLab