List browserSharedCookies
Article
07/12/2023
1 contributor
Feedback
In this article
Namespace: microsoft.graph
Get a list of the browserSharedCookie objects and their properties.
Permissions
One of the following permissions is required to call this API. To learn more, including how to choose permissions, see Permissions .
Permission type
Permissions (from least to most privileged)
Delegated (work or school account)
BrowserSiteLists.Read.All, BrowserSiteLists.ReadWrite.All
Delegated (personal Microsoft account)
Not supported.
Application
BrowserSiteLists.Read.All, BrowserSiteLists.ReadWrite.All
HTTP request
GET /admin/edge/internetExplorerMode/siteLists/{browserSiteListId}/sharedCookies
Optional query parameters
This method supports some of the OData query parameters to help customize the response. For general information, see OData query parameters .
Name
Description
Authorization
Bearer {token}. Required.
Request body
Do not supply a request body for this method.
Response
If successful, this method returns a 200 OK
response code and a collection of browserSharedCookie objects in the response body.
Examples
Request
The following is an example of a request.
GET https://graph.microsoft.com/v1.0/admin/edge/internetExplorerMode/siteLists/e370d818-f650-5ab1-499e-5915e83f4573/sharedCookies
// Code snippets are only available for the latest version. Current version is 5.x
var graphClient = new GraphServiceClient(requestAdapter);
var result = await graphClient.Admin.Edge.InternetExplorerMode.SiteLists["{browserSiteList-id}"].SharedCookies.GetAsync();
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation .
// THE CLI IS IN PREVIEW. NON-PRODUCTION USE ONLY
mgc admin edge internet-explorer-mode site-lists shared-cookies list --browser-site-list-id {browserSiteList-id}
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation .
import (
"context"
msgraphsdk "github.com/microsoftgraph/msgraph-sdk-go"
//other-imports
)
graphClient := msgraphsdk.NewGraphServiceClientWithCredentials(cred, scopes)
sharedCookies, err := graphClient.Admin().Edge().InternetExplorerMode().SiteLists().ByBrowserSiteListId("browserSiteList-id").SharedCookies().Get(context.Background(), nil)
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation .
GraphServiceClient graphClient = GraphServiceClient.builder().authenticationProvider( authProvider ).buildClient();
BrowserSharedCookieCollectionPage sharedCookies = graphClient.admin().edge().internetExplorerMode().siteLists("e370d818-f650-5ab1-499e-5915e83f4573").sharedCookies()
.buildRequest()
.get();
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation .
const options = {
authProvider,
};
const client = Client.init(options);
let sharedCookies = await client.api('/admin/edge/internetExplorerMode/siteLists/e370d818-f650-5ab1-499e-5915e83f4573/sharedCookies')
.get();
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation .
<?php
// THIS SNIPPET IS A PREVIEW VERSION OF THE SDK. NON-PRODUCTION USE ONLY
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$result = $graphServiceClient->admin()->edge()->internetExplorerMode()->siteLists()->byBrowserSiteListId('browserSiteList-id')->sharedCookies()->get()->wait();
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation .
Import-Module Microsoft.Graph.DeviceManagement
Get-MgAdminEdgeInternetExplorerModeSiteListSharedCookie -BrowserSiteListId $browserSiteListId
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation .
# THE PYTHON SDK IS IN PREVIEW. FOR NON-PRODUCTION USE ONLY
graph_client = GraphServiceClient(request_adapter)
result = await graph_client.admin.edge.internet_explorer_mode.site_lists.by_site_list_id('browserSiteList-id').shared_cookies.get()
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation .
Response
The following is an example of the response.
Note: The response object shown here might be shortened for readability.
HTTP/1.1 200 OK
Content-Type: application/json
{
"value": [
{
"status": "published",
"id": "07f4030f-45ff-4ad1-9277-3b8f6ee74141",
"hostOrDomain": "www.microsoft.com",
"sourceEnvironment": "internetExplorer11",
"displayName": "Microsoft Cookie",
"path": "/",
"hostOnly": true,
"comment": "A cookie for microsoft.com",
"lastModifiedDateTime": "2022-06-29T11:32:39.6732721-04:00",
"createdDateTime": "2022-06-29T11:32:39.673272-04:00",
"lastModifiedBy": {
"user": {
"id": "f6ff107e-bc40-4918-a432-8d7b60030a7c",
"displayName": "Joe Smith"
},
"application": null
},
"history": []
}
]
}