Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generated models and request builders #2130

Merged
merged 2 commits into from
Sep 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ and this project does adheres to [Semantic Versioning](https://semver.org/spec/v

## [Unreleased]

## [5.27.0] - 2023-09-13

- Improves message of `OdataError`(https://github.com/microsoftgraph/msgraph-sdk-dotnet/issues/2094,https://github.com/microsoftgraph/msgraph-sdk-dotnet/issues/1954)
- Latest metadata updates from 12th September 2023.

## [5.26.0] - 2023-09-06

Expand Down
4 changes: 2 additions & 2 deletions src/Microsoft.Graph/Generated/Admin/AdminRequestBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public AdminRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<Microsoft.Graph.Models.Admin>(requestInfo, Microsoft.Graph.Models.Admin.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<Microsoft.Graph.Models.Admin>(requestInfo, Microsoft.Graph.Models.Admin.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Update admin
Expand All @@ -81,7 +81,7 @@ public AdminRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<Microsoft.Graph.Models.Admin>(requestInfo, Microsoft.Graph.Models.Admin.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<Microsoft.Graph.Models.Admin>(requestInfo, Microsoft.Graph.Models.Admin.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Get admin
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public async Task DeleteAsync(Action<EdgeRequestBuilderDeleteRequestConfiguratio
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken);
await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// A container for Microsoft Edge resources. Read-only.
Expand All @@ -69,7 +69,7 @@ public async Task DeleteAsync(Action<EdgeRequestBuilderDeleteRequestConfiguratio
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<Microsoft.Graph.Models.Edge>(requestInfo, Microsoft.Graph.Models.Edge.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<Microsoft.Graph.Models.Edge>(requestInfo, Microsoft.Graph.Models.Edge.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Update the navigation property edge in admin
Expand All @@ -90,7 +90,7 @@ public async Task DeleteAsync(Action<EdgeRequestBuilderDeleteRequestConfiguratio
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<Microsoft.Graph.Models.Edge>(requestInfo, Microsoft.Graph.Models.Edge.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<Microsoft.Graph.Models.Edge>(requestInfo, Microsoft.Graph.Models.Edge.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Delete navigation property edge for admin
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public async Task DeleteAsync(Action<InternetExplorerModeRequestBuilderDeleteReq
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken);
await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// A container for Internet Explorer mode resources.
Expand All @@ -69,7 +69,7 @@ public async Task DeleteAsync(Action<InternetExplorerModeRequestBuilderDeleteReq
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<Microsoft.Graph.Models.InternetExplorerMode>(requestInfo, Microsoft.Graph.Models.InternetExplorerMode.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<Microsoft.Graph.Models.InternetExplorerMode>(requestInfo, Microsoft.Graph.Models.InternetExplorerMode.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Update the navigation property internetExplorerMode in admin
Expand All @@ -90,7 +90,7 @@ public async Task DeleteAsync(Action<InternetExplorerModeRequestBuilderDeleteReq
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<Microsoft.Graph.Models.InternetExplorerMode>(requestInfo, Microsoft.Graph.Models.InternetExplorerMode.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<Microsoft.Graph.Models.InternetExplorerMode>(requestInfo, Microsoft.Graph.Models.InternetExplorerMode.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Delete navigation property internetExplorerMode for admin
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public CountRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendPrimitiveAsync<int?>(requestInfo, errorMapping, cancellationToken);
return await RequestAdapter.SendPrimitiveAsync<int?>(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Get the number of the resource
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ public async Task DeleteAsync(Action<BrowserSiteListItemRequestBuilderDeleteRequ
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken);
await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Get a browserSiteList that contains browserSite and browserSharedCookie resources.
Expand All @@ -81,7 +81,7 @@ public async Task<BrowserSiteList> GetAsync(Action<BrowserSiteListItemRequestBui
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<BrowserSiteList>(requestInfo, BrowserSiteList.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<BrowserSiteList>(requestInfo, BrowserSiteList.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Update the properties of a browserSiteList object.
Expand All @@ -103,7 +103,7 @@ public async Task<BrowserSiteList> PatchAsync(BrowserSiteList body, Action<Brows
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<BrowserSiteList>(requestInfo, BrowserSiteList.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<BrowserSiteList>(requestInfo, BrowserSiteList.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Delete a browserSiteList object.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public async Task<BrowserSiteList> PostAsync(PublishPostRequestBody body, Action
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<BrowserSiteList>(requestInfo, BrowserSiteList.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<BrowserSiteList>(requestInfo, BrowserSiteList.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Publish the specified browserSiteList for devices to download.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public CountRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendPrimitiveAsync<int?>(requestInfo, errorMapping, cancellationToken);
return await RequestAdapter.SendPrimitiveAsync<int?>(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Get the number of the resource
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public async Task DeleteAsync(Action<BrowserSharedCookieItemRequestBuilderDelete
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken);
await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Get a session cookie that can be shared between a Microsoft Edge process and an Internet Explorer process, while using Internet Explorer mode.
Expand All @@ -66,7 +66,7 @@ public async Task<BrowserSharedCookie> GetAsync(Action<BrowserSharedCookieItemRe
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<BrowserSharedCookie>(requestInfo, BrowserSharedCookie.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<BrowserSharedCookie>(requestInfo, BrowserSharedCookie.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Update the properties of a browserSharedCookie object.
Expand All @@ -88,7 +88,7 @@ public async Task<BrowserSharedCookie> PatchAsync(BrowserSharedCookie body, Acti
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<BrowserSharedCookie>(requestInfo, BrowserSharedCookie.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<BrowserSharedCookie>(requestInfo, BrowserSharedCookie.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Delete a browserSharedCookie from a browserSiteList.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public async Task<BrowserSharedCookieCollectionResponse> GetAsync(Action<SharedC
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<BrowserSharedCookieCollectionResponse>(requestInfo, BrowserSharedCookieCollectionResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<BrowserSharedCookieCollectionResponse>(requestInfo, BrowserSharedCookieCollectionResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Create a new browserSharedCookie object in a browserSiteList.
Expand All @@ -81,7 +81,7 @@ public async Task<BrowserSharedCookie> PostAsync(BrowserSharedCookie body, Actio
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<BrowserSharedCookie>(requestInfo, BrowserSharedCookie.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<BrowserSharedCookie>(requestInfo, BrowserSharedCookie.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Get a list of the browserSharedCookie objects and their properties.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public CountRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendPrimitiveAsync<int?>(requestInfo, errorMapping, cancellationToken);
return await RequestAdapter.SendPrimitiveAsync<int?>(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Get the number of the resource
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public async Task DeleteAsync(Action<BrowserSiteItemRequestBuilderDeleteRequestC
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken);
await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Get a browserSite that resides on a browserSiteList.
Expand All @@ -66,7 +66,7 @@ public async Task<BrowserSite> GetAsync(Action<BrowserSiteItemRequestBuilderGetR
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<BrowserSite>(requestInfo, BrowserSite.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<BrowserSite>(requestInfo, BrowserSite.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Update the properties of a browserSite object.
Expand All @@ -88,7 +88,7 @@ public async Task<BrowserSite> PatchAsync(BrowserSite body, Action<BrowserSiteIt
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<BrowserSite>(requestInfo, BrowserSite.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<BrowserSite>(requestInfo, BrowserSite.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Delete a browserSite from a browserSiteList.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public async Task<BrowserSiteCollectionResponse> GetAsync(Action<SitesRequestBui
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<BrowserSiteCollectionResponse>(requestInfo, BrowserSiteCollectionResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<BrowserSiteCollectionResponse>(requestInfo, BrowserSiteCollectionResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Create a new browserSite object in a browserSiteList.
Expand All @@ -81,7 +81,7 @@ public async Task<BrowserSite> PostAsync(BrowserSite body, Action<SitesRequestBu
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<BrowserSite>(requestInfo, BrowserSite.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<BrowserSite>(requestInfo, BrowserSite.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Get a list of the browserSite objects and their properties.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public async Task<BrowserSiteListCollectionResponse> GetAsync(Action<SiteListsRe
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<BrowserSiteListCollectionResponse>(requestInfo, BrowserSiteListCollectionResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<BrowserSiteListCollectionResponse>(requestInfo, BrowserSiteListCollectionResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Create a new browserSiteList object to support Internet Explorer mode.
Expand All @@ -81,7 +81,7 @@ public async Task<BrowserSiteList> PostAsync(BrowserSiteList body, Action<SiteLi
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendAsync<BrowserSiteList>(requestInfo, BrowserSiteList.CreateFromDiscriminatorValue, errorMapping, cancellationToken);
return await RequestAdapter.SendAsync<BrowserSiteList>(requestInfo, BrowserSiteList.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Get a list of the browserSiteList objects and their properties.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public CountRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base
{"4XX", ODataError.CreateFromDiscriminatorValue},
{"5XX", ODataError.CreateFromDiscriminatorValue},
};
return await RequestAdapter.SendPrimitiveAsync<int?>(requestInfo, errorMapping, cancellationToken);
return await RequestAdapter.SendPrimitiveAsync<int?>(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Get the number of the resource
Expand Down
Loading