Skip to content

Commit 719f928

Browse files
Microsoft Graph DevX ToolingMicrosoft Graph DevX Tooling
authored andcommitted
feat(generation): update request builders and models
Update generated files with build 209142
1 parent 9644cd7 commit 719f928

File tree

61 files changed

+4961
-178
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

61 files changed

+4961
-178
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
// <auto-generated/>
2+
#pragma warning disable CS0618
3+
using Microsoft.Graph.Models.TeamsAdministration;
4+
using Microsoft.Graph.Models;
5+
using Microsoft.Kiota.Abstractions.Extensions;
6+
using Microsoft.Kiota.Abstractions.Serialization;
7+
using System.Collections.Generic;
8+
using System.IO;
9+
using System;
10+
namespace Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName
11+
{
12+
[global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")]
13+
#pragma warning disable CS1591
14+
public partial class GetPolicyIdWithTypeWithNameGetResponse : global::Microsoft.Graph.Models.BaseCollectionPaginationCountResponse, IParsable
15+
#pragma warning restore CS1591
16+
{
17+
/// <summary>The value property</summary>
18+
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
19+
#nullable enable
20+
public List<global::Microsoft.Graph.Models.TeamsAdministration.PolicyIdentifierDetail>? Value
21+
{
22+
get { return BackingStore?.Get<List<global::Microsoft.Graph.Models.TeamsAdministration.PolicyIdentifierDetail>?>("value"); }
23+
set { BackingStore?.Set("value", value); }
24+
}
25+
#nullable restore
26+
#else
27+
public List<global::Microsoft.Graph.Models.TeamsAdministration.PolicyIdentifierDetail> Value
28+
{
29+
get { return BackingStore?.Get<List<global::Microsoft.Graph.Models.TeamsAdministration.PolicyIdentifierDetail>>("value"); }
30+
set { BackingStore?.Set("value", value); }
31+
}
32+
#endif
33+
/// <summary>
34+
/// Creates a new instance of the appropriate class based on discriminator value
35+
/// </summary>
36+
/// <returns>A <see cref="global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameGetResponse"/></returns>
37+
/// <param name="parseNode">The parse node to use to read the discriminator value and create the object</param>
38+
public static new global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameGetResponse CreateFromDiscriminatorValue(IParseNode parseNode)
39+
{
40+
if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode));
41+
return new global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameGetResponse();
42+
}
43+
/// <summary>
44+
/// The deserialization information for the current model
45+
/// </summary>
46+
/// <returns>A IDictionary&lt;string, Action&lt;IParseNode&gt;&gt;</returns>
47+
public override IDictionary<string, Action<IParseNode>> GetFieldDeserializers()
48+
{
49+
return new Dictionary<string, Action<IParseNode>>(base.GetFieldDeserializers())
50+
{
51+
{ "value", n => { Value = n.GetCollectionOfObjectValues<global::Microsoft.Graph.Models.TeamsAdministration.PolicyIdentifierDetail>(global::Microsoft.Graph.Models.TeamsAdministration.PolicyIdentifierDetail.CreateFromDiscriminatorValue)?.AsList(); } },
52+
};
53+
}
54+
/// <summary>
55+
/// Serializes information the current object
56+
/// </summary>
57+
/// <param name="writer">Serialization writer to use to serialize this model</param>
58+
public override void Serialize(ISerializationWriter writer)
59+
{
60+
if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer));
61+
base.Serialize(writer);
62+
writer.WriteCollectionOfObjectValues<global::Microsoft.Graph.Models.TeamsAdministration.PolicyIdentifierDetail>("value", Value);
63+
}
64+
}
65+
}
66+
#pragma warning restore CS0618
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
// <auto-generated/>
2+
#pragma warning disable CS0618
3+
using Microsoft.Kiota.Abstractions.Extensions;
4+
using Microsoft.Kiota.Abstractions.Serialization;
5+
using System.Collections.Generic;
6+
using System.IO;
7+
using System;
8+
namespace Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName
9+
{
10+
[Obsolete("This class is obsolete. Use GetPolicyIdWithTypeWithNameGetResponse instead.")]
11+
[global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")]
12+
#pragma warning disable CS1591
13+
public partial class GetPolicyIdWithTypeWithNameResponse : global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameGetResponse, IParsable
14+
#pragma warning restore CS1591
15+
{
16+
/// <summary>
17+
/// Creates a new instance of the appropriate class based on discriminator value
18+
/// </summary>
19+
/// <returns>A <see cref="global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameResponse"/></returns>
20+
/// <param name="parseNode">The parse node to use to read the discriminator value and create the object</param>
21+
public static new global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameResponse CreateFromDiscriminatorValue(IParseNode parseNode)
22+
{
23+
if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode));
24+
return new global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameResponse();
25+
}
26+
}
27+
}
28+
#pragma warning restore CS0618
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,193 @@
1+
// <auto-generated/>
2+
#pragma warning disable CS0618
3+
using Microsoft.Graph.Models.ODataErrors;
4+
using Microsoft.Kiota.Abstractions.Extensions;
5+
using Microsoft.Kiota.Abstractions.Serialization;
6+
using Microsoft.Kiota.Abstractions;
7+
using System.Collections.Generic;
8+
using System.IO;
9+
using System.Threading.Tasks;
10+
using System.Threading;
11+
using System;
12+
namespace Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName
13+
{
14+
/// <summary>
15+
/// Provides operations to call the getPolicyId method.
16+
/// </summary>
17+
[global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")]
18+
public partial class MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder : BaseRequestBuilder
19+
{
20+
/// <summary>
21+
/// Instantiates a new <see cref="global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder"/> and sets the default values.
22+
/// </summary>
23+
/// <param name="name">Usage: name=&apos;{name}&apos;</param>
24+
/// <param name="pathParameters">Path parameters for the request</param>
25+
/// <param name="requestAdapter">The request adapter to use to execute the requests.</param>
26+
/// <param name="type">Usage: type=&apos;{type}&apos;</param>
27+
public MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder(Dictionary<string, object> pathParameters, IRequestAdapter requestAdapter, string name = "", string type = "") : base(requestAdapter, "{+baseurl}/admin/teams/policy/microsoft.graph.teamsAdministration.getPolicyId(type='{type}',name='{name}'){?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", pathParameters)
28+
{
29+
if (!string.IsNullOrWhiteSpace(name)) PathParameters.Add("name", name);
30+
if (!string.IsNullOrWhiteSpace(type)) PathParameters.Add("type", type);
31+
}
32+
/// <summary>
33+
/// Instantiates a new <see cref="global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder"/> and sets the default values.
34+
/// </summary>
35+
/// <param name="rawUrl">The raw URL to use for the request builder.</param>
36+
/// <param name="requestAdapter">The request adapter to use to execute the requests.</param>
37+
public MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/admin/teams/policy/microsoft.graph.teamsAdministration.getPolicyId(type='{type}',name='{name}'){?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", rawUrl)
38+
{
39+
}
40+
/// <summary>
41+
/// Get the policy ID for a given policy name and policy type within Teams administration.
42+
/// Find more info here <see href="https://learn.microsoft.com/graph/api/teamsadministration-teamspolicyassignment-getpolicyid?view=graph-rest-1.0" />
43+
/// </summary>
44+
/// <returns>A <see cref="global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameGetResponse"/></returns>
45+
/// <param name="cancellationToken">Cancellation token to use when cancelling requests</param>
46+
/// <param name="requestConfiguration">Configuration for the request such as headers, query parameters, and middleware options.</param>
47+
/// <exception cref="global::Microsoft.Graph.Models.ODataErrors.ODataError">When receiving a 4XX or 5XX status code</exception>
48+
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
49+
#nullable enable
50+
public async Task<global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameGetResponse?> GetAsGetPolicyIdWithTypeWithNameGetResponseAsync(Action<RequestConfiguration<global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilderGetQueryParameters>>? requestConfiguration = default, CancellationToken cancellationToken = default)
51+
{
52+
#nullable restore
53+
#else
54+
public async Task<global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameGetResponse> GetAsGetPolicyIdWithTypeWithNameGetResponseAsync(Action<RequestConfiguration<global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilderGetQueryParameters>> requestConfiguration = default, CancellationToken cancellationToken = default)
55+
{
56+
#endif
57+
var requestInfo = ToGetRequestInformation(requestConfiguration);
58+
var errorMapping = new Dictionary<string, ParsableFactory<IParsable>>
59+
{
60+
{ "XXX", global::Microsoft.Graph.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue },
61+
};
62+
return await RequestAdapter.SendAsync<global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameGetResponse>(requestInfo, global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameGetResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
63+
}
64+
/// <summary>
65+
/// Get the policy ID for a given policy name and policy type within Teams administration.
66+
/// Find more info here <see href="https://learn.microsoft.com/graph/api/teamsadministration-teamspolicyassignment-getpolicyid?view=graph-rest-1.0" />
67+
/// </summary>
68+
/// <returns>A <see cref="global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameResponse"/></returns>
69+
/// <param name="cancellationToken">Cancellation token to use when cancelling requests</param>
70+
/// <param name="requestConfiguration">Configuration for the request such as headers, query parameters, and middleware options.</param>
71+
/// <exception cref="global::Microsoft.Graph.Models.ODataErrors.ODataError">When receiving a 4XX or 5XX status code</exception>
72+
[Obsolete("This method is obsolete. Use GetAsGetPolicyIdWithTypeWithNameGetResponseAsync instead.")]
73+
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
74+
#nullable enable
75+
public async Task<global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameResponse?> GetAsync(Action<RequestConfiguration<global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilderGetQueryParameters>>? requestConfiguration = default, CancellationToken cancellationToken = default)
76+
{
77+
#nullable restore
78+
#else
79+
public async Task<global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameResponse> GetAsync(Action<RequestConfiguration<global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilderGetQueryParameters>> requestConfiguration = default, CancellationToken cancellationToken = default)
80+
{
81+
#endif
82+
var requestInfo = ToGetRequestInformation(requestConfiguration);
83+
var errorMapping = new Dictionary<string, ParsableFactory<IParsable>>
84+
{
85+
{ "XXX", global::Microsoft.Graph.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue },
86+
};
87+
return await RequestAdapter.SendAsync<global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameResponse>(requestInfo, global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.GetPolicyIdWithTypeWithNameResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false);
88+
}
89+
/// <summary>
90+
/// Get the policy ID for a given policy name and policy type within Teams administration.
91+
/// </summary>
92+
/// <returns>A <see cref="RequestInformation"/></returns>
93+
/// <param name="requestConfiguration">Configuration for the request such as headers, query parameters, and middleware options.</param>
94+
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
95+
#nullable enable
96+
public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilderGetQueryParameters>>? requestConfiguration = default)
97+
{
98+
#nullable restore
99+
#else
100+
public RequestInformation ToGetRequestInformation(Action<RequestConfiguration<global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilderGetQueryParameters>> requestConfiguration = default)
101+
{
102+
#endif
103+
var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters);
104+
requestInfo.Configure(requestConfiguration);
105+
requestInfo.Headers.TryAdd("Accept", "application/json");
106+
return requestInfo;
107+
}
108+
/// <summary>
109+
/// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored.
110+
/// </summary>
111+
/// <returns>A <see cref="global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder"/></returns>
112+
/// <param name="rawUrl">The raw URL to use for the request builder.</param>
113+
public global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder WithUrl(string rawUrl)
114+
{
115+
return new global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder(rawUrl, RequestAdapter);
116+
}
117+
/// <summary>
118+
/// Get the policy ID for a given policy name and policy type within Teams administration.
119+
/// </summary>
120+
[global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")]
121+
public partial class MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilderGetQueryParameters
122+
{
123+
/// <summary>Include count of items</summary>
124+
[QueryParameter("%24count")]
125+
public bool? Count { get; set; }
126+
/// <summary>Expand related entities</summary>
127+
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
128+
#nullable enable
129+
[QueryParameter("%24expand")]
130+
public string[]? Expand { get; set; }
131+
#nullable restore
132+
#else
133+
[QueryParameter("%24expand")]
134+
public string[] Expand { get; set; }
135+
#endif
136+
/// <summary>Filter items by property values</summary>
137+
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
138+
#nullable enable
139+
[QueryParameter("%24filter")]
140+
public string? Filter { get; set; }
141+
#nullable restore
142+
#else
143+
[QueryParameter("%24filter")]
144+
public string Filter { get; set; }
145+
#endif
146+
/// <summary>Order items by property values</summary>
147+
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
148+
#nullable enable
149+
[QueryParameter("%24orderby")]
150+
public string[]? Orderby { get; set; }
151+
#nullable restore
152+
#else
153+
[QueryParameter("%24orderby")]
154+
public string[] Orderby { get; set; }
155+
#endif
156+
/// <summary>Search items by search phrases</summary>
157+
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
158+
#nullable enable
159+
[QueryParameter("%24search")]
160+
public string? Search { get; set; }
161+
#nullable restore
162+
#else
163+
[QueryParameter("%24search")]
164+
public string Search { get; set; }
165+
#endif
166+
/// <summary>Select properties to be returned</summary>
167+
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
168+
#nullable enable
169+
[QueryParameter("%24select")]
170+
public string[]? Select { get; set; }
171+
#nullable restore
172+
#else
173+
[QueryParameter("%24select")]
174+
public string[] Select { get; set; }
175+
#endif
176+
/// <summary>Skip the first n items</summary>
177+
[QueryParameter("%24skip")]
178+
public int? Skip { get; set; }
179+
/// <summary>Show only the first n items</summary>
180+
[QueryParameter("%24top")]
181+
public int? Top { get; set; }
182+
}
183+
/// <summary>
184+
/// Configuration for the request such as headers, query parameters, and middleware options.
185+
/// </summary>
186+
[Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")]
187+
[global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")]
188+
public partial class MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilderGetRequestConfiguration : RequestConfiguration<global::Microsoft.Graph.Admin.Teams.Policy.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithName.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilder.MicrosoftGraphTeamsAdministrationGetPolicyIdWithTypeWithNameRequestBuilderGetQueryParameters>
189+
{
190+
}
191+
}
192+
}
193+
#pragma warning restore CS0618

0 commit comments

Comments
 (0)