コード例 #1
0
 /// <summary>
 /// This method removes a member from a group
 /// </summary>
 /// <param name="user">The user to remove from the group</param>
 /// <param name="groupId">The ID of the target group</param>
 public static void RemoveMemberFromGroup(User user, String groupId)
 {
     MicrosoftGraphHelper.MakeDeleteRequest(
         String.Format("{0}groups/{1}/members/{2}/$ref",
                       MicrosoftGraphHelper.MicrosoftGraphV1BaseUri,
                       groupId, user.Id));
 }
コード例 #2
0
 /// <summary>
 /// This method deletes a contact
 /// </summary>
 /// <param name="contactId">The ID of the contact to delete</param>
 public static void DeleteContact(String contactId)
 {
     MicrosoftGraphHelper.MakeDeleteRequest(
         String.Format("{0}me/contacts/{1}",
                       MicrosoftGraphHelper.MicrosoftGraphV1BaseUri,
                       contactId));
 }
コード例 #3
0
 /// <summary>
 /// This method deletes an event from a calendar
 /// </summary>
 /// <param name="calendarId">The ID of the calendar</param>
 /// <param name="eventId">The ID of the event to delete</param>
 public static void DeleteEvent(String calendarId, String eventId)
 {
     MicrosoftGraphHelper.MakeDeleteRequest(
         String.Format("{0}me/calendars/{1}/events/{2}",
                       MicrosoftGraphHelper.MicrosoftGraphV1BaseUri,
                       calendarId, eventId));
 }
コード例 #4
0
 /// <summary>
 /// This method removes a permission from a target DriveItem
 /// </summary>
 /// <param name="driveItemId">The ID of the DriveItem</param>
 /// <param name="permissionId">The ID of the permission</param>
 public static void RemoveDriveItemPermission(String driveItemId, String permissionId)
 {
     MicrosoftGraphHelper.MakeDeleteRequest(
         String.Format("{0}me/drive/items/{1}/permissions/{2}",
                       MicrosoftGraphHelper.MicrosoftGraphV1BaseUri,
                       driveItemId,
                       permissionId));
 }
コード例 #5
0
 /// <summary>
 /// This method deletes a file in OneDrive for Business
 /// </summary>
 /// <param name="driveId">The ID of the target drive</param>
 /// <param name="fileId">The ID of the target file</param>
 public static void DeleteFile(String driveId, String fileId)
 {
     MicrosoftGraphHelper.MakeDeleteRequest(
         String.Format("{0}drives/{1}/items/{2}",
                       MicrosoftGraphHelper.MicrosoftGraphV1BaseUri,
                       driveId,
                       fileId));
 }
コード例 #6
0
 /// <summary>
 /// Deletes an Office 365 Group
 /// </summary>
 /// <param name="groupId">The ID of the group to delete</param>
 public static void DeleteUnifiedGroup(String groupId)
 {
     MicrosoftGraphHelper.MakeDeleteRequest(
         String.Format("{0}groups/{1}",
                       MicrosoftGraphHelper.MicrosoftGraphV1BaseUri, groupId));
 }