Get a contact collection from the default Contacts folder of the signed-in user (.../me/contacts), or from the specified contact folder.
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)
Contacts.Read, Contacts.ReadWrite
Delegated (personal Microsoft account)
Contacts.Read, Contacts.ReadWrite
Application
Contacts.Read, Contacts.ReadWrite
HTTP request
GET /me/contacts
GET /users/{id | userPrincipalName}/contacts
GET /me/contactFolders/{id}/contacts
GET /users/{id | userPrincipalName}/contactFolders/{id}/contacts
//THE GO SDK IS IN PREVIEW. NON-PRODUCTION USE ONLY
graphClient := msgraphsdk.NewGraphServiceClient(requestAdapter)
result, err := graphClient.Me().ContactFoldersById("contactFolder-id").Contacts().Get(context.Background(), nil)
Import-Module Microsoft.Graph.PersonalContacts
# A UPN can also be used as -UserId.
Get-MgUserContactFolderContact -UserId $userId -ContactFolderId $contactFolderId
<?php
// THIS SNIPPET IS A PREVIEW FOR THE KIOTA BASED SDK. NON-PRODUCTION USE ONLY
$graphServiceClient = new GraphServiceClient($requestAdapter);
$requestResult = $graphServiceClient->me()->contactFoldersById('contactFolder-id')->contacts()->get();