From 0f871c8236a2f48cd55564b874528fdf2055b5a1 Mon Sep 17 00:00:00 2001 From: Microsoft Graph DevX Tooling Date: Thu, 24 Sep 2026 13:41:11 -0700 Subject: [PATCH 1/2] renamde namingOverrides to cmdletconfigurations and seperate configurations by module --- .../Applications_cmdletConfigurations.cs | 3 + .../BackupRestore_cmdletConfigurations.cs | 3 + .../wrapper/Bookings_cmdletConfigurations.cs | 25 ++ .../BusinessScenario_cmdletConfigurations.cs | 3 + .../wrapper/Calendar_cmdletConfigurations.cs | 33 ++ ...hangeNotifications_cmdletConfigurations.cs | 3 + ...loudCommunications_cmdletConfigurations.cs | 3 + .../Compliance_cmdletConfigurations.cs | 3 + ...gurationManagement_cmdletConfigurations.cs | 3 + ...sDeviceExperiences_cmdletConfigurations.cs | 3 + ...ent.Administration_cmdletConfigurations.cs | 18 + ...agement.Enrollment_cmdletConfigurations.cs | 3 + ...nagement.Functions_cmdletConfigurations.cs | 3 + .../DeviceManagement_cmdletConfigurations.cs | 3 + ...Devices.CloudPrint_cmdletConfigurations.cs | 3 + ...orporateManagement_cmdletConfigurations.cs | 12 + ...erviceAnnouncement_cmdletConfigurations.cs | 3 + .../DirectoryObjects_cmdletConfigurations.cs | 3 + .../wrapper/Education_cmdletConfigurations.cs | 14 + .../wrapper/Files_cmdletConfigurations.cs | 21 + .../Financials_cmdletConfigurations.cs | 3 + .../wrapper/Groups_cmdletConfigurations.cs | 19 + ...irectoryManagement_cmdletConfigurations.cs | 38 ++ ...dentity.Governance_cmdletConfigurations.cs | 34 ++ .../Identity.Partner_cmdletConfigurations.cs | 3 + .../Identity.SignIns_cmdletConfigurations.cs | 12 + src/Mail/wrapper/Mail_cmdletConfigurations.cs | 12 + .../ManagedTenants_cmdletConfigurations.cs | 3 + .../Migrations_cmdletConfigurations.cs | 3 + .../NetworkAccess_cmdletConfigurations.cs | 3 + .../wrapper/Notes_cmdletConfigurations.cs | 3 + .../wrapper/People_cmdletConfigurations.cs | 3 + .../PersonalContacts_cmdletConfigurations.cs | 3 + .../wrapper/Planner_cmdletConfigurations.cs | 3 + .../wrapper/Reports_cmdletConfigurations.cs | 3 + .../SchemaExtensions_cmdletConfigurations.cs | 3 + .../wrapper/Search_cmdletConfigurations.cs | 3 + .../wrapper/Security_cmdletConfigurations.cs | 36 ++ .../wrapper/Sites_cmdletConfigurations.cs | 36 ++ .../wrapper/Teams_cmdletConfigurations.cs | 19 + .../Users.Actions_cmdletConfigurations.cs | 3 + .../Users.Functions_cmdletConfigurations.cs | 3 + .../wrapper/Users_cmdletConfigurations.cs | 16 + .../WindowsUpdates_cmdletConfigurations.cs | 3 + .../DerivedCollisionResolutionsTests.cs | 10 +- .../GenerationServiceRegressionTests.cs | 2 +- tools/WrapperGenerator.Tests/NamingTests.cs | 44 +-- tools/WrapperGenerator/CmdletConfigurator.cs | 208 ++++++++++ tools/WrapperGenerator/CmdletNaming.cs | 12 +- .../DerivedCollisionResolutions.cs | 4 +- tools/WrapperGenerator/NamingOverrides.cs | 358 ------------------ .../PowerShellWrapperGenerationService.cs | 8 +- tools/WrapperGenerator/README.md | 7 +- .../WrapperGenerator/WrapperGenerator.csproj | 5 + .../edge-cases/crosspath-merge-edge-cases.md | 4 +- .../docs/edge-cases/naming-edge-cases.md | 9 +- 56 files changed, 696 insertions(+), 407 deletions(-) create mode 100644 src/Applications/wrapper/Applications_cmdletConfigurations.cs create mode 100644 src/BackupRestore/wrapper/BackupRestore_cmdletConfigurations.cs create mode 100644 src/Bookings/wrapper/Bookings_cmdletConfigurations.cs create mode 100644 src/BusinessScenario/wrapper/BusinessScenario_cmdletConfigurations.cs create mode 100644 src/Calendar/wrapper/Calendar_cmdletConfigurations.cs create mode 100644 src/ChangeNotifications/wrapper/ChangeNotifications_cmdletConfigurations.cs create mode 100644 src/CloudCommunications/wrapper/CloudCommunications_cmdletConfigurations.cs create mode 100644 src/Compliance/wrapper/Compliance_cmdletConfigurations.cs create mode 100644 src/ConfigurationManagement/wrapper/ConfigurationManagement_cmdletConfigurations.cs create mode 100644 src/CrossDeviceExperiences/wrapper/CrossDeviceExperiences_cmdletConfigurations.cs create mode 100644 src/DeviceManagement.Administration/wrapper/DeviceManagement.Administration_cmdletConfigurations.cs create mode 100644 src/DeviceManagement.Enrollment/wrapper/DeviceManagement.Enrollment_cmdletConfigurations.cs create mode 100644 src/DeviceManagement.Functions/wrapper/DeviceManagement.Functions_cmdletConfigurations.cs create mode 100644 src/DeviceManagement/wrapper/DeviceManagement_cmdletConfigurations.cs create mode 100644 src/Devices.CloudPrint/wrapper/Devices.CloudPrint_cmdletConfigurations.cs create mode 100644 src/Devices.CorporateManagement/wrapper/Devices.CorporateManagement_cmdletConfigurations.cs create mode 100644 src/Devices.ServiceAnnouncement/wrapper/Devices.ServiceAnnouncement_cmdletConfigurations.cs create mode 100644 src/DirectoryObjects/wrapper/DirectoryObjects_cmdletConfigurations.cs create mode 100644 src/Education/wrapper/Education_cmdletConfigurations.cs create mode 100644 src/Files/wrapper/Files_cmdletConfigurations.cs create mode 100644 src/Financials/wrapper/Financials_cmdletConfigurations.cs create mode 100644 src/Groups/wrapper/Groups_cmdletConfigurations.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/Identity.DirectoryManagement_cmdletConfigurations.cs create mode 100644 src/Identity.Governance/wrapper/Identity.Governance_cmdletConfigurations.cs create mode 100644 src/Identity.Partner/wrapper/Identity.Partner_cmdletConfigurations.cs create mode 100644 src/Identity.SignIns/wrapper/Identity.SignIns_cmdletConfigurations.cs create mode 100644 src/Mail/wrapper/Mail_cmdletConfigurations.cs create mode 100644 src/ManagedTenants/wrapper/ManagedTenants_cmdletConfigurations.cs create mode 100644 src/Migrations/wrapper/Migrations_cmdletConfigurations.cs create mode 100644 src/NetworkAccess/wrapper/NetworkAccess_cmdletConfigurations.cs create mode 100644 src/Notes/wrapper/Notes_cmdletConfigurations.cs create mode 100644 src/People/wrapper/People_cmdletConfigurations.cs create mode 100644 src/PersonalContacts/wrapper/PersonalContacts_cmdletConfigurations.cs create mode 100644 src/Planner/wrapper/Planner_cmdletConfigurations.cs create mode 100644 src/Reports/wrapper/Reports_cmdletConfigurations.cs create mode 100644 src/SchemaExtensions/wrapper/SchemaExtensions_cmdletConfigurations.cs create mode 100644 src/Search/wrapper/Search_cmdletConfigurations.cs create mode 100644 src/Security/wrapper/Security_cmdletConfigurations.cs create mode 100644 src/Sites/wrapper/Sites_cmdletConfigurations.cs create mode 100644 src/Teams/wrapper/Teams_cmdletConfigurations.cs create mode 100644 src/Users.Actions/wrapper/Users.Actions_cmdletConfigurations.cs create mode 100644 src/Users.Functions/wrapper/Users.Functions_cmdletConfigurations.cs create mode 100644 src/Users/wrapper/Users_cmdletConfigurations.cs create mode 100644 src/WindowsUpdates/wrapper/WindowsUpdates_cmdletConfigurations.cs create mode 100644 tools/WrapperGenerator/CmdletConfigurator.cs delete mode 100644 tools/WrapperGenerator/NamingOverrides.cs diff --git a/src/Applications/wrapper/Applications_cmdletConfigurations.cs b/src/Applications/wrapper/Applications_cmdletConfigurations.cs new file mode 100644 index 00000000000..09989ab7f0c --- /dev/null +++ b/src/Applications/wrapper/Applications_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List ApplicationsCmdletConfigurations = []; } diff --git a/src/BackupRestore/wrapper/BackupRestore_cmdletConfigurations.cs b/src/BackupRestore/wrapper/BackupRestore_cmdletConfigurations.cs new file mode 100644 index 00000000000..5a0420169b9 --- /dev/null +++ b/src/BackupRestore/wrapper/BackupRestore_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List BackupRestoreCmdletConfigurations = []; } diff --git a/src/Bookings/wrapper/Bookings_cmdletConfigurations.cs b/src/Bookings/wrapper/Bookings_cmdletConfigurations.cs new file mode 100644 index 00000000000..7e23ccbd317 --- /dev/null +++ b/src/Bookings/wrapper/Bookings_cmdletConfigurations.cs @@ -0,0 +1,25 @@ +using System.Collections.Generic; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List BookingsCmdletConfigurations = + [ + // The SDK ships no cmdlets for the /solutions root singleton itself (Get-MgSolution / + // Update-MgSolution do not exist): src/Bookings/Bookings.md removes every solutionsRoot + // operation with remove-path-by-operation ^solution\.solutionsRoot.*$. Exact-path, all + // methods, so operations on children like /solutions/bookingBusinesses are unaffected. + new(OverrideKind.SuppressOperation, Method: null, "/solutions", Match: PathMatch.Exact, Value: null, + Reason: "Bookings.md remove-path-by-operation ^solution\\.solutionsRoot.*$"), + + // Most nouns under /solutions/ drop the "Solution" prefix (for example + // Get-MgBookingBusiness, Get-MgVirtualEventWebinar). BackupRestore is a known + // exception where published cmdlets keep the Solution prefix. + new(OverrideKind.StripNounPrefix, Method: null, "/solutions/", Match: PathMatch.Prefix, Value: "Solution", + Reason: "Bookings/VirtualEvents naming pattern under /solutions/*; BackupRestore is explicitly excluded in ApplyNounOverrides"), + + new(OverrideKind.SuppressOperation, Method: null, "/solutions/virtualevents", Match: PathMatch.Exact, Value: null, + Reason: "oracle: the virtualEvents root node ships nothing; children ship (Get-MgVirtualEventWebinar)"), + ]; +} diff --git a/src/BusinessScenario/wrapper/BusinessScenario_cmdletConfigurations.cs b/src/BusinessScenario/wrapper/BusinessScenario_cmdletConfigurations.cs new file mode 100644 index 00000000000..cda3d8746a7 --- /dev/null +++ b/src/BusinessScenario/wrapper/BusinessScenario_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List BusinessScenarioCmdletConfigurations = []; } diff --git a/src/Calendar/wrapper/Calendar_cmdletConfigurations.cs b/src/Calendar/wrapper/Calendar_cmdletConfigurations.cs new file mode 100644 index 00000000000..c84d810aba2 --- /dev/null +++ b/src/Calendar/wrapper/Calendar_cmdletConfigurations.cs @@ -0,0 +1,33 @@ +using System.Collections.Generic; +using System.Net.Http; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List CalendarCmdletConfigurations = + [ + // The SDK ships no Update cmdlet for /users/{id}/calendar. Its pipeline removes the + // operation outright, in src/Calendar/Calendar.md: remove-path-by-operation + // user_UpdateCalendar. The wrapper must not invent a cmdlet the SDK chose to drop. + new(OverrideKind.SuppressOperation, HttpMethod.Patch, "/users/{}/calendar", Match: PathMatch.Exact, Value: null, + Reason: "Calendar.md remove-path-by-operation user_UpdateCalendar"), + + // GET /users/{id}/calendar ships as Get-MgUserDefaultCalendar, renamed in + // src/Calendar/Calendar.md: "^(User)(Calendar)$" -> "$1Default$2". + new(OverrideKind.ReplaceNoun, HttpMethod.Get, "/users/{}/calendar", Match: PathMatch.Exact, Value: "UserDefaultCalendar", + Reason: "Calendar.md directive renames UserCalendar to UserDefaultCalendar"), + + // Calendar: the shipped default-calendar surface. Events under a NAMED calendar and + // the default-calendar event item tree ship nothing; event items ship from + // /users/{}/events (Get-MgUserEvent family). + new(OverrideKind.ReplaceNoun, Method: null, "/users/{}/calendar/events", Match: PathMatch.Exact, Value: "UserDefaultCalendarEvent", + Reason: "oracle: list/create ship as Get/New-MgUserDefaultCalendarEvent"), + new(OverrideKind.SuppressOperation, Method: null, "/users/{}/calendar/events/{}", Match: PathMatch.Prefix, Value: null, + Reason: "oracle: default-calendar event items ship nothing; items ship from /users/{}/events/{}"), + new(OverrideKind.SuppressOperation, Method: null, "/users/{}/calendars/{}/events/{}", Match: PathMatch.Prefix, Value: null, + Reason: "oracle: named-calendar event items ship nothing; items ship from /users/{}/events/{}"), + new(OverrideKind.SuppressOperation, Method: null, "/users/{}/calendars/{}/calendarpermissions", Match: PathMatch.Prefix, Value: null, + Reason: "oracle: permissions ship only from the default calendar (Get-MgUserCalendarPermission on /users/{}/calendar/calendarPermissions)"), + ]; +} diff --git a/src/ChangeNotifications/wrapper/ChangeNotifications_cmdletConfigurations.cs b/src/ChangeNotifications/wrapper/ChangeNotifications_cmdletConfigurations.cs new file mode 100644 index 00000000000..ed2eb6e96d5 --- /dev/null +++ b/src/ChangeNotifications/wrapper/ChangeNotifications_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List ChangeNotificationsCmdletConfigurations = []; } diff --git a/src/CloudCommunications/wrapper/CloudCommunications_cmdletConfigurations.cs b/src/CloudCommunications/wrapper/CloudCommunications_cmdletConfigurations.cs new file mode 100644 index 00000000000..77e925f1be5 --- /dev/null +++ b/src/CloudCommunications/wrapper/CloudCommunications_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List CloudCommunicationsCmdletConfigurations = []; } diff --git a/src/Compliance/wrapper/Compliance_cmdletConfigurations.cs b/src/Compliance/wrapper/Compliance_cmdletConfigurations.cs new file mode 100644 index 00000000000..8d8d726c021 --- /dev/null +++ b/src/Compliance/wrapper/Compliance_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List ComplianceCmdletConfigurations = []; } diff --git a/src/ConfigurationManagement/wrapper/ConfigurationManagement_cmdletConfigurations.cs b/src/ConfigurationManagement/wrapper/ConfigurationManagement_cmdletConfigurations.cs new file mode 100644 index 00000000000..431823e372f --- /dev/null +++ b/src/ConfigurationManagement/wrapper/ConfigurationManagement_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List ConfigurationManagementCmdletConfigurations = []; } diff --git a/src/CrossDeviceExperiences/wrapper/CrossDeviceExperiences_cmdletConfigurations.cs b/src/CrossDeviceExperiences/wrapper/CrossDeviceExperiences_cmdletConfigurations.cs new file mode 100644 index 00000000000..85ff011c1de --- /dev/null +++ b/src/CrossDeviceExperiences/wrapper/CrossDeviceExperiences_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List CrossDeviceExperiencesCmdletConfigurations = []; } diff --git a/src/DeviceManagement.Administration/wrapper/DeviceManagement.Administration_cmdletConfigurations.cs b/src/DeviceManagement.Administration/wrapper/DeviceManagement.Administration_cmdletConfigurations.cs new file mode 100644 index 00000000000..cb3a5bb68e7 --- /dev/null +++ b/src/DeviceManagement.Administration/wrapper/DeviceManagement.Administration_cmdletConfigurations.cs @@ -0,0 +1,18 @@ +using System.Collections.Generic; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List DeviceManagementAdministrationCmdletConfigurations = + [ + // Naming-parity sweep (2026-08-13): the other of the two rules proved safe against the + // whole corpus, fixing real mismatches without rewriting a currently matching name. + // The resource repeats its parent's name, so segment-joining yields + // DeviceManagementDeviceManagementPartner. The published SDK collapses the repetition. + new(OverrideKind.ReplaceNoun, Method: null, "/devicemanagement/devicemanagementpartners", Match: PathMatch.Exact, Value: "DeviceManagementPartner", + Reason: "oracle ships Get-MgDeviceManagementPartner, not ...DeviceManagementDeviceManagementPartner"), + new(OverrideKind.ReplaceNoun, Method: null, "/devicemanagement/devicemanagementpartners/{}", Match: PathMatch.Exact, Value: "DeviceManagementPartner", + Reason: "oracle ships Get-MgDeviceManagementPartner"), + ]; +} diff --git a/src/DeviceManagement.Enrollment/wrapper/DeviceManagement.Enrollment_cmdletConfigurations.cs b/src/DeviceManagement.Enrollment/wrapper/DeviceManagement.Enrollment_cmdletConfigurations.cs new file mode 100644 index 00000000000..5712925b83c --- /dev/null +++ b/src/DeviceManagement.Enrollment/wrapper/DeviceManagement.Enrollment_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List DeviceManagementEnrollmentCmdletConfigurations = []; } diff --git a/src/DeviceManagement.Functions/wrapper/DeviceManagement.Functions_cmdletConfigurations.cs b/src/DeviceManagement.Functions/wrapper/DeviceManagement.Functions_cmdletConfigurations.cs new file mode 100644 index 00000000000..ee7c7cc98ae --- /dev/null +++ b/src/DeviceManagement.Functions/wrapper/DeviceManagement.Functions_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List DeviceManagementFunctionsCmdletConfigurations = []; } diff --git a/src/DeviceManagement/wrapper/DeviceManagement_cmdletConfigurations.cs b/src/DeviceManagement/wrapper/DeviceManagement_cmdletConfigurations.cs new file mode 100644 index 00000000000..e644dfd75dc --- /dev/null +++ b/src/DeviceManagement/wrapper/DeviceManagement_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List DeviceManagementCmdletConfigurations = []; } diff --git a/src/Devices.CloudPrint/wrapper/Devices.CloudPrint_cmdletConfigurations.cs b/src/Devices.CloudPrint/wrapper/Devices.CloudPrint_cmdletConfigurations.cs new file mode 100644 index 00000000000..51aa2faea92 --- /dev/null +++ b/src/Devices.CloudPrint/wrapper/Devices.CloudPrint_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List DevicesCloudPrintCmdletConfigurations = []; } diff --git a/src/Devices.CorporateManagement/wrapper/Devices.CorporateManagement_cmdletConfigurations.cs b/src/Devices.CorporateManagement/wrapper/Devices.CorporateManagement_cmdletConfigurations.cs new file mode 100644 index 00000000000..3abb044dc6b --- /dev/null +++ b/src/Devices.CorporateManagement/wrapper/Devices.CorporateManagement_cmdletConfigurations.cs @@ -0,0 +1,12 @@ +using System.Collections.Generic; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List DevicesCorporateManagementCmdletConfigurations = + [ + new(OverrideKind.SuppressOperation, Method: null, "/deviceappmanagement/mobileapps/{}/categories", Match: PathMatch.Prefix, Value: null, + Reason: "oracle: nested app categories ship nothing; the set ships top-level (mobileAppCategories)"), + ]; +} diff --git a/src/Devices.ServiceAnnouncement/wrapper/Devices.ServiceAnnouncement_cmdletConfigurations.cs b/src/Devices.ServiceAnnouncement/wrapper/Devices.ServiceAnnouncement_cmdletConfigurations.cs new file mode 100644 index 00000000000..84001b41069 --- /dev/null +++ b/src/Devices.ServiceAnnouncement/wrapper/Devices.ServiceAnnouncement_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List DevicesServiceAnnouncementCmdletConfigurations = []; } diff --git a/src/DirectoryObjects/wrapper/DirectoryObjects_cmdletConfigurations.cs b/src/DirectoryObjects/wrapper/DirectoryObjects_cmdletConfigurations.cs new file mode 100644 index 00000000000..13b09e756ce --- /dev/null +++ b/src/DirectoryObjects/wrapper/DirectoryObjects_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List DirectoryObjectsCmdletConfigurations = []; } diff --git a/src/Education/wrapper/Education_cmdletConfigurations.cs b/src/Education/wrapper/Education_cmdletConfigurations.cs new file mode 100644 index 00000000000..05c2de44bef --- /dev/null +++ b/src/Education/wrapper/Education_cmdletConfigurations.cs @@ -0,0 +1,14 @@ +using System.Collections.Generic; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List EducationCmdletConfigurations = + [ + new(OverrideKind.SuppressOperation, Method: null, "/education/classes/{}/assignments/{}/categories", Match: PathMatch.Exact, Value: null, + Reason: "oracle: the plain path ships nothing; the shipped surface is the $ref route"), + new(OverrideKind.SuppressOperation, Method: null, "/education/users/{}/user", Match: PathMatch.Exact, Value: null, + Reason: "oracle: the user self-nav node ships nothing; its children (mailboxSettings) ship"), + ]; +} diff --git a/src/Files/wrapper/Files_cmdletConfigurations.cs b/src/Files/wrapper/Files_cmdletConfigurations.cs new file mode 100644 index 00000000000..e6c83050918 --- /dev/null +++ b/src/Files/wrapper/Files_cmdletConfigurations.cs @@ -0,0 +1,21 @@ +using System.Collections.Generic; +using System.Net.Http; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List FilesCmdletConfigurations = + [ + new(OverrideKind.ReplaceNoun, HttpMethod.Get, "/groups/{}/drive", Match: PathMatch.Exact, Value: "GroupDefaultDrive", + Reason: "Files.md directive (subject $1Default$2); oracle ships Get-MgGroupDefaultDrive"), + new(OverrideKind.ReplaceNoun, HttpMethod.Get, "/users/{}/drive", Match: PathMatch.Exact, Value: "UserDefaultDrive", + Reason: "Files.md directive (subject $1Default$2); oracle ships Get-MgUserDefaultDrive"), + new(OverrideKind.ReplaceNoun, HttpMethod.Get, "/sites/{}/drive", Match: PathMatch.Exact, Value: "SiteDefaultDrive", + Reason: "oracle ships Get-MgSiteDefaultDrive for the site default-drive singleton"), + new(OverrideKind.ReplaceNoun, HttpMethod.Get, "/groups/{}/sites/{}/drive", Match: PathMatch.Exact, Value: "GroupSiteDefaultDrive", + Reason: "oracle ships Get-MgGroupSiteDefaultDrive"), + new(OverrideKind.SuppressOperation, HttpMethod.Get, "/shares/{}/list/items/{}", Match: PathMatch.Exact, Value: null, + Reason: "oracle: the bare shared-list item GET ships nothing; its descendants ship"), + ]; +} diff --git a/src/Financials/wrapper/Financials_cmdletConfigurations.cs b/src/Financials/wrapper/Financials_cmdletConfigurations.cs new file mode 100644 index 00000000000..78fa1c02faa --- /dev/null +++ b/src/Financials/wrapper/Financials_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List FinancialsCmdletConfigurations = []; } diff --git a/src/Groups/wrapper/Groups_cmdletConfigurations.cs b/src/Groups/wrapper/Groups_cmdletConfigurations.cs new file mode 100644 index 00000000000..289c1f5d157 --- /dev/null +++ b/src/Groups/wrapper/Groups_cmdletConfigurations.cs @@ -0,0 +1,19 @@ +using System.Collections.Generic; +using System.Net.Http; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List GroupsCmdletConfigurations = + [ + // Groups: the nested lifecycle-policies GET ships renamed; everything else on that + // route ships from the top-level set. Photos items ship nothing (singleton /photo). + new(OverrideKind.ReplaceNoun, HttpMethod.Get, "/groups/{}/grouplifecyclepolicies", Match: PathMatch.Exact, Value: "GroupLifecyclePolicyByGroup", + Reason: "Groups.md directive (subject $1ByGroup); oracle ships Get-MgGroupLifecyclePolicyByGroup"), + new(OverrideKind.SuppressOperation, Method: null, "/groups/{}/grouplifecyclepolicies/", Match: PathMatch.Prefix, Value: null, + Reason: "oracle: item/children under the nested route ship nothing; the set ships top-level"), + new(OverrideKind.SuppressOperation, Method: null, "/groups/{}/photos/{}", Match: PathMatch.Exact, Value: null, + Reason: "oracle: photos items ship nothing; shipped surface is the /photo singleton (Get-MgGroupPhoto)"), + ]; +} diff --git a/src/Identity.DirectoryManagement/wrapper/Identity.DirectoryManagement_cmdletConfigurations.cs b/src/Identity.DirectoryManagement/wrapper/Identity.DirectoryManagement_cmdletConfigurations.cs new file mode 100644 index 00000000000..82f81f72eac --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/Identity.DirectoryManagement_cmdletConfigurations.cs @@ -0,0 +1,38 @@ +using System.Collections.Generic; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List IdentityDirectoryManagementCmdletConfigurations = + [ + // ---- Naming-parity sweep (2026-08-13): one of the two rules proved safe. ---- + // + // Both safe rules were measured against the whole corpus first: each fixes real + // mismatches and rewrites no currently-matching name. Every other candidate rule from + // that sweep broke more names than it fixed (dropping "IdentityGovernance" would have + // fixed 297 and broken 417), so the rest await oracle-derived naming. + + // "people" is singularized everywhere else and correctly so - /users/{}/people ships as + // Get-MgUserPerson. Under /admin/people the published SDK keeps the plural, so this is + // scoped per path rather than by making "people" invariant, which would break UserPerson. + new(OverrideKind.ReplaceNoun, Method: null, "/admin/people", Match: PathMatch.Exact, Value: "AdminPeople", + Reason: "oracle ships Get-MgAdminPeople; /admin/people keeps the plural"), + new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/iteminsights", Match: PathMatch.Exact, Value: "AdminPeopleItemInsight", + Reason: "oracle ships Get-MgAdminPeopleItemInsight"), + new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/profilecardproperties", Match: PathMatch.Exact, Value: "AdminPeopleProfileCardProperty", + Reason: "oracle ships Get-MgAdminPeopleProfileCardProperty"), + new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/profilecardproperties/{}", Match: PathMatch.Exact, Value: "AdminPeopleProfileCardProperty", + Reason: "oracle ships Get-MgAdminPeopleProfileCardProperty"), + new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/profilepropertysettings", Match: PathMatch.Exact, Value: "AdminPeopleProfilePropertySetting", + Reason: "oracle ships Get-MgAdminPeopleProfilePropertySetting"), + new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/profilepropertysettings/{}", Match: PathMatch.Exact, Value: "AdminPeopleProfilePropertySetting", + Reason: "oracle ships Get-MgAdminPeopleProfilePropertySetting"), + new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/profilesources", Match: PathMatch.Exact, Value: "AdminPeopleProfileSource", + Reason: "oracle ships Get-MgAdminPeopleProfileSource"), + new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/profilesources/{}", Match: PathMatch.Exact, Value: "AdminPeopleProfileSource", + Reason: "oracle ships Get-MgAdminPeopleProfileSource"), + new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/pronouns", Match: PathMatch.Exact, Value: "AdminPeoplePronoun", + Reason: "oracle ships Get-MgAdminPeoplePronoun"), + ]; +} diff --git a/src/Identity.Governance/wrapper/Identity.Governance_cmdletConfigurations.cs b/src/Identity.Governance/wrapper/Identity.Governance_cmdletConfigurations.cs new file mode 100644 index 00000000000..5ec893b8bec --- /dev/null +++ b/src/Identity.Governance/wrapper/Identity.Governance_cmdletConfigurations.cs @@ -0,0 +1,34 @@ +using System.Collections.Generic; +using System.Net.Http; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List IdentityGovernanceCmdletConfigurations = + [ + // Agreement file item operations ship only from the /file singleton; /files/{} items + // ship nothing, while /files/{}/versions remains a valid descendant. + new(OverrideKind.SuppressOperation, Method: null, "/agreements/{}/files/{}", Match: PathMatch.Exact, Value: null, + Reason: "oracle: /files/{} item ops ship nothing; file surface is the /file singleton (Update/Remove-MgAgreementFile)"), + new(OverrideKind.SuppressOperation, Method: null, "/identitygovernance/termsofuse/agreements/{}/files/{}", Match: PathMatch.Exact, Value: null, + Reason: "oracle: ships nothing; mirrors /agreements/{}/files/{} suppression"), + // GET of the file/files pair ships from the collection; Update/Remove stay on singleton. + new(OverrideKind.SuppressOperation, HttpMethod.Get, "/agreements/{}/file", Match: PathMatch.Exact, Value: null, + Reason: "oracle: Get-MgAgreementFile serves /file and /files; GET generated from the collection side only"), + new(OverrideKind.SuppressOperation, HttpMethod.Get, "/identitygovernance/termsofuse/agreements/{}/file", Match: PathMatch.Exact, Value: null, + Reason: "oracle: Get-MgIdentityGovernanceTermsOfUseAgreementFile serves /file and /files; GET from the collection side only"), + // The /scope node duplicates its parent's noun and ships nothing anywhere; its + // children ship with the Scope segment elided. + new(OverrideKind.SuppressOperation, Method: null, "/resourcerolescopes/{}/scope", Match: PathMatch.Suffix, Value: null, + Reason: "oracle: the /scope node ships nothing under any parent; children ship with Scope elided"), + new(OverrideKind.SuppressOperation, Method: null, "/identitygovernance/entitlementmanagement/assignments/{}/assignmentpolicy", Match: PathMatch.Exact, Value: null, + Reason: "nav duplicate of /assignmentPolicies (Get-MgEntitlementManagementAssignmentPolicy); ships nothing"), + new(OverrideKind.SuppressOperation, Method: null, "/identitygovernance/entitlementmanagement/resources/{}/environment", Match: PathMatch.Exact, Value: null, + Reason: "nav duplicate of /resourceEnvironments (Get-MgEntitlementManagementResourceEnvironment); ships nothing"), + new(OverrideKind.SuppressOperation, Method: null, "/identitygovernance/lifecycleworkflows", Match: PathMatch.Exact, Value: null, + Reason: "the container node's own operations ship nothing; its children ship"), + new(OverrideKind.SuppressOperation, Method: null, "/identitygovernance/termsofuse/agreements/{}/acceptances", Match: PathMatch.Prefix, Value: null, + Reason: "ships nothing; acceptances ship from /termsOfUse/agreementAcceptances (Get-MgIdentityGovernanceTermsOfUseAgreementAcceptance)"), + ]; +} diff --git a/src/Identity.Partner/wrapper/Identity.Partner_cmdletConfigurations.cs b/src/Identity.Partner/wrapper/Identity.Partner_cmdletConfigurations.cs new file mode 100644 index 00000000000..a5f8a5237aa --- /dev/null +++ b/src/Identity.Partner/wrapper/Identity.Partner_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List IdentityPartnerCmdletConfigurations = []; } diff --git a/src/Identity.SignIns/wrapper/Identity.SignIns_cmdletConfigurations.cs b/src/Identity.SignIns/wrapper/Identity.SignIns_cmdletConfigurations.cs new file mode 100644 index 00000000000..b0ed3066b63 --- /dev/null +++ b/src/Identity.SignIns/wrapper/Identity.SignIns_cmdletConfigurations.cs @@ -0,0 +1,12 @@ +using System.Collections.Generic; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List IdentitySignInsCmdletConfigurations = + [ + new(OverrideKind.SuppressOperation, Method: null, "/identityproviders", Match: PathMatch.Prefix, Value: null, + Reason: "oracle: the deprecated top-level /identityProviders set ships nothing in v1.0; shipped surface is /identity/identityProviders (Get-MgIdentityProvider)"), + ]; +} diff --git a/src/Mail/wrapper/Mail_cmdletConfigurations.cs b/src/Mail/wrapper/Mail_cmdletConfigurations.cs new file mode 100644 index 00000000000..bd4cb90bf14 --- /dev/null +++ b/src/Mail/wrapper/Mail_cmdletConfigurations.cs @@ -0,0 +1,12 @@ +using System.Collections.Generic; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List MailCmdletConfigurations = + [ + new(OverrideKind.SuppressOperation, Method: null, "/replies/{}/replyto", Match: PathMatch.Suffix, Value: null, + Reason: "oracle: the replyTo nav ships nothing under any root"), + ]; +} diff --git a/src/ManagedTenants/wrapper/ManagedTenants_cmdletConfigurations.cs b/src/ManagedTenants/wrapper/ManagedTenants_cmdletConfigurations.cs new file mode 100644 index 00000000000..ad5e1d03bc9 --- /dev/null +++ b/src/ManagedTenants/wrapper/ManagedTenants_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List ManagedTenantsCmdletConfigurations = []; } diff --git a/src/Migrations/wrapper/Migrations_cmdletConfigurations.cs b/src/Migrations/wrapper/Migrations_cmdletConfigurations.cs new file mode 100644 index 00000000000..54651b456f2 --- /dev/null +++ b/src/Migrations/wrapper/Migrations_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List MigrationsCmdletConfigurations = []; } diff --git a/src/NetworkAccess/wrapper/NetworkAccess_cmdletConfigurations.cs b/src/NetworkAccess/wrapper/NetworkAccess_cmdletConfigurations.cs new file mode 100644 index 00000000000..373eaceded6 --- /dev/null +++ b/src/NetworkAccess/wrapper/NetworkAccess_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List NetworkAccessCmdletConfigurations = []; } diff --git a/src/Notes/wrapper/Notes_cmdletConfigurations.cs b/src/Notes/wrapper/Notes_cmdletConfigurations.cs new file mode 100644 index 00000000000..e043eb642a3 --- /dev/null +++ b/src/Notes/wrapper/Notes_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List NotesCmdletConfigurations = []; } diff --git a/src/People/wrapper/People_cmdletConfigurations.cs b/src/People/wrapper/People_cmdletConfigurations.cs new file mode 100644 index 00000000000..a477a3e85de --- /dev/null +++ b/src/People/wrapper/People_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List PeopleCmdletConfigurations = []; } diff --git a/src/PersonalContacts/wrapper/PersonalContacts_cmdletConfigurations.cs b/src/PersonalContacts/wrapper/PersonalContacts_cmdletConfigurations.cs new file mode 100644 index 00000000000..892e96d2237 --- /dev/null +++ b/src/PersonalContacts/wrapper/PersonalContacts_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List PersonalContactsCmdletConfigurations = []; } diff --git a/src/Planner/wrapper/Planner_cmdletConfigurations.cs b/src/Planner/wrapper/Planner_cmdletConfigurations.cs new file mode 100644 index 00000000000..2b85ea6bff5 --- /dev/null +++ b/src/Planner/wrapper/Planner_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List PlannerCmdletConfigurations = []; } diff --git a/src/Reports/wrapper/Reports_cmdletConfigurations.cs b/src/Reports/wrapper/Reports_cmdletConfigurations.cs new file mode 100644 index 00000000000..8cd7865115e --- /dev/null +++ b/src/Reports/wrapper/Reports_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List ReportsCmdletConfigurations = []; } diff --git a/src/SchemaExtensions/wrapper/SchemaExtensions_cmdletConfigurations.cs b/src/SchemaExtensions/wrapper/SchemaExtensions_cmdletConfigurations.cs new file mode 100644 index 00000000000..1ddfd402c2e --- /dev/null +++ b/src/SchemaExtensions/wrapper/SchemaExtensions_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List SchemaExtensionsCmdletConfigurations = []; } diff --git a/src/Search/wrapper/Search_cmdletConfigurations.cs b/src/Search/wrapper/Search_cmdletConfigurations.cs new file mode 100644 index 00000000000..512bf5d0df6 --- /dev/null +++ b/src/Search/wrapper/Search_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List SearchCmdletConfigurations = []; } diff --git a/src/Security/wrapper/Security_cmdletConfigurations.cs b/src/Security/wrapper/Security_cmdletConfigurations.cs new file mode 100644 index 00000000000..714b33184dd --- /dev/null +++ b/src/Security/wrapper/Security_cmdletConfigurations.cs @@ -0,0 +1,36 @@ +using System.Collections.Generic; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List SecurityCmdletConfigurations = + [ + // Security threatIntelligence: nested navs under articles/{} and hosts/{} duplicate + // the shipped top-level sets (articleIndicators, hostComponents, hostCookies, + // hostPairs, hostPorts, hostSslCertificates, hostTrackers) and ship nothing + // themselves. Exact-only: two of these navs have shipped $count children + // (Get-MgSecurityThreatIntelligenceHost{SslCertificate,Tracker}Count); the other five + // ship no children at all. + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/articles/{}/indicators", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level articleIndicators ships"), + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/articles/{}/indicators/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level articleIndicators ships"), + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/components", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostComponents ships"), + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/components/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostComponents ships"), + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/cookies", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostCookies ships"), + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/cookies/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostCookies ships"), + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/hostpairs", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostPairs ships"), + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/hostpairs/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostPairs ships"), + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/ports", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostPorts ships"), + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/ports/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostPorts ships"), + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/sslcertificates", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostSslCertificates ships"), + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/sslcertificates/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostSslCertificates ships"), + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/trackers", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostTrackers ships"), + new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/trackers/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostTrackers ships"), + // The attackSimulation container node itself ships nothing; children under a + // simulation item ship nothing either (the list/item pair then merges normally). + new(OverrideKind.SuppressOperation, Method: null, "/security/attacksimulation", Match: PathMatch.Exact, Value: null, + Reason: "oracle: the container node ships nothing; its child collections ship"), + new(OverrideKind.SuppressOperation, Method: null, "/security/attacksimulation/simulations/{}/", Match: PathMatch.Prefix, Value: null, + Reason: "oracle: nothing under a simulation item ships in v1.0"), + ]; +} diff --git a/src/Sites/wrapper/Sites_cmdletConfigurations.cs b/src/Sites/wrapper/Sites_cmdletConfigurations.cs new file mode 100644 index 00000000000..24ff3b971d9 --- /dev/null +++ b/src/Sites/wrapper/Sites_cmdletConfigurations.cs @@ -0,0 +1,36 @@ +using System.Collections.Generic; +using System.Net.Http; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List SitesCmdletConfigurations = + [ + // The spec carries two parallel termStore trees; the shipped surface stitches them: + // GET/POST come from the /termStores collection (Get-MgSiteTermStore, New-...), while + // PATCH/DELETE and all 402 descendant command rows come from the /termStore singleton. + // Nothing ships under /termStores/{id}, and the singleton root GET has no distinct + // cmdlet — generating either would collide with its shipped twin. + new(OverrideKind.SuppressOperation, Method: null, "/sites/{}/termstores/{}", Match: PathMatch.Prefix, Value: null, + Reason: "oracle: zero commands under /termStores/{id}; descendants ship from the /termStore singleton tree"), + new(OverrideKind.SuppressOperation, HttpMethod.Get, "/sites/{}/termstore", Match: PathMatch.Exact, Value: null, + Reason: "oracle: Get-MgSiteTermStore serves GET /termStore and /termStores; GET generates from the collection side only"), + new(OverrideKind.SuppressOperation, Method: null, "/groups/{}/sites/{}/termstores/{}", Match: PathMatch.Prefix, Value: null, + Reason: "oracle: zero commands under /termStores/{id}; descendants ship from the /termStore singleton tree"), + new(OverrideKind.SuppressOperation, HttpMethod.Get, "/groups/{}/sites/{}/termstore", Match: PathMatch.Exact, Value: null, + Reason: "oracle: Get-MgGroupSiteTermStore serves GET /termStore and /termStores; GET generates from the collection side only"), + + // Self-referential /sites: singularizing sites/{id}/sites collapses to the parent's + // noun, so the sub-sites cmdlets would overwrite Get-MgSite. The SDK ships them + // renamed: Get-MgSubSite and Get-MgGroupSubSite (v1.0 and beta, incl. $count). + new(OverrideKind.ReplaceNoun, Method: null, "/sites/{}/sites", Match: PathMatch.Exact, Value: "SubSite", + Reason: "Sites.md directive; oracle ships Get-MgSubSite for /sites/{site-id}/sites"), + new(OverrideKind.ReplaceNoun, Method: null, "/sites/{}/sites/{}", Match: PathMatch.Exact, Value: "SubSite", + Reason: "Sites.md directive; oracle ships Get-MgSubSite for /sites/{site-id}/sites/{site-id1}"), + new(OverrideKind.ReplaceNoun, Method: null, "/groups/{}/sites/{}/sites", Match: PathMatch.Exact, Value: "GroupSubSite", + Reason: "Sites.md directive; oracle ships Get-MgGroupSubSite"), + new(OverrideKind.ReplaceNoun, Method: null, "/groups/{}/sites/{}/sites/{}", Match: PathMatch.Exact, Value: "GroupSubSite", + Reason: "Sites.md directive; oracle ships Get-MgGroupSubSite"), + ]; +} diff --git a/src/Teams/wrapper/Teams_cmdletConfigurations.cs b/src/Teams/wrapper/Teams_cmdletConfigurations.cs new file mode 100644 index 00000000000..bdced6eaa62 --- /dev/null +++ b/src/Teams/wrapper/Teams_cmdletConfigurations.cs @@ -0,0 +1,19 @@ +using System.Collections.Generic; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List TeamsCmdletConfigurations = + [ + // Teams Info-wrapper navs: the wrapped single-entity navigation ships nothing under + // any root. The suffix matches just the nav node, so shipped siblings + // (…SharedWithTeamAllowedMember) are unaffected. + new(OverrideKind.SuppressOperation, Method: null, "/pinnedmessages/{}/message", Match: PathMatch.Suffix, Value: null, + Reason: "oracle: ships nothing under any root; list side ships (Get-MgChatPinnedMessage)"), + new(OverrideKind.SuppressOperation, Method: null, "/sharedwithteams/{}/team", Match: PathMatch.Suffix, Value: null, + Reason: "oracle: ships nothing; sibling /allowedMembers ships, so node-only"), + new(OverrideKind.SuppressOperation, Method: null, "/associatedteams/{}/team", Match: PathMatch.Suffix, Value: null, + Reason: "oracle: ships nothing; list side ships (Get-MgUserTeamworkAssociatedTeam)"), + ]; +} diff --git a/src/Users.Actions/wrapper/Users.Actions_cmdletConfigurations.cs b/src/Users.Actions/wrapper/Users.Actions_cmdletConfigurations.cs new file mode 100644 index 00000000000..5336c6cede1 --- /dev/null +++ b/src/Users.Actions/wrapper/Users.Actions_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List UsersActionsCmdletConfigurations = []; } diff --git a/src/Users.Functions/wrapper/Users.Functions_cmdletConfigurations.cs b/src/Users.Functions/wrapper/Users.Functions_cmdletConfigurations.cs new file mode 100644 index 00000000000..61c861dc59d --- /dev/null +++ b/src/Users.Functions/wrapper/Users.Functions_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List UsersFunctionsCmdletConfigurations = []; } diff --git a/src/Users/wrapper/Users_cmdletConfigurations.cs b/src/Users/wrapper/Users_cmdletConfigurations.cs new file mode 100644 index 00000000000..601c139a8a4 --- /dev/null +++ b/src/Users/wrapper/Users_cmdletConfigurations.cs @@ -0,0 +1,16 @@ +using System.Collections.Generic; + +namespace WrapperGenerator; + +public static partial class CmdletConfigurator +{ + private static readonly List UsersCmdletConfigurations = + [ + // Get-MgUserPhoto serves both /photo and /photos; the /photos routes ship no distinct + // cmdlet, and generating them would collide with the singleton's noun. + new(OverrideKind.SuppressOperation, Method: null, "/users/{}/photos", Match: PathMatch.Exact, Value: null, + Reason: "oracle: Get-MgUserPhoto serves /photo and /photos; the collection ships no distinct cmdlet"), + new(OverrideKind.SuppressOperation, Method: null, "/users/{}/photos/{}", Match: PathMatch.Exact, Value: null, + Reason: "oracle: /photos/{} ships nothing; the photo surface is the /photo singleton"), + ]; +} diff --git a/src/WindowsUpdates/wrapper/WindowsUpdates_cmdletConfigurations.cs b/src/WindowsUpdates/wrapper/WindowsUpdates_cmdletConfigurations.cs new file mode 100644 index 00000000000..7698f87fbb4 --- /dev/null +++ b/src/WindowsUpdates/wrapper/WindowsUpdates_cmdletConfigurations.cs @@ -0,0 +1,3 @@ +using System.Collections.Generic; +namespace WrapperGenerator; +public static partial class CmdletConfigurator { private static readonly List WindowsUpdatesCmdletConfigurations = []; } diff --git a/tools/WrapperGenerator.Tests/DerivedCollisionResolutionsTests.cs b/tools/WrapperGenerator.Tests/DerivedCollisionResolutionsTests.cs index da3a2541194..493cdcdfe70 100644 --- a/tools/WrapperGenerator.Tests/DerivedCollisionResolutionsTests.cs +++ b/tools/WrapperGenerator.Tests/DerivedCollisionResolutionsTests.cs @@ -19,9 +19,9 @@ public sealed class DerivedCollisionResolutionsTests [Fact] public void DerivedSuppressionAppliesOnlyWithDataEnabled() { - Assert.True(NamingOverrides.IsSuppressed(HttpMethod.Get, "/groupSettings", DataOn)); - Assert.False(NamingOverrides.IsSuppressed(HttpMethod.Get, "/groupSettings", DataOff)); - Assert.False(NamingOverrides.IsSuppressed(HttpMethod.Get, "/groupSettings")); + Assert.True(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/groupSettings", DataOn)); + Assert.False(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/groupSettings", DataOff)); + Assert.False(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/groupSettings")); } // Oracle: the nested catalog resourceRoles route ships as @@ -44,7 +44,7 @@ public void DerivedRenameReplacesTheNounVerbatim() [Fact] public void DerivedEntriesAreExactMatchOnly() { - Assert.False(NamingOverrides.IsSuppressed(HttpMethod.Get, "/groupSettings/extra/segment", DataOn)); + Assert.False(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/groupSettings/extra/segment", DataOn)); } // The two deferred cross-path merges (the only ones in all of v1.0): the published SDK @@ -55,6 +55,6 @@ public void DerivedEntriesAreExactMatchOnly() [InlineData("/shares/{sharedDriveItem-id}/list/items")] public void DeferredCrossPathRoutesAreSuppressed(string pathTemplate) { - Assert.True(NamingOverrides.IsSuppressed(HttpMethod.Get, pathTemplate, DataOn)); + Assert.True(CmdletConfigurator.IsSuppressed(HttpMethod.Get, pathTemplate, DataOn)); } } diff --git a/tools/WrapperGenerator.Tests/GenerationServiceRegressionTests.cs b/tools/WrapperGenerator.Tests/GenerationServiceRegressionTests.cs index cd4adb95a1e..a77769db8ae 100644 --- a/tools/WrapperGenerator.Tests/GenerationServiceRegressionTests.cs +++ b/tools/WrapperGenerator.Tests/GenerationServiceRegressionTests.cs @@ -189,7 +189,7 @@ public async Task GenerateAsync_SkipsUnsupportedODataPathSegments_DoesNotEmitMal // Two operations resolving to the same cmdlet file must fail generation loudly, // identifying both operations — never silently overwrite. The real shipped collision - // (/sites/{id}/sites) is renamed via NamingOverrides, so a synthetic self-referential + // (/sites/{id}/sites) is renamed via CmdletConfigurator, so a synthetic self-referential // path keeps the guard itself exercised. [Fact] public async Task GenerateAsync_FailsLoudlyWhenTwoCmdletsResolveToTheSameFile() diff --git a/tools/WrapperGenerator.Tests/NamingTests.cs b/tools/WrapperGenerator.Tests/NamingTests.cs index 2dc2dbdc3a1..446f9ecc7be 100644 --- a/tools/WrapperGenerator.Tests/NamingTests.cs +++ b/tools/WrapperGenerator.Tests/NamingTests.cs @@ -106,7 +106,7 @@ private static CmdletNaming Resolve(string method, string path) => [InlineData("GET", "/domains/{domain-id}", "Get", "MgDomain")] [InlineData("GET", "/groups/{group-id}", "Get", "MgGroup")] [InlineData("GET", "/teams/{team-id}", "Get", "MgTeam")] - // overrides mirroring the SDK's own AutoRest directives (see NamingOverrides) + // configurations mirroring the SDK's own AutoRest directives (see CmdletConfigurator) [InlineData("GET", "/solutions/bookingBusinesses/{bookingBusiness-id}", "Get", "MgBookingBusiness")] [InlineData("PATCH", "/solutions/bookingBusinesses/{bookingBusiness-id}", "Update", "MgBookingBusiness")] [InlineData("GET", "/users/{user-id}/calendar", "Get", "MgUserDefaultCalendar")] @@ -190,43 +190,43 @@ public void SuppressesOperationsThePublishedSdkOmits() { // Calendar.md remove-path-by-operation user_UpdateCalendar: no Update cmdlet ships for // the default-calendar singleton. - Assert.True(NamingOverrides.IsSuppressed(HttpMethod.Patch, "/users/{user-id}/calendar")); - Assert.False(NamingOverrides.IsSuppressed(HttpMethod.Get, "/users/{user-id}/calendar")); - Assert.False(NamingOverrides.IsSuppressed(HttpMethod.Patch, "/users/{user-id}/messages/{message-id}")); + Assert.True(CmdletConfigurator.IsSuppressed(HttpMethod.Patch, "/users/{user-id}/calendar")); + Assert.False(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/users/{user-id}/calendar")); + Assert.False(CmdletConfigurator.IsSuppressed(HttpMethod.Patch, "/users/{user-id}/messages/{message-id}")); // Bookings.md remove-path-by-operation ^solution\.solutionsRoot.*$: the /solutions root // singleton ships no cmdlets, but its children are untouched. - Assert.True(NamingOverrides.IsSuppressed(HttpMethod.Get, "/solutions")); - Assert.True(NamingOverrides.IsSuppressed(HttpMethod.Patch, "/solutions")); - Assert.False(NamingOverrides.IsSuppressed(HttpMethod.Get, "/solutions/bookingBusinesses/{bookingBusiness-id}")); + Assert.True(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/solutions")); + Assert.True(CmdletConfigurator.IsSuppressed(HttpMethod.Patch, "/solutions")); + Assert.False(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/solutions/bookingBusinesses/{bookingBusiness-id}")); // The /photos collection ships no distinct cmdlet; only the /photo singleton does. - Assert.True(NamingOverrides.IsSuppressed(HttpMethod.Get, "/users/{user-id}/photos")); - Assert.True(NamingOverrides.IsSuppressed(HttpMethod.Get, "/users/{user-id}/photos/{userProfilePhoto-id}")); - Assert.False(NamingOverrides.IsSuppressed(HttpMethod.Get, "/users/{user-id}/photo")); + Assert.True(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/users/{user-id}/photos")); + Assert.True(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/users/{user-id}/photos/{userProfilePhoto-id}")); + Assert.False(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/users/{user-id}/photo")); // Suffix-matched suppressions apply under any root; siblings stay generated // (issue #3704: Info-wrapper navs ship nothing, their siblings ship). - Assert.True(NamingOverrides.IsSuppressed(HttpMethod.Get, "/chats/{chat-id}/pinnedMessages/{pinnedChatMessageInfo-id}/message")); - Assert.True(NamingOverrides.IsSuppressed(HttpMethod.Get, "/teams/{team-id}/channels/{channel-id}/sharedWithTeams/{id}/team")); - Assert.False(NamingOverrides.IsSuppressed(HttpMethod.Get, "/teams/{team-id}/channels/{channel-id}/sharedWithTeams/{id}/allowedMembers")); + Assert.True(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/chats/{chat-id}/pinnedMessages/{pinnedChatMessageInfo-id}/message")); + Assert.True(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/teams/{team-id}/channels/{channel-id}/sharedWithTeams/{id}/team")); + Assert.False(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/teams/{team-id}/channels/{channel-id}/sharedWithTeams/{id}/allowedMembers")); // Exact-matched suppressions cover only the named node; descendants with no entry of // their own stay generated (Security nested navs, issue #3704). - Assert.True(NamingOverrides.IsSuppressed(HttpMethod.Get, "/security/threatIntelligence/hosts/{host-id}/components")); - Assert.False(NamingOverrides.IsSuppressed(HttpMethod.Get, "/security/threatIntelligence/hosts/{host-id}/components/$count")); - Assert.False(NamingOverrides.IsSuppressed(HttpMethod.Get, "/security/threatIntelligence/hosts/{host-id}/passiveDns")); + Assert.True(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/security/threatIntelligence/hosts/{host-id}/components")); + Assert.False(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/security/threatIntelligence/hosts/{host-id}/components/$count")); + Assert.False(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/security/threatIntelligence/hosts/{host-id}/passiveDns")); // termStore trees are stitched: /termStores/{id} descendants ship nothing (the 402 // descendant command rows come from the /termStore singleton trees), and the singleton // root GET ships no distinct cmdlet (Get-MgSiteTermStore serves both /termStore and // /termStores; GET generates from the collection side only). - Assert.True(NamingOverrides.IsSuppressed(HttpMethod.Get, "/sites/{site-id}/termStores/{store-id}")); - Assert.True(NamingOverrides.IsSuppressed(HttpMethod.Get, "/sites/{site-id}/termStores/{store-id}/sets/{set-id}")); - Assert.True(NamingOverrides.IsSuppressed(HttpMethod.Get, "/sites/{site-id}/termStore")); - Assert.False(NamingOverrides.IsSuppressed(HttpMethod.Patch, "/sites/{site-id}/termStore")); - Assert.False(NamingOverrides.IsSuppressed(HttpMethod.Get, "/sites/{site-id}/termStores")); - Assert.False(NamingOverrides.IsSuppressed(HttpMethod.Get, "/sites/{site-id}/termStore/sets/{set-id}")); + Assert.True(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/sites/{site-id}/termStores/{store-id}")); + Assert.True(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/sites/{site-id}/termStores/{store-id}/sets/{set-id}")); + Assert.True(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/sites/{site-id}/termStore")); + Assert.False(CmdletConfigurator.IsSuppressed(HttpMethod.Patch, "/sites/{site-id}/termStore")); + Assert.False(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/sites/{site-id}/termStores")); + Assert.False(CmdletConfigurator.IsSuppressed(HttpMethod.Get, "/sites/{site-id}/termStore/sets/{set-id}")); } [Theory] diff --git a/tools/WrapperGenerator/CmdletConfigurator.cs b/tools/WrapperGenerator/CmdletConfigurator.cs new file mode 100644 index 00000000000..b9946792827 --- /dev/null +++ b/tools/WrapperGenerator/CmdletConfigurator.cs @@ -0,0 +1,208 @@ +using System; +using System.Collections.Generic; +using System.Net.Http; +using System.Text.RegularExpressions; + +namespace WrapperGenerator; + +// Matching engine for hand-tuned cmdlet configurations. The cited entries live beside each +// module in src//wrapper/_cmdletConfigurations.cs. +// +// The published Microsoft.Graph names are mostly algorithmic. Module entries cover the rest: +// renames from hand-written AutoRest directives in the msgraph-sdk-powershell module +// configs, and suppressions for spec routes the published SDK ships nothing for. +// +// Add an entry only when the published surface cannot come out of the naming rules, and +// cite the evidence: the directive when one exists, otherwise the shipped-command +// inventory (the oracle, MgCommandMetadata.json). +public static partial class CmdletConfigurator +{ + private enum OverrideKind + { + SuppressOperation, + ReplaceNoun, + StripNounPrefix, + } + + // How Pattern is matched against the normalized path: the full path (Exact), its start + // (Prefix), or its end (Suffix — for navs that recur under many roots, like + // .../resourceRoleScopes/{}/scope appearing under several parents). + private enum PathMatch + { + Exact, + Prefix, + Suffix, + } + + private sealed record Entry(OverrideKind Kind, HttpMethod? Method, string Pattern, PathMatch Match, string? Value, string Reason); + + // NormalizePath lowercases before matching, so a Pattern containing an uppercase letter can + // never match anything: the entry is silently dead and the override looks applied but is not. + // Every pre-existing entry happened to be single-word lowercase, so nothing surfaced this + // until a camelCase path was added. Failing at startup beats debugging a missing rename. + static CmdletConfigurator() + { + var dead = Entries.FindAll(e => e.Pattern != e.Pattern.ToLowerInvariant()); + if (dead.Count > 0) + { + throw new InvalidOperationException( + "CmdletConfigurator pattern(s) contain uppercase and can never match, because paths are " + + "lowercased before comparison: " + string.Join(", ", dead.ConvertAll(e => e.Pattern))); + } + } + + // Static field initialization order is unspecified across partial-class files. Defer + // aggregation until first use so every module collection has been initialized. + private static readonly Lazy> LazyEntries = new(CreateEntries); + + private static List Entries => LazyEntries.Value; + + private static List CreateEntries() => + [ + .. ApplicationsCmdletConfigurations, + .. BackupRestoreCmdletConfigurations, + .. BookingsCmdletConfigurations, + .. BusinessScenarioCmdletConfigurations, + .. CalendarCmdletConfigurations, + .. ChangeNotificationsCmdletConfigurations, + .. CloudCommunicationsCmdletConfigurations, + .. ComplianceCmdletConfigurations, + .. ConfigurationManagementCmdletConfigurations, + .. CrossDeviceExperiencesCmdletConfigurations, + .. DeviceManagementCmdletConfigurations, + .. DeviceManagementAdministrationCmdletConfigurations, + .. DeviceManagementEnrollmentCmdletConfigurations, + .. DeviceManagementFunctionsCmdletConfigurations, + .. DevicesCloudPrintCmdletConfigurations, + .. DevicesCorporateManagementCmdletConfigurations, + .. DevicesServiceAnnouncementCmdletConfigurations, + .. DirectoryObjectsCmdletConfigurations, + .. EducationCmdletConfigurations, + .. FilesCmdletConfigurations, + .. FinancialsCmdletConfigurations, + .. GroupsCmdletConfigurations, + .. IdentityDirectoryManagementCmdletConfigurations, + .. IdentityGovernanceCmdletConfigurations, + .. IdentityPartnerCmdletConfigurations, + .. IdentitySignInsCmdletConfigurations, + .. MailCmdletConfigurations, + .. ManagedTenantsCmdletConfigurations, + .. MigrationsCmdletConfigurations, + .. NetworkAccessCmdletConfigurations, + .. NotesCmdletConfigurations, + .. PeopleCmdletConfigurations, + .. PersonalContactsCmdletConfigurations, + .. PlannerCmdletConfigurations, + .. ReportsCmdletConfigurations, + .. SchemaExtensionsCmdletConfigurations, + .. SearchCmdletConfigurations, + .. SecurityCmdletConfigurations, + .. SitesCmdletConfigurations, + .. TeamsCmdletConfigurations, + .. UsersCmdletConfigurations, + .. UsersActionsCmdletConfigurations, + .. UsersFunctionsCmdletConfigurations, + .. WindowsUpdatesCmdletConfigurations, + ]; + + [GeneratedRegex(@"\{[^}]*\}")] + private static partial Regex PathParamRegex(); + + // Parameter names are erased before comparing, so "/users/{user-id}/calendar" and + // "/users/{id}/calendar" both match the "/users/{}/calendar" module entries. A spec-side + // parameter rename must not silently disable an override. + // An empty argument list is dropped: the spec spells a zero-argument function + // "filterOperators()", while the published inventory records the same operation as + // "/schema/filterOperators" and kiota exposes it as a plain property. Keeping the parentheses + // made a route key that could never match an oracle-derived entry, so every such function + // silently kept its structural name instead of its published one. + private static string NormalizePath(string pathTemplate) => + PathParamRegex().Replace(pathTemplate, "{}").Replace("()", "", StringComparison.Ordinal) + .TrimEnd('/').ToLowerInvariant(); + + // The same normalization, for callers that need to report or key by a route rather than + // match one — the derived data files and the collision diagnostics both use this form, so + // there is one definition of what a route looks like. + public static string NormalizePathTemplate(string pathTemplate) + { + ArgumentNullException.ThrowIfNull(pathTemplate); + return NormalizePath(pathTemplate); + } + + // config carries the API version the derived collision data is keyed by; null (the unit + // tests' default) applies only the curated entries below, so a data-file change can never + // silently shift a pinned naming expectation. + public static bool IsSuppressed(HttpMethod httpMethod, string pathTemplate, GeneratorConfig? config = null) + { + ArgumentNullException.ThrowIfNull(httpMethod); + ArgumentNullException.ThrowIfNull(pathTemplate); + var path = NormalizePath(pathTemplate); + if (config is { UseCollisionData: true } && DerivedCollisionResolutions.IsSuppressed(config.ApiVersion, httpMethod, path)) + return true; + foreach (var entry in Entries) + { + if (entry.Kind == OverrideKind.SuppressOperation && Matches(entry, httpMethod, path)) + return true; + } + return false; + } + + // The published verb for an operation, when the oracle-derived data carries one. Only an + // action or function needs it: CRUD verbs follow from the HTTP method, but an action's verb + // is the SDK's own choice per operation (applyHold ships as Add-, removeHold as Remove-). + public static string? TryGetOverriddenVerb(HttpMethod httpMethod, string pathTemplate, GeneratorConfig? config) + { + ArgumentNullException.ThrowIfNull(httpMethod); + ArgumentNullException.ThrowIfNull(pathTemplate); + return config is { UseCollisionData: true } + && DerivedCollisionResolutions.TryReplaceName(config.ApiVersion, httpMethod, NormalizePath(pathTemplate), out var derived) + ? derived.Verb + : null; + } + + public static string ApplyNounOverrides(HttpMethod httpMethod, string pathTemplate, string noun, GeneratorConfig? config = null) + { + ArgumentNullException.ThrowIfNull(httpMethod); + ArgumentNullException.ThrowIfNull(pathTemplate); + ArgumentNullException.ThrowIfNull(noun); + var path = NormalizePath(pathTemplate); + + // A derived rename is the published noun verbatim; nothing curated may rewrite it. + if (config is { UseCollisionData: true } && DerivedCollisionResolutions.TryReplaceName(config.ApiVersion, httpMethod, path, out var derived)) + return derived.Noun; + + // Published BackupRestore cmdlets retain the Solution prefix (for example, + // Get-MgSolutionBackupRestore). Do not apply /solutions/* strip rules here. + var skipSolutionStrip = path.StartsWith("/solutions/backuprestore", StringComparison.Ordinal); + + foreach (var entry in Entries) + { + if (!Matches(entry, httpMethod, path)) + continue; + switch (entry.Kind) + { + case OverrideKind.ReplaceNoun: + return entry.Value!; + case OverrideKind.StripNounPrefix when skipSolutionStrip: + break; + case OverrideKind.StripNounPrefix when noun.StartsWith(entry.Value!, StringComparison.Ordinal) && noun.Length > entry.Value!.Length: + noun = noun[entry.Value!.Length..]; + break; + } + } + return noun; + } + + private static bool Matches(Entry entry, HttpMethod httpMethod, string normalizedPath) + { + // HttpMethod's own equality is case-insensitive, so no string comparison is needed. + if (entry.Method is not null && entry.Method != httpMethod) + return false; + return entry.Match switch + { + PathMatch.Exact => string.Equals(normalizedPath, entry.Pattern, StringComparison.Ordinal), + PathMatch.Prefix => normalizedPath.StartsWith(entry.Pattern, StringComparison.Ordinal), + _ => normalizedPath.EndsWith(entry.Pattern, StringComparison.Ordinal), + }; + } +} diff --git a/tools/WrapperGenerator/CmdletNaming.cs b/tools/WrapperGenerator/CmdletNaming.cs index c7a07b3dc34..3895e9fe50d 100644 --- a/tools/WrapperGenerator/CmdletNaming.cs +++ b/tools/WrapperGenerator/CmdletNaming.cs @@ -123,7 +123,7 @@ public sealed record CmdletNaming( // PathParamNames. A parameterized function is built by populating kiota's path-parameter // dictionary, which is keyed by these template names, not by the cmdlet parameter names. IReadOnlyList? PathParamTemplateNames = null, - // The operation's route, normalized the way NamingOverrides keys its data. Diagnostics + // The operation's route, normalized the way CmdletConfigurator keys its data. Diagnostics // report it rather than leaving the route to be reconstructed from the builder expression: // that reconstruction is lossy for a function (the builder member keeps the argument names // but not the OData argument syntax) and wrong for a namespace-qualified action (kiota @@ -131,7 +131,7 @@ public sealed record CmdletNaming( // against the wrong oracle row. string NormalizedPath = "", // The operation's route and method exactly as the spec declares them, qualifier and {id} - // template names intact. NormalizedPath cannot serve here: it is the key NamingOverrides + // template names intact. NormalizedPath cannot serve here: it is the key CmdletConfigurator // indexes by, so it is lower-cased and collapses every {id} to {}. These are emitted as a // [GraphRoute] attribute so verification tooling reads the operation's identity out of the // compiled assembly instead of reconstructing it from the builder expression. @@ -172,14 +172,14 @@ public static CmdletNaming Resolve(OperationInfo operation, GeneratorConfig? con // The published SDK picks an action's verb per operation rather than from the method, so // where the oracle-derived data records one it replaces the structural default. - if (NamingOverrides.TryGetOverriddenVerb(operation.HttpMethod, operation.Path, config) is { } publishedVerb) + if (CmdletConfigurator.TryGetOverriddenVerb(operation.HttpMethod, operation.Path, config) is { } publishedVerb) verb = PsVerb.FromApprovedName(publishedVerb); // The noun comes from the URL path, not the operationId. OperationIds keep whatever // plurality the spec author chose, while the published SDK names follow the path: // GET /users/{id}/messages is Get-MgUserMessage. The few hand-tuned exceptions the - // published SDK carries are mirrored as data in NamingOverrides, never as code here. - var noun = GeneratorConstants.NounPrefix + NamingOverrides.ApplyNounOverrides(operation.HttpMethod, operation.Path, BuildNounFromPath(operation.Path, operation.Kind), config); + // published SDK carries are mirrored as data in CmdletConfigurator, never as code here. + var noun = GeneratorConstants.NounPrefix + CmdletConfigurator.ApplyNounOverrides(operation.HttpMethod, operation.Path, BuildNounFromPath(operation.Path, operation.Kind), config); // A list GET (/users/{id}/messages) and its item GET (/users/{id}/messages/{message-id}) // get the same noun on purpose. PowerShellWrapperGenerationService pairs them into one @@ -198,7 +198,7 @@ public static CmdletNaming Resolve(OperationInfo operation, GeneratorConfig? con .Select(raw => new HeaderParam(raw, raw.ToPascalCase('-'))) .ToList(); - var normalizedPath = NamingOverrides.NormalizePathTemplate(operation.Path); + var normalizedPath = CmdletConfigurator.NormalizePathTemplate(operation.Path); if (operation.Kind == OperationKind.Resource) return new CmdletNaming(verb.AttributeClass, verb.Name, noun, className, pathParamNames, builderExpression, headerParams, NormalizedPath: normalizedPath, SourcePath: operation.Path, SourceMethod: operation.HttpMethod.Method); diff --git a/tools/WrapperGenerator/DerivedCollisionResolutions.cs b/tools/WrapperGenerator/DerivedCollisionResolutions.cs index e84672bd5e1..f4238242c2e 100644 --- a/tools/WrapperGenerator/DerivedCollisionResolutions.cs +++ b/tools/WrapperGenerator/DerivedCollisionResolutions.cs @@ -9,14 +9,14 @@ namespace WrapperGenerator; // Collision resolutions DERIVED from the published-command oracle, as opposed to the curated -// judgment entries in NamingOverrides. tools/Derive-CollisionResolutions.ps1 writes the +// judgment entries in CmdletConfigurator. tools/Derive-CollisionResolutions.ps1 writes the // data/collision-*.json files from (collision inventory x MgCommandMetadata.json) and its // -Validate mode fails when the checked-in files drift from a fresh derivation; the files are // embedded at build time so a generation run never reads the 22 MB oracle itself. // // Entries are exact-match only, keyed by API version + HTTP method + normalized URI, and // exist solely for operations that appeared in the collision inventory. Anything broader -// (subtree prunes, cross-path merge picks) is curated in NamingOverrides with a citation. +// (subtree prunes, cross-path merge picks) is curated in CmdletConfigurator with a citation. internal static class DerivedCollisionResolutions { private sealed record DataEntry(string ApiVersion, string Method, string Uri, string Action, string? ReplacementNoun, string? ReplacementVerb); diff --git a/tools/WrapperGenerator/NamingOverrides.cs b/tools/WrapperGenerator/NamingOverrides.cs deleted file mode 100644 index 1f93ab3e0ab..00000000000 --- a/tools/WrapperGenerator/NamingOverrides.cs +++ /dev/null @@ -1,358 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Net.Http; -using System.Text.RegularExpressions; - -namespace WrapperGenerator; - -// Hand-tuned naming exceptions, kept as data with a cited source on every entry. -// -// The published Microsoft.Graph names are mostly algorithmic. Entries here cover the rest: -// renames from hand-written AutoRest directives in the msgraph-sdk-powershell module -// configs, and suppressions for spec routes the published SDK ships nothing for. -// -// Add an entry only when the published surface cannot come out of the naming rules, and -// cite the evidence: the directive when one exists, otherwise the shipped-command -// inventory (the oracle, MgCommandMetadata.json). -public static partial class NamingOverrides -{ - private enum OverrideKind - { - SuppressOperation, - ReplaceNoun, - StripNounPrefix, - } - - // How Pattern is matched against the normalized path: the full path (Exact), its start - // (Prefix), or its end (Suffix — for navs that recur under many roots, like - // .../resourceRoleScopes/{}/scope appearing under several parents). - private enum PathMatch - { - Exact, - Prefix, - Suffix, - } - - private sealed record Entry(OverrideKind Kind, HttpMethod? Method, string Pattern, PathMatch Match, string? Value, string Reason); - - // NormalizePath lowercases before matching, so a Pattern containing an uppercase letter can - // never match anything: the entry is silently dead and the override looks applied but is not. - // Every pre-existing entry happened to be single-word lowercase, so nothing surfaced this - // until a camelCase path was added. Failing at startup beats debugging a missing rename. - static NamingOverrides() - { - var dead = Entries.FindAll(e => e.Pattern != e.Pattern.ToLowerInvariant()); - if (dead.Count > 0) - { - throw new InvalidOperationException( - "NamingOverrides pattern(s) contain uppercase and can never match, because paths are " + - "lowercased before comparison: " + string.Join(", ", dead.ConvertAll(e => e.Pattern))); - } - } - - private static readonly List Entries = - [ - // The SDK ships no Update cmdlet for /users/{id}/calendar. Its pipeline removes the - // operation outright, in src/Calendar/Calendar.md: remove-path-by-operation - // user_UpdateCalendar. The wrapper must not invent a cmdlet the SDK chose to drop. - new(OverrideKind.SuppressOperation, HttpMethod.Patch, "/users/{}/calendar", Match: PathMatch.Exact, Value: null, - Reason: "Calendar.md remove-path-by-operation user_UpdateCalendar"), - - // GET /users/{id}/calendar ships as Get-MgUserDefaultCalendar, renamed in - // src/Calendar/Calendar.md: "^(User)(Calendar)$" -> "$1Default$2". - new(OverrideKind.ReplaceNoun, HttpMethod.Get, "/users/{}/calendar", Match: PathMatch.Exact, Value: "UserDefaultCalendar", - Reason: "Calendar.md directive renames UserCalendar to UserDefaultCalendar"), - - // The SDK ships no cmdlets for the /solutions root singleton itself (Get-MgSolution / - // Update-MgSolution do not exist): src/Bookings/Bookings.md removes every solutionsRoot - // operation with remove-path-by-operation ^solution\.solutionsRoot.*$. Exact-path, all - // methods, so operations on children like /solutions/bookingBusinesses are unaffected. - new(OverrideKind.SuppressOperation, Method: null, "/solutions", Match: PathMatch.Exact, Value: null, - Reason: "Bookings.md remove-path-by-operation ^solution\\.solutionsRoot.*$"), - - // Most nouns under /solutions/ drop the "Solution" prefix (for example - // Get-MgBookingBusiness, Get-MgVirtualEventWebinar). BackupRestore is a known - // exception where published cmdlets keep the Solution prefix. - new(OverrideKind.StripNounPrefix, Method: null, "/solutions/", Match: PathMatch.Prefix, Value: "Solution", - Reason: "Bookings/VirtualEvents naming pattern under /solutions/*; BackupRestore is explicitly excluded in ApplyNounOverrides"), - - // The spec carries two parallel termStore trees; the shipped surface stitches them: - // GET/POST come from the /termStores collection (Get-MgSiteTermStore, New-...), while - // PATCH/DELETE and all 402 descendant command rows come from the /termStore singleton. - // Nothing ships under /termStores/{id}, and the singleton root GET has no distinct - // cmdlet — generating either would collide with its shipped twin. - new(OverrideKind.SuppressOperation, Method: null, "/sites/{}/termstores/{}", Match: PathMatch.Prefix, Value: null, - Reason: "oracle: zero commands under /termStores/{id}; descendants ship from the /termStore singleton tree"), - new(OverrideKind.SuppressOperation, HttpMethod.Get, "/sites/{}/termstore", Match: PathMatch.Exact, Value: null, - Reason: "oracle: Get-MgSiteTermStore serves GET /termStore and /termStores; GET generates from the collection side only"), - new(OverrideKind.SuppressOperation, Method: null, "/groups/{}/sites/{}/termstores/{}", Match: PathMatch.Prefix, Value: null, - Reason: "oracle: zero commands under /termStores/{id}; descendants ship from the /termStore singleton tree"), - new(OverrideKind.SuppressOperation, HttpMethod.Get, "/groups/{}/sites/{}/termstore", Match: PathMatch.Exact, Value: null, - Reason: "oracle: Get-MgGroupSiteTermStore serves GET /termStore and /termStores; GET generates from the collection side only"), - - // Get-MgUserPhoto serves both /photo and /photos; the /photos routes ship no distinct - // cmdlet, and generating them would collide with the singleton's noun. - new(OverrideKind.SuppressOperation, Method: null, "/users/{}/photos", Match: PathMatch.Exact, Value: null, - Reason: "oracle: Get-MgUserPhoto serves /photo and /photos; the collection ships no distinct cmdlet"), - new(OverrideKind.SuppressOperation, Method: null, "/users/{}/photos/{}", Match: PathMatch.Exact, Value: null, - Reason: "oracle: /photos/{} ships nothing; the photo surface is the /photo singleton"), - - // Self-referential /sites: singularizing sites/{id}/sites collapses to the parent's - // noun, so the sub-sites cmdlets would overwrite Get-MgSite. The SDK ships them - // renamed: Get-MgSubSite and Get-MgGroupSubSite (v1.0 and beta, incl. $count). - new(OverrideKind.ReplaceNoun, Method: null, "/sites/{}/sites", Match: PathMatch.Exact, Value: "SubSite", - Reason: "Sites.md directive; oracle ships Get-MgSubSite for /sites/{site-id}/sites"), - new(OverrideKind.ReplaceNoun, Method: null, "/sites/{}/sites/{}", Match: PathMatch.Exact, Value: "SubSite", - Reason: "Sites.md directive; oracle ships Get-MgSubSite for /sites/{site-id}/sites/{site-id1}"), - new(OverrideKind.ReplaceNoun, Method: null, "/groups/{}/sites/{}/sites", Match: PathMatch.Exact, Value: "GroupSubSite", - Reason: "Sites.md directive; oracle ships Get-MgGroupSubSite"), - new(OverrideKind.ReplaceNoun, Method: null, "/groups/{}/sites/{}/sites/{}", Match: PathMatch.Exact, Value: "GroupSubSite", - Reason: "Sites.md directive; oracle ships Get-MgGroupSubSite"), - - // ---- Naming-parity sweep (2026-08-13): the two rules the sweep proved safe. ---- - // - // Both were measured against the whole corpus first: each fixes real mismatches and - // rewrites no currently-matching name. Every other candidate rule from that sweep broke - // more names than it fixed (dropping "IdentityGovernance" would have fixed 297 and broken - // 417), which is why only these two are here and the rest await oracle-derived naming. - - // "people" is singularized everywhere else and correctly so - /users/{}/people ships as - // Get-MgUserPerson. Under /admin/people the published SDK keeps the plural, so this is - // scoped per path rather than by making "people" invariant, which would break UserPerson. - new(OverrideKind.ReplaceNoun, Method: null, "/admin/people", Match: PathMatch.Exact, Value: "AdminPeople", - Reason: "oracle ships Get-MgAdminPeople; /admin/people keeps the plural"), - new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/iteminsights", Match: PathMatch.Exact, Value: "AdminPeopleItemInsight", - Reason: "oracle ships Get-MgAdminPeopleItemInsight"), - new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/profilecardproperties", Match: PathMatch.Exact, Value: "AdminPeopleProfileCardProperty", - Reason: "oracle ships Get-MgAdminPeopleProfileCardProperty"), - new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/profilecardproperties/{}", Match: PathMatch.Exact, Value: "AdminPeopleProfileCardProperty", - Reason: "oracle ships Get-MgAdminPeopleProfileCardProperty"), - new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/profilepropertysettings", Match: PathMatch.Exact, Value: "AdminPeopleProfilePropertySetting", - Reason: "oracle ships Get-MgAdminPeopleProfilePropertySetting"), - new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/profilepropertysettings/{}", Match: PathMatch.Exact, Value: "AdminPeopleProfilePropertySetting", - Reason: "oracle ships Get-MgAdminPeopleProfilePropertySetting"), - new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/profilesources", Match: PathMatch.Exact, Value: "AdminPeopleProfileSource", - Reason: "oracle ships Get-MgAdminPeopleProfileSource"), - new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/profilesources/{}", Match: PathMatch.Exact, Value: "AdminPeopleProfileSource", - Reason: "oracle ships Get-MgAdminPeopleProfileSource"), - new(OverrideKind.ReplaceNoun, Method: null, "/admin/people/pronouns", Match: PathMatch.Exact, Value: "AdminPeoplePronoun", - Reason: "oracle ships Get-MgAdminPeoplePronoun"), - - // The resource repeats its parent's name, so segment-joining yields - // DeviceManagementDeviceManagementPartner. The published SDK collapses the repetition. - new(OverrideKind.ReplaceNoun, Method: null, "/devicemanagement/devicemanagementpartners", Match: PathMatch.Exact, Value: "DeviceManagementPartner", - Reason: "oracle ships Get-MgDeviceManagementPartner, not ...DeviceManagementDeviceManagementPartner"), - new(OverrideKind.ReplaceNoun, Method: null, "/devicemanagement/devicemanagementpartners/{}", Match: PathMatch.Exact, Value: "DeviceManagementPartner", - Reason: "oracle ships Get-MgDeviceManagementPartner"), - - // ---- Collision resolutions from the full-inventory oracle sweep (issue #3704). ---- - - // Identity.Governance: agreement file item ops ship only from the /file singleton - // (Update/Remove-MgAgreementFile); /files/{} items ship nothing, /files/{}/versions does. - new(OverrideKind.SuppressOperation, Method: null, "/agreements/{}/files/{}", Match: PathMatch.Exact, Value: null, - Reason: "oracle: /files/{} item ops ship nothing; file surface is the /file singleton (Update/Remove-MgAgreementFile)"), - new(OverrideKind.SuppressOperation, Method: null, "/identitygovernance/termsofuse/agreements/{}/files/{}", Match: PathMatch.Exact, Value: null, - Reason: "oracle: ships nothing; mirrors /agreements/{}/files/{} suppression"), - // GET of the file/files pair ships from the collection (same command on both URIs), - // like the termStore root stitch; Update/Remove stay on the singleton. - new(OverrideKind.SuppressOperation, HttpMethod.Get, "/agreements/{}/file", Match: PathMatch.Exact, Value: null, - Reason: "oracle: Get-MgAgreementFile serves /file and /files; GET generated from the collection side only"), - new(OverrideKind.SuppressOperation, HttpMethod.Get, "/identitygovernance/termsofuse/agreements/{}/file", Match: PathMatch.Exact, Value: null, - Reason: "oracle: Get-MgIdentityGovernanceTermsOfUseAgreementFile serves /file and /files; GET from the collection side only"), - // The /scope node duplicates its parent's noun and ships nothing anywhere; its - // children ship with the Scope segment elided (…ResourceRoleScopeResource). - new(OverrideKind.SuppressOperation, Method: null, "/resourcerolescopes/{}/scope", Match: PathMatch.Suffix, Value: null, - Reason: "oracle: the /scope node ships nothing under any parent; children ship with Scope elided"), - new(OverrideKind.SuppressOperation, Method: null, "/identitygovernance/entitlementmanagement/assignments/{}/assignmentpolicy", Match: PathMatch.Exact, Value: null, - Reason: "nav duplicate of /assignmentPolicies (Get-MgEntitlementManagementAssignmentPolicy); ships nothing"), - new(OverrideKind.SuppressOperation, Method: null, "/identitygovernance/entitlementmanagement/resources/{}/environment", Match: PathMatch.Exact, Value: null, - Reason: "nav duplicate of /resourceEnvironments (Get-MgEntitlementManagementResourceEnvironment); ships nothing"), - new(OverrideKind.SuppressOperation, Method: null, "/identitygovernance/lifecycleworkflows", Match: PathMatch.Exact, Value: null, - Reason: "the container node's own operations ship nothing; its children ship"), - new(OverrideKind.SuppressOperation, Method: null, "/identitygovernance/termsofuse/agreements/{}/acceptances", Match: PathMatch.Prefix, Value: null, - Reason: "ships nothing; acceptances ship from /termsOfUse/agreementAcceptances (Get-MgIdentityGovernanceTermsOfUseAgreementAcceptance)"), - - // Security threatIntelligence: nested navs under articles/{} and hosts/{} duplicate - // the shipped top-level sets (articleIndicators, hostComponents, hostCookies, - // hostPairs, hostPorts, hostSslCertificates, hostTrackers) and ship nothing - // themselves. Exact-only: two of these navs have shipped $count children - // (Get-MgSecurityThreatIntelligenceHost{SslCertificate,Tracker}Count); the other five - // ship no children at all. - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/articles/{}/indicators", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level articleIndicators ships"), - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/articles/{}/indicators/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level articleIndicators ships"), - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/components", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostComponents ships"), - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/components/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostComponents ships"), - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/cookies", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostCookies ships"), - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/cookies/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostCookies ships"), - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/hostpairs", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostPairs ships"), - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/hostpairs/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostPairs ships"), - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/ports", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostPorts ships"), - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/ports/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostPorts ships"), - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/sslcertificates", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostSslCertificates ships"), - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/sslcertificates/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostSslCertificates ships"), - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/trackers", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostTrackers ships"), - new(OverrideKind.SuppressOperation, Method: null, "/security/threatintelligence/hosts/{}/trackers/{}", Match: PathMatch.Exact, Value: null, Reason: "oracle: ships nothing; top-level hostTrackers ships"), - // The attackSimulation container node itself ships nothing; children under a - // simulation item ship nothing either (the list/item pair then merges normally). - new(OverrideKind.SuppressOperation, Method: null, "/security/attacksimulation", Match: PathMatch.Exact, Value: null, - Reason: "oracle: the container node ships nothing; its child collections ship"), - new(OverrideKind.SuppressOperation, Method: null, "/security/attacksimulation/simulations/{}/", Match: PathMatch.Prefix, Value: null, - Reason: "oracle: nothing under a simulation item ships in v1.0"), - - // Calendar: the shipped default-calendar surface. Events under a NAMED calendar and - // the default-calendar event item tree ship nothing; event items ship from - // /users/{}/events (Get-MgUserEvent family). - new(OverrideKind.ReplaceNoun, Method: null, "/users/{}/calendar/events", Match: PathMatch.Exact, Value: "UserDefaultCalendarEvent", - Reason: "oracle: list/create ship as Get/New-MgUserDefaultCalendarEvent"), - new(OverrideKind.SuppressOperation, Method: null, "/users/{}/calendar/events/{}", Match: PathMatch.Prefix, Value: null, - Reason: "oracle: default-calendar event items ship nothing; items ship from /users/{}/events/{}"), - new(OverrideKind.SuppressOperation, Method: null, "/users/{}/calendars/{}/events/{}", Match: PathMatch.Prefix, Value: null, - Reason: "oracle: named-calendar event items ship nothing; items ship from /users/{}/events/{}"), - new(OverrideKind.SuppressOperation, Method: null, "/users/{}/calendars/{}/calendarpermissions", Match: PathMatch.Prefix, Value: null, - Reason: "oracle: permissions ship only from the default calendar (Get-MgUserCalendarPermission on /users/{}/calendar/calendarPermissions)"), - - // Teams Info-wrapper navs: the wrapped single-entity navigation ships nothing under - // any root. The suffix matches just the nav node, so shipped siblings - // (…SharedWithTeamAllowedMember) are unaffected. - new(OverrideKind.SuppressOperation, Method: null, "/pinnedmessages/{}/message", Match: PathMatch.Suffix, Value: null, - Reason: "oracle: ships nothing under any root; list side ships (Get-MgChatPinnedMessage)"), - new(OverrideKind.SuppressOperation, Method: null, "/sharedwithteams/{}/team", Match: PathMatch.Suffix, Value: null, - Reason: "oracle: ships nothing; sibling /allowedMembers ships, so node-only"), - new(OverrideKind.SuppressOperation, Method: null, "/associatedteams/{}/team", Match: PathMatch.Suffix, Value: null, - Reason: "oracle: ships nothing; list side ships (Get-MgUserTeamworkAssociatedTeam)"), - - // Groups: the nested lifecycle-policies GET ships renamed; everything else on that - // route ships from the top-level set. Photos items ship nothing (singleton /photo). - new(OverrideKind.ReplaceNoun, HttpMethod.Get, "/groups/{}/grouplifecyclepolicies", Match: PathMatch.Exact, Value: "GroupLifecyclePolicyByGroup", - Reason: "Groups.md directive (subject $1ByGroup); oracle ships Get-MgGroupLifecyclePolicyByGroup"), - new(OverrideKind.SuppressOperation, Method: null, "/groups/{}/grouplifecyclepolicies/", Match: PathMatch.Prefix, Value: null, - Reason: "oracle: item/children under the nested route ship nothing; the set ships top-level"), - new(OverrideKind.SuppressOperation, Method: null, "/groups/{}/photos/{}", Match: PathMatch.Exact, Value: null, - Reason: "oracle: photos items ship nothing; shipped surface is the /photo singleton (Get-MgGroupPhoto)"), - - // Small-module resolutions. - new(OverrideKind.SuppressOperation, Method: null, "/solutions/virtualevents", Match: PathMatch.Exact, Value: null, - Reason: "oracle: the virtualEvents root node ships nothing; children ship (Get-MgVirtualEventWebinar)"), - new(OverrideKind.SuppressOperation, Method: null, "/replies/{}/replyto", Match: PathMatch.Suffix, Value: null, - Reason: "oracle: the replyTo nav ships nothing under any root"), - new(OverrideKind.SuppressOperation, Method: null, "/deviceappmanagement/mobileapps/{}/categories", Match: PathMatch.Prefix, Value: null, - Reason: "oracle: nested app categories ship nothing; the set ships top-level (mobileAppCategories)"), - new(OverrideKind.SuppressOperation, Method: null, "/education/classes/{}/assignments/{}/categories", Match: PathMatch.Exact, Value: null, - Reason: "oracle: the plain path ships nothing; the shipped surface is the $ref route"), - new(OverrideKind.SuppressOperation, Method: null, "/education/users/{}/user", Match: PathMatch.Exact, Value: null, - Reason: "oracle: the user self-nav node ships nothing; its children (mailboxSettings) ship"), - new(OverrideKind.ReplaceNoun, HttpMethod.Get, "/groups/{}/drive", Match: PathMatch.Exact, Value: "GroupDefaultDrive", - Reason: "Files.md directive (subject $1Default$2); oracle ships Get-MgGroupDefaultDrive"), - new(OverrideKind.ReplaceNoun, HttpMethod.Get, "/users/{}/drive", Match: PathMatch.Exact, Value: "UserDefaultDrive", - Reason: "Files.md directive (subject $1Default$2); oracle ships Get-MgUserDefaultDrive"), - new(OverrideKind.ReplaceNoun, HttpMethod.Get, "/sites/{}/drive", Match: PathMatch.Exact, Value: "SiteDefaultDrive", - Reason: "oracle ships Get-MgSiteDefaultDrive for the site default-drive singleton"), - new(OverrideKind.ReplaceNoun, HttpMethod.Get, "/groups/{}/sites/{}/drive", Match: PathMatch.Exact, Value: "GroupSiteDefaultDrive", - Reason: "oracle ships Get-MgGroupSiteDefaultDrive"), - new(OverrideKind.SuppressOperation, HttpMethod.Get, "/shares/{}/list/items/{}", Match: PathMatch.Exact, Value: null, - Reason: "oracle: the bare shared-list item GET ships nothing; its descendants ship"), - new(OverrideKind.SuppressOperation, Method: null, "/identityproviders", Match: PathMatch.Prefix, Value: null, - Reason: "oracle: the deprecated top-level /identityProviders set ships nothing in v1.0; shipped surface is /identity/identityProviders (Get-MgIdentityProvider)"), - ]; - - [GeneratedRegex(@"\{[^}]*\}")] - private static partial Regex PathParamRegex(); - - // Parameter names are erased before comparing, so "/users/{user-id}/calendar" and - // "/users/{id}/calendar" both match the "/users/{}/calendar" entries above. A spec-side - // parameter rename must not silently disable an override. - // An empty argument list is dropped: the spec spells a zero-argument function - // "filterOperators()", while the published inventory records the same operation as - // "/schema/filterOperators" and kiota exposes it as a plain property. Keeping the parentheses - // made a route key that could never match an oracle-derived entry, so every such function - // silently kept its structural name instead of its published one. - private static string NormalizePath(string pathTemplate) => - PathParamRegex().Replace(pathTemplate, "{}").Replace("()", "", StringComparison.Ordinal) - .TrimEnd('/').ToLowerInvariant(); - - // The same normalization, for callers that need to report or key by a route rather than - // match one — the derived data files and the collision diagnostics both use this form, so - // there is one definition of what a route looks like. - public static string NormalizePathTemplate(string pathTemplate) - { - ArgumentNullException.ThrowIfNull(pathTemplate); - return NormalizePath(pathTemplate); - } - - // config carries the API version the derived collision data is keyed by; null (the unit - // tests' default) applies only the curated entries below, so a data-file change can never - // silently shift a pinned naming expectation. - public static bool IsSuppressed(HttpMethod httpMethod, string pathTemplate, GeneratorConfig? config = null) - { - ArgumentNullException.ThrowIfNull(httpMethod); - ArgumentNullException.ThrowIfNull(pathTemplate); - var path = NormalizePath(pathTemplate); - if (config is { UseCollisionData: true } && DerivedCollisionResolutions.IsSuppressed(config.ApiVersion, httpMethod, path)) - return true; - foreach (var entry in Entries) - { - if (entry.Kind == OverrideKind.SuppressOperation && Matches(entry, httpMethod, path)) - return true; - } - return false; - } - - // The published verb for an operation, when the oracle-derived data carries one. Only an - // action or function needs it: CRUD verbs follow from the HTTP method, but an action's verb - // is the SDK's own choice per operation (applyHold ships as Add-, removeHold as Remove-). - public static string? TryGetOverriddenVerb(HttpMethod httpMethod, string pathTemplate, GeneratorConfig? config) - { - ArgumentNullException.ThrowIfNull(httpMethod); - ArgumentNullException.ThrowIfNull(pathTemplate); - return config is { UseCollisionData: true } - && DerivedCollisionResolutions.TryReplaceName(config.ApiVersion, httpMethod, NormalizePath(pathTemplate), out var derived) - ? derived.Verb - : null; - } - - public static string ApplyNounOverrides(HttpMethod httpMethod, string pathTemplate, string noun, GeneratorConfig? config = null) - { - ArgumentNullException.ThrowIfNull(httpMethod); - ArgumentNullException.ThrowIfNull(pathTemplate); - ArgumentNullException.ThrowIfNull(noun); - var path = NormalizePath(pathTemplate); - - // A derived rename is the published noun verbatim; nothing curated may rewrite it. - if (config is { UseCollisionData: true } && DerivedCollisionResolutions.TryReplaceName(config.ApiVersion, httpMethod, path, out var derived)) - return derived.Noun; - - // Published BackupRestore cmdlets retain the Solution prefix (for example, - // Get-MgSolutionBackupRestore). Do not apply /solutions/* strip rules here. - var skipSolutionStrip = path.StartsWith("/solutions/backuprestore", StringComparison.Ordinal); - - foreach (var entry in Entries) - { - if (!Matches(entry, httpMethod, path)) - continue; - switch (entry.Kind) - { - case OverrideKind.ReplaceNoun: - return entry.Value!; - case OverrideKind.StripNounPrefix when skipSolutionStrip: - break; - case OverrideKind.StripNounPrefix when noun.StartsWith(entry.Value!, StringComparison.Ordinal) && noun.Length > entry.Value!.Length: - noun = noun[entry.Value!.Length..]; - break; - } - } - return noun; - } - - private static bool Matches(Entry entry, HttpMethod httpMethod, string normalizedPath) - { - // HttpMethod's own equality is case-insensitive, so no string comparison is needed. - if (entry.Method is not null && entry.Method != httpMethod) - return false; - return entry.Match switch - { - PathMatch.Exact => string.Equals(normalizedPath, entry.Pattern, StringComparison.Ordinal), - PathMatch.Prefix => normalizedPath.StartsWith(entry.Pattern, StringComparison.Ordinal), - _ => normalizedPath.EndsWith(entry.Pattern, StringComparison.Ordinal), - }; - } -} diff --git a/tools/WrapperGenerator/PowerShellWrapperGenerationService.cs b/tools/WrapperGenerator/PowerShellWrapperGenerationService.cs index 81afca2838d..e4e0d6b41b6 100644 --- a/tools/WrapperGenerator/PowerShellWrapperGenerationService.cs +++ b/tools/WrapperGenerator/PowerShellWrapperGenerationService.cs @@ -183,9 +183,9 @@ public async Task GenerateAsync(CancellationToken cancellationToken) continue; } - // Skip operations the published SDK deliberately does not ship. NamingOverrides + // Skip operations the published SDK deliberately does not ship. CmdletConfigurator // holds the citation for each one. - if (NamingOverrides.IsSuppressed(httpMethod, pathTemplate, config)) + if (CmdletConfigurator.IsSuppressed(httpMethod, pathTemplate, config)) { LogSuppressedOperation(httpMethod.Method, pathTemplate); continue; @@ -354,7 +354,7 @@ public async Task GenerateAsync(CancellationToken cancellationToken) if (config.UseCollisionData) { throw new InvalidOperationException( - $"{summary} Resolve each with a NamingOverrides rename or suppression.\n " + string.Join("\n ", fileCollisions)); + $"{summary} Resolve each with a CmdletConfigurator rename or suppression.\n " + string.Join("\n ", fileCollisions)); } LogRawCollisionInventory(summary, string.Join("\n ", fileCollisions)); @@ -542,7 +542,7 @@ private async Task WriteCmdletFileAsync(CmdletNaming naming, string source, private partial void LogWroteCmdletFile(string fileName, string verb, string noun); [LoggerMessage(Level = LogLevel.Information, Message = "Wrote {Count} file(s) to {OutputPath}")] private partial void LogWroteFiles(int count, string outputPath); - [LoggerMessage(Level = LogLevel.Information, Message = "Suppressed {Method} {PathTemplate}: the published SDK ships no cmdlet for it (see NamingOverrides)")] + [LoggerMessage(Level = LogLevel.Information, Message = "Suppressed {Method} {PathTemplate}: the published SDK ships no cmdlet for it (see CmdletConfigurator)")] private partial void LogSuppressedOperation(string method, string pathTemplate); [LoggerMessage(Level = LogLevel.Warning, Message = "Skipped {Method} {PathTemplate}: {Reason}")] private partial void LogSkippedUnsupportedOperation(string method, string pathTemplate, string reason); diff --git a/tools/WrapperGenerator/README.md b/tools/WrapperGenerator/README.md index 974bdc6c462..c398ec0e590 100644 --- a/tools/WrapperGenerator/README.md +++ b/tools/WrapperGenerator/README.md @@ -52,7 +52,7 @@ Singularization runs per camel-case word (so `termsAndConditions` → `TermAndCo | ends in `ss`/`us`/`is` stays | `Access`, `Status`, `Analysis` | | trailing `s` drops | `Messages` → `Message` | -A few published names aren't algorithmic, and the spec publishes some routes the SDK never shipped. Both live as data in `NamingOverrides.cs` — renames mirroring the SDK's hand-written AutoRest directives, and suppressions for routes that ship nothing — each entry citing its evidence: the directive when one exists, otherwise the shipped-command inventory. Examples: the `GET /users/{id}/calendar` rename to `…UserDefaultCalendar` (Calendar.md), the `Solution` prefix strip under `/solutions/*` with the BackupRestore exception (Bookings.md), and the self-referential `sites/{id}/sites` rename to `SubSite`/`GroupSubSite` (Sites.md) — without which the sub-sites cmdlets would collide with `Get-MgSite` itself. The generator fails loudly on any such file collision rather than silently overwriting. +A few published names aren't algorithmic, and the spec publishes some routes the SDK never shipped. `CmdletConfigurator.cs` contains the shared matching engine, while each module owns its curated data in `src\\wrapper\_cmdletConfigurations.cs` — renames mirroring the SDK's hand-written AutoRest directives, and suppressions for routes that ship nothing — with every entry citing its evidence: the directive when one exists, otherwise the shipped-command inventory. Module ownership is organizational; all configured entries are compiled into the generator and matched globally. Examples: the `GET /users/{id}/calendar` rename to `…UserDefaultCalendar` (Calendar.md), the `Solution` prefix strip under `/solutions/*` with the BackupRestore exception (Bookings.md), and the self-referential `sites/{id}/sites` rename to `SubSite`/`GroupSubSite` (Sites.md) — without which the sub-sites cmdlets would collide with `Get-MgSite` itself. The generator fails loudly on any such file collision rather than silently overwriting. On top of the curated entries sits a **derived** layer: `tools/Derive-CollisionResolutions.ps1` replays every route from the checked-in collision inventory (`data/collision-inventory.v1.0.txt`, captured with `--no-collision-data`) against the shipped-command inventory and emits `data/collision-suppressions.v1.0.json` and `data/collision-renames.v1.0.json` — one exact-match entry per contested method+route, each carrying its oracle evidence. The files are embedded into the generator at build time (generation never reads the 22 MB oracle), applied only when `GeneratorConfig.UseCollisionData` is set, and the script's `-Validate` mode fails if the checked-in files drift from a fresh derivation. Two routes in all of v1.0 are **deferred cross-path merges** — the published SDK serves `Get-MgGroupPhoto` from both `/photo` and `/photos`, and `Get-MgShareListItem` from both `/listItem` and `/list/items`, as parameter-set variants of one cmdlet; the generator keeps the singleton side and suppresses the collection side until cross-path parameter sets land (see [docs/edge-cases/crosspath-merge-edge-cases.md](docs/edge-cases/crosspath-merge-edge-cases.md)). With the derived data applied, a full v1.0 generation across all 38 configured modules produces zero collisions. @@ -225,7 +225,8 @@ gate set, in order and with a population reported per gate, is `.\tools\Invoke-W | `PowerShellWrapperGenerationService.cs` | The orchestrator: walks the paths, pairs list/item GETs, writes the files | | `CmdletNaming.cs` | Verb + noun + the `client.X[Y].Z` request chain | | `Singularizer.cs` | The per-word singularization rules | -| `NamingOverrides.cs` | Cited rename/suppression data mirroring the shipped SDK surface | +| `CmdletConfigurator.cs` | Shared matching engine for curated cmdlet renames and suppressions | +| `src\\wrapper\_cmdletConfigurations.cs` | Module-owned cited rename/suppression data mirroring the shipped SDK surface | | `CmdletEmitter.cs` | The C# templates for each cmdlet shape (the actual code text) | | `SchemaProperties.cs` | Which body properties become `New`/`Update` parameters | | `OperationInfo.cs`, `EmitContext.cs`, `GeneratorConfig.cs` | Small data/config carriers | @@ -370,7 +371,7 @@ The generated cmdlets **are** compiled: `Build-WrapperModule.ps1` builds each mo - **The runtime base exists; the polish around it does not.** `src/GraphWrapperRuntime/` ships `GraphClientCmdlet` with session-keyed request adapters over the shipped Authentication module's session, `-AccessToken` support, paging with a truncation warning and `-All`, delta-link validation against the session's service root, Ctrl+C cancellation, and one `GraphRequestFailed` error shape. Still open: per-cmdlet help and examples, a `SupportsShouldProcess` audit on destructive cmdlets, and an automated Windows PowerShell 5.1 gate leg (the dll targets it; the gates run on PowerShell 7 only). - **Body binding covers every shape reaching the classifier** — the omission oracle reports 0 failures across 2,235 body-writing cmdlets (24,003 members seen, 15,838 bound). That is a statement about the operations that generate, not about v1.0: see the coverage figure below. Classifications for shapes that do not occur (inline objects and enums, genuine unions, dictionaries, unresolvable references, unknown formats) are retained so a future corpus change is reported rather than silently mis-bound; [docs/edge-cases/body-binding-edge-cases.md](docs/edge-cases/body-binding-edge-cases.md) records each with its exit criteria. - **73.6% of v1.0 operations generate, deliberately.** Of 14,115 operations across the 38 specs (the DirectoryObjects re-slice removes the 16 publicKeyInfrastructure operations it double-declared with Identity.DirectoryManagement): 10,385 become cmdlets, 3,173 are suppressed because the published SDK ships no cmdlet for them (oracle-derived), and 557 are unsupported — 345 call segments on operations the spec does not class as an action or function, 125 routes that call a parameterized function before their final segment, 42 whose content response is neither a stream nor a resolvable entity, 24 with no wrapper emitter for the HTTP method, 13 OData parameter aliases, 6 unresolvable collection schemas, 2 missing request schemas. The three populations sum to 14,115 by construction. The rise from 61.3% is the OData `$`-segments — `$count`, `$ref` and `$value` were 2,304 unsupported operations and now have emitters of their own — plus PUT and the media/content downloads. -- **Naming parity: every generated cmdlet is now compared.** The generator stamps each emitted class with a `[GraphRoute(method, path)]` attribute carrying the operation's route exactly as the spec declares it, and the gate reads that attribute out of the module's **compiled assembly**. Nothing is excluded: of 12,355 cmdlet files on the refreshed corpus, 9,537 match, 1,431 are GET dispatchers verified through their `_List`/`_Get` workers, 396 mismatch, 985 have no oracle row (new surface from the late-August docs refresh), and 6 are documented deliberate corrections. Numbers in this file are snapshots; the ledger is the authority — regenerate it any time with `Compare-WrapperCmdletNames.ps1 -GeneratedPath src\\wrapper\v1.0\Cmdlets -OutLedger ` per module. Before this the gate reconstructed the route from the generated C#, which cannot work for a parameterized function (the builder member keeps the argument names but not the OData argument syntax) or a namespace-qualified action (kiota keeps the qualifier, the route does not) — so it excluded **1,669 cmdlets** from comparison and reported them as skipped. Those names were never wrong-free; they were unexamined. Renames and suppressions are derived from the oracle by `tools/Derive-ParityResolutions.ps1` — data, not rules — alongside a small curated set in `NamingOverrides.cs` and the comparer's deliberate-corrections table, each entry cited. A derived rename carries the published **verb** as well as the noun, because the SDK chooses an action's verb per operation (`sendMail` ships `Send-`, `checkMemberGroups` ships `Confirm-`, and `applyHold`/`removeHold` share one noun and differ only by verb). +- **Naming parity: every generated cmdlet is now compared.** The generator stamps each emitted class with a `[GraphRoute(method, path)]` attribute carrying the operation's route exactly as the spec declares it, and the gate reads that attribute out of the module's **compiled assembly**. Nothing is excluded: of 12,355 cmdlet files on the refreshed corpus, 9,537 match, 1,431 are GET dispatchers verified through their `_List`/`_Get` workers, 396 mismatch, 985 have no oracle row (new surface from the late-August docs refresh), and 6 are documented deliberate corrections. Numbers in this file are snapshots; the ledger is the authority — regenerate it any time with `Compare-WrapperCmdletNames.ps1 -GeneratedPath src\\wrapper\v1.0\Cmdlets -OutLedger ` per module. Before this the gate reconstructed the route from the generated C#, which cannot work for a parameterized function (the builder member keeps the argument names but not the OData argument syntax) or a namespace-qualified action (kiota keeps the qualifier, the route does not) — so it excluded **1,669 cmdlets** from comparison and reported them as skipped. Those names were never wrong-free; they were unexamined. Renames and suppressions are derived from the oracle by `tools/Derive-ParityResolutions.ps1` — data, not rules — alongside the small curated per-module sets consumed by `CmdletConfigurator` and the comparer's deliberate-corrections table, each entry cited. A derived rename carries the published **verb** as well as the noun, because the SDK chooses an action's verb per operation (`sendMail` ships `Send-`, `checkMemberGroups` ships `Confirm-`, and `applyHold`/`removeHold` share one noun and differ only by verb). - **The 362 unresolved name mismatches fall into six families**, measured from the ledger on the refreshed corpus. Five resolve as derived-data updates (extend the parity derivation to cover the pattern); none require generator code changes; the last is a decision to make, not a bug to fix. | Family | Count | Example (generated vs published) | Resolution path | diff --git a/tools/WrapperGenerator/WrapperGenerator.csproj b/tools/WrapperGenerator/WrapperGenerator.csproj index b3b3284047e..4bb452d3f81 100644 --- a/tools/WrapperGenerator/WrapperGenerator.csproj +++ b/tools/WrapperGenerator/WrapperGenerator.csproj @@ -21,6 +21,11 @@ + + diff --git a/tools/WrapperGenerator/docs/edge-cases/crosspath-merge-edge-cases.md b/tools/WrapperGenerator/docs/edge-cases/crosspath-merge-edge-cases.md index 6d13334f7a9..531ab980ca0 100644 --- a/tools/WrapperGenerator/docs/edge-cases/crosspath-merge-edge-cases.md +++ b/tools/WrapperGenerator/docs/edge-cases/crosspath-merge-edge-cases.md @@ -19,7 +19,7 @@ shapes / parameter-set work). - **Status:** workaround (singleton kept, collection deferred) - **Evidence:** oracle ships `Get-MgGroupPhoto` for both `GET /groups/{id}/photo` and `GET /groups/{id}/photos`; `/photos/{id}` ships nothing. Mirrors the `/users/{id}/photo(s)` - pair already curated in `NamingOverrides.cs`. + pair already curated through `CmdletConfigurator`. - **Decision:** generate from the `/photo` singleton (the primary published variant); defer `/photos` (the all-sizes collection) until parameter sets can put both URIs behind one cmdlet. @@ -34,7 +34,7 @@ shapes / parameter-set work). - **Status:** workaround (singleton kept, collection deferred) - **Evidence:** oracle ships `Get-MgShareListItem` for both `GET /shares/{id}/listItem` and `GET /shares/{id}/list/items`; the bare `/list/items/{id}` item GET ships nothing (curated - suppression, `NamingOverrides.cs`). + suppression, `CmdletConfigurator`). - **Decision:** generate from the `/listItem` singleton; defer the `/list/items` collection. - **Migration impact:** `Get-MgShareListItem` exists with identical name; enumerating a shared list's items through this cmdlet is not available until the deferral lifts. diff --git a/tools/WrapperGenerator/docs/edge-cases/naming-edge-cases.md b/tools/WrapperGenerator/docs/edge-cases/naming-edge-cases.md index f0505140b22..8f357a6d6aa 100644 --- a/tools/WrapperGenerator/docs/edge-cases/naming-edge-cases.md +++ b/tools/WrapperGenerator/docs/edge-cases/naming-edge-cases.md @@ -155,12 +155,12 @@ Entry template (keep the field names exact so the file converts cleanly): not logged at console level, the summary counts surviving files, and the parity gate only inspects files that exist. - **Decision:** the generator now fails generation loudly on any cmdlet file collision, - listing every colliding pair. Shipped cases are renamed via NamingOverrides with their + listing every colliding pair. Shipped cases are renamed via CmdletConfigurator with their directive cited (`sites/{id}/sites` → `SubSite`/`GroupSubSite`, per Sites.md `subject: SubSite` directives); paths the SDK ships nothing for are suppressed as they surface. - **Migration impact:** none — renames match the published names exactly. -- **References:** issue #3704; `NamingOverrides.cs` SubSite entries; Sites.md lines 32–61. +- **References:** issue #3704; `src\Sites\wrapper\Sites_cmdletConfigurations.cs` SubSite entries; Sites.md lines 32–61. ## Route duplicates: the spec publishes paths the SDK never shipped @@ -175,13 +175,14 @@ Entry template (keep the field names exact so the file converts cleanly): `/users/{id}/calendar/events` ships `UserDefaultCalendarEvent`), Info-wrapper navs that never shipped (`pinnedMessages/{id}/message`), and stitched pairs where GET ships from one route and PATCH/DELETE from the other (termStore, agreement file/files). -- **Decision:** each resolved family is a `NamingOverrides` entry citing the shipped +- **Decision:** each resolved family is a `CmdletConfigurator` entry citing the shipped command or the oracle's absence. Two families remain open on #3704 with full evidence: the Identity.Governance mirrored navigations (the shipped survivor alternates by nesting level, needing a dedupe design decision) and the Sites termStore `children` recursion (resolver and direct oracle probes disagree; needs reconciliation before encoding). - **Migration impact:** none — suppressed routes never shipped; renames match shipped names. -- **References:** issue #3704 (remainder inventory + resolver evidence); `NamingOverrides.cs` +- **References:** issue #3704 (remainder inventory + resolver evidence); per-module + `src\\wrapper\_cmdletConfigurations.cs` files "Collision resolutions" section. ## `-Password` / `-ForceChangePasswordNextSignIn` replaced by typed `-PasswordProfile` From 58f8dd95278bd345dc64d549e321a844bd7bc89e Mon Sep 17 00:00:00 2001 From: Microsoft Graph DevX Tooling Date: Fri, 25 Sep 2026 11:53:25 -0700 Subject: [PATCH 2/2] update v1 client and cmdlets --- .../wrapper/v1.0/Client/Models/Application.cs | 2 +- .../Client/Models/AuthenticationBehaviors.cs | 10 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + .../wrapper/v1.0/Client/Models/Group.cs | 2 +- .../wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + .../wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../CommunicationsRequestBuilder.cs | 4 +- .../v1.0/Client/Models/CloudCommunications.cs | 5 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + .../wrapper/v1.0/Client/Models/Group.cs | 2 +- .../wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + .../wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + .../wrapper/v1.0/Client/Models/Group.cs | 2 +- .../wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + .../wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 5 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + .../wrapper/v1.0/Client/Models/Group.cs | 2 +- .../wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + .../wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + .../wrapper/v1.0/Client/Models/Group.cs | 2 +- .../wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + .../wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + .../wrapper/v1.0/Client/Models/Group.cs | 2 +- .../wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + .../wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + .../wrapper/v1.0/Client/Models/Group.cs | 2 +- .../wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + .../wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + src/Files/wrapper/v1.0/Client/Models/Group.cs | 2 +- src/Files/wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + src/Files/wrapper/v1.0/Client/Models/User.cs | 10 + src/Files/wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/Application.cs | 2 +- .../Client/Models/AuthenticationBehaviors.cs | 10 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + .../wrapper/v1.0/Client/Models/Group.cs | 2 +- src/Groups/wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + src/Groups/wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../DirectoryRequestBuilder.cs | 6 + .../Count/CountRequestBuilder.cs | 124 ++++++++ .../GovernanceInvitationsRequestBuilder.cs | 238 ++++++++++++++++ .../GovernanceInvitationItemRequestBuilder.cs | 229 +++++++++++++++ .../Count/CountRequestBuilder.cs | 124 ++++++++ ...GovernancePolicyTemplatesRequestBuilder.cs | 238 ++++++++++++++++ ...ernancePolicyTemplateItemRequestBuilder.cs | 229 +++++++++++++++ .../Count/CountRequestBuilder.cs | 124 ++++++++ .../GovernanceRelationshipsRequestBuilder.cs | 238 ++++++++++++++++ ...overnanceRelationshipItemRequestBuilder.cs | 229 +++++++++++++++ .../Count/CountRequestBuilder.cs | 124 ++++++++ .../GovernanceRequestsRequestBuilder.cs | 238 ++++++++++++++++ .../GovernancePolicyTemplateRequestBuilder.cs | 125 +++++++++ .../GovernanceRequestItemRequestBuilder.cs | 235 ++++++++++++++++ .../Count/CountRequestBuilder.cs | 124 ++++++++ ...pB2BSignInActivityMetricsRequestBuilder.cs | 125 +++++++++ .../B2BRegistrationMetricsRequestBuilder.cs | 125 +++++++++ .../B2BSignInActivityMetricsRequestBuilder.cs | 125 +++++++++ .../BillingMetricsRequestBuilder.cs | 125 +++++++++ ...iTenantApplicationMetricsRequestBuilder.cs | 125 +++++++++ .../Item/RelatedTenantItemRequestBuilder.cs | 259 +++++++++++++++++ .../Refresh/RefreshRequestBuilder.cs | 96 +++++++ .../RelatedTenantsRequestBuilder.cs | 244 ++++++++++++++++ .../EnableRelatedTenantsRequestBuilder.cs | 96 +++++++ .../Settings/SettingsRequestBuilder.cs | 235 ++++++++++++++++ .../TenantGovernanceRequestBuilder.cs | 265 ++++++++++++++++++ .../wrapper/v1.0/Client/Models/Application.cs | 2 +- .../Models/ApplicationPermissionType.cs | 21 ++ .../Models/ApplicationResourcePermission.cs | 89 ++++++ .../ApplicationsRequiredResourceAccess.cs | 85 ++++++ .../Client/Models/AuthenticationBehaviors.cs | 10 +- .../Models/B2BRegistrationMetricsBase.cs | 64 +++++ .../Models/B2BRegistrationMetricsInitial.cs | 57 ++++ .../Models/B2BRegistrationMetricsRecent.cs | 57 ++++ .../Client/Models/B2BSignInActivityMetrics.cs | 66 +++++ .../Models/B2BSignInActivityMetricsBase.cs | 72 +++++ .../Models/B2BSignInActivityMetricsInitial.cs | 57 ++++ .../Models/B2BSignInActivityMetricsRecent.cs | 57 ++++ .../Client/Models/B2bRegistrationMetrics.cs | 66 +++++ .../v1.0/Client/Models/BillingMetrics.cs | 66 +++++ .../v1.0/Client/Models/BillingMetricsBase.cs | 90 ++++++ .../Client/Models/BillingMetricsInitial.cs | 50 ++++ .../Client/Models/BillingMetricsRecent.cs | 50 ++++ .../DelegatedAdministrationRoleAssignment.cs | 95 +++++++ ...tedAdministrationRoleAssignmentSnapshot.cs | 95 +++++++ .../v1.0/Client/Models/DirectoryObject1.cs | 10 + .../wrapper/v1.0/Client/Models/Entity.cs | 24 ++ .../Client/Models/GovernanceInvitation.cs | 94 +++++++ .../GovernanceInvitationCollectionResponse.cs | 56 ++++ .../Client/Models/GovernanceRelationship.cs | 108 +++++++ ...overnanceRelationshipCollectionResponse.cs | 56 ++++ .../v1.0/Client/Models/GovernanceRequest.cs | 118 ++++++++ .../GovernanceRequestCollectionResponse.cs | 56 ++++ .../wrapper/v1.0/Client/Models/Group.cs | 2 +- .../Models/MultiTenantApplicationMetrics.cs | 66 +++++ .../MultiTenantApplicationMetricsBase.cs | 64 +++++ .../MultiTenantApplicationMetricsInitial.cs | 50 ++++ .../MultiTenantApplicationMetricsRecent.cs | 50 ++++ .../MultiTenantApplicationsToProvision.cs | 105 +++++++ ...tiTenantApplicationsToProvisionSnapshot.cs | 105 +++++++ .../wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + .../v1.0/Client/Models/RelatedTenant.cs | 103 +++++++ .../Models/RelatedTenantCollectionResponse.cs | 56 ++++ .../Client/Models/RelationshipCreationType.cs | 21 ++ .../v1.0/Client/Models/RelationshipPolicy.cs | 102 +++++++ .../v1.0/Client/Models/RelationshipStatus.cs | 24 ++ .../v1.0/Client/Models/RequestStatus.cs | 24 ++ .../v1.0/Client/Models/RoleTemplate.cs | 85 ++++++ .../v1.0/Client/Models/TenantGovernance.cs | 106 +++++++ .../Models/TenantGovernancePolicyTemplate.cs | 108 +++++++ ...ernancePolicyTemplateCollectionResponse.cs | 56 ++++ .../Client/Models/TenantGovernanceSetting.cs | 54 ++++ .../wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../GetMgDirectoryTenantGovernance.g.cs | 64 +++++ ...MgDirectoryTenantGovernanceInvitation.g.cs | 91 ++++++ ...ectoryTenantGovernanceInvitationCount.g.cs | 61 ++++ ...rectoryTenantGovernanceInvitation_Get.g.cs | 65 +++++ ...ectoryTenantGovernanceInvitation_List.g.cs | 141 ++++++++++ ...rectoryTenantGovernancePolicyTemplate.g.cs | 91 ++++++ ...ryTenantGovernancePolicyTemplateCount.g.cs | 61 ++++ ...oryTenantGovernancePolicyTemplate_Get.g.cs | 65 +++++ ...ryTenantGovernancePolicyTemplate_List.g.cs | 141 ++++++++++ ...irectoryTenantGovernanceRelatedTenant.g.cs | 91 ++++++ ...latedTenantAppB2BSignInActivityMetric.g.cs | 65 +++++ ...nceRelatedTenantB2BRegistrationMetric.g.cs | 65 +++++ ...eRelatedTenantB2BSignInActivityMetric.g.cs | 65 +++++ ...tGovernanceRelatedTenantBillingMetric.g.cs | 65 +++++ ...oryTenantGovernanceRelatedTenantCount.g.cs | 61 ++++ ...tedTenantMultiTenantApplicationMetric.g.cs | 65 +++++ ...toryTenantGovernanceRelatedTenant_Get.g.cs | 65 +++++ ...oryTenantGovernanceRelatedTenant_List.g.cs | 141 ++++++++++ ...DirectoryTenantGovernanceRelationship.g.cs | 91 ++++++ ...toryTenantGovernanceRelationshipCount.g.cs | 61 ++++ ...ctoryTenantGovernanceRelationship_Get.g.cs | 65 +++++ ...toryTenantGovernanceRelationship_List.g.cs | 141 ++++++++++ ...GetMgDirectoryTenantGovernanceRequest.g.cs | 91 ++++++ ...DirectoryTenantGovernanceRequestCount.g.cs | 61 ++++ ...rnanceRequestGovernancePolicyTemplate.g.cs | 65 +++++ ...gDirectoryTenantGovernanceRequest_Get.g.cs | 65 +++++ ...DirectoryTenantGovernanceRequest_List.g.cs | 141 ++++++++++ ...GetMgDirectoryTenantGovernanceSetting.g.cs | 64 +++++ ...yTenantGovernanceRelatedTenantRefresh.g.cs | 58 ++++ ...GovernanceSettingEnableRelatedTenants.g.cs | 58 ++++ ...MgDirectoryTenantGovernanceInvitation.g.cs | 94 +++++++ ...rectoryTenantGovernancePolicyTemplate.g.cs | 104 +++++++ ...irectoryTenantGovernanceRelatedTenant.g.cs | 64 +++++ ...DirectoryTenantGovernanceRelationship.g.cs | 104 +++++++ ...NewMgDirectoryTenantGovernanceRequest.g.cs | 104 +++++++ .../RemoveMgDirectoryTenantGovernance.g.cs | 55 ++++ ...MgDirectoryTenantGovernanceInvitation.g.cs | 56 ++++ ...rectoryTenantGovernancePolicyTemplate.g.cs | 56 ++++ ...irectoryTenantGovernanceRelatedTenant.g.cs | 56 ++++ ...DirectoryTenantGovernanceRelationship.g.cs | 56 ++++ ...oveMgDirectoryTenantGovernanceRequest.g.cs | 56 ++++ ...oveMgDirectoryTenantGovernanceSetting.g.cs | 55 ++++ .../UpdateMgDirectoryTenantGovernance.g.cs | 75 +++++ ...MgDirectoryTenantGovernanceInvitation.g.cs | 110 ++++++++ ...rectoryTenantGovernancePolicyTemplate.g.cs | 120 ++++++++ ...irectoryTenantGovernanceRelatedTenant.g.cs | 80 ++++++ ...DirectoryTenantGovernanceRelationship.g.cs | 120 ++++++++ ...ateMgDirectoryTenantGovernanceRequest.g.cs | 120 ++++++++ ...ateMgDirectoryTenantGovernanceSetting.g.cs | 85 ++++++ .../AccessReviewInstanceItemRequestBuilder.cs | 6 + ...rovidedResourceDecisionsPostRequestBody.cs | 80 ++++++ ...ProvidedResourceDecisionsRequestBuilder.cs | 101 +++++++ .../AccessReviewInstanceItemRequestBuilder.cs | 6 + ...rovidedResourceDecisionsPostRequestBody.cs | 80 ++++++ ...ProvidedResourceDecisionsRequestBuilder.cs | 101 +++++++ .../AccessReviewInstanceItemRequestBuilder.cs | 6 + ...rovidedResourceDecisionsPostRequestBody.cs | 80 ++++++ ...ProvidedResourceDecisionsRequestBuilder.cs | 101 +++++++ .../Group/GroupRequestBuilder.cs | 6 + .../Resources/Count/CountRequestBuilder.cs | 124 ++++++++ .../Item/GroupResourceItemRequestBuilder.cs | 229 +++++++++++++++ .../Resources/ResourcesRequestBuilder.cs | 238 ++++++++++++++++ .../Models/AccessPackageAssignmentRequest.cs | 10 + ...ccessPackageAssignmentRequestParameters.cs | 69 +++++ .../AccessReviewInstanceDecisionItem.cs | 10 + ...ssReviewInstanceDecisionItemApplyResult.cs | 36 +++ ...essReviewInstanceDecisionItemPermission.cs | 105 +++++++ ...ccessReviewInstanceDecisionItemResource.cs | 10 + .../v1.0/Client/Models/DirectoryObject.cs | 1 + .../wrapper/v1.0/Client/Models/Entity.cs | 2 + .../wrapper/v1.0/Client/Models/Group.cs | 2 +- .../v1.0/Client/Models/GroupResource.cs | 53 ++++ .../Models/GroupResourceCollectionResponse.cs | 56 ++++ .../wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + .../Client/Models/PrivilegedAccessGroup.cs | 10 + .../wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- ...vernancePrivilegedAccessGroupResource.g.cs | 91 ++++++ ...ncePrivilegedAccessGroupResourceCount.g.cs | 61 ++++ ...ancePrivilegedAccessGroupResource_Get.g.cs | 65 +++++ ...ncePrivilegedAccessGroupResource_List.g.cs | 141 ++++++++++ ...lyCustomDataProvidedResourceDecisions.g.cs | 77 +++++ ...lyCustomDataProvidedResourceDecisions.g.cs | 77 +++++ ...lyCustomDataProvidedResourceDecisions.g.cs | 75 +++++ ...ntitlementManagementAssignmentRequest.g.cs | 6 + ...ccessReviewDefinitionInstanceDecision.g.cs | 6 + ...ReviewDefinitionInstanceStageDecision.g.cs | 6 + ...GovernanceAccessReviewUnifiedDecision.g.cs | 6 + ...viewUnifiedDefinitionInstanceDecision.g.cs | 6 + ...nifiedDefinitionInstanceStageDecision.g.cs | 6 + ...ceAccessReviewUnifiedInstanceDecision.g.cs | 6 + ...essReviewUnifiedInstanceStageDecision.g.cs | 6 + ...vernancePrivilegedAccessGroupResource.g.cs | 64 +++++ ...vernancePrivilegedAccessGroupResource.g.cs | 56 ++++ ...ccessReviewDefinitionInstanceDecision.g.cs | 6 + ...ReviewDefinitionInstanceStageDecision.g.cs | 6 + ...GovernanceAccessReviewUnifiedDecision.g.cs | 6 + ...viewUnifiedDefinitionInstanceDecision.g.cs | 6 + ...nifiedDefinitionInstanceStageDecision.g.cs | 6 + ...ceAccessReviewUnifiedInstanceDecision.g.cs | 6 + ...essReviewUnifiedInstanceStageDecision.g.cs | 6 + ...vernancePrivilegedAccessGroupResource.g.cs | 80 ++++++ .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + .../wrapper/v1.0/Client/Models/Group.cs | 2 +- .../wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + .../wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- src/Mail/wrapper/v1.0/Client/kiota-lock.json | 7 +- src/Notes/wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/DlpAction.cs | 4 + .../wrapper/v1.0/Client/Models/Entity.cs | 1 + .../wrapper/v1.0/Client/Models/Group.cs | 2 +- .../wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + .../v1.0/Client/Models/Security/Alert.cs | 2 +- .../v1.0/Client/Models/Security/Incident.cs | 2 +- .../v1.0/Client/Models/Security/Security.cs | 5 +- .../wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + src/Sites/wrapper/v1.0/Client/Models/Group.cs | 2 +- src/Sites/wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + src/Sites/wrapper/v1.0/Client/Models/User.cs | 10 + src/Sites/wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + src/Teams/wrapper/v1.0/Client/Models/Group.cs | 2 +- src/Teams/wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + src/Teams/wrapper/v1.0/Client/Models/User.cs | 10 + src/Teams/wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + .../wrapper/v1.0/Client/Models/Group.cs | 2 +- .../wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + .../wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + .../wrapper/v1.0/Client/Models/Group.cs | 2 +- .../wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + .../wrapper/v1.0/Client/Models/User.cs | 10 + .../wrapper/v1.0/Client/kiota-lock.json | 7 +- .../wrapper/v1.0/Client/Models/Application.cs | 2 +- .../Client/Models/AuthenticationBehaviors.cs | 10 +- .../wrapper/v1.0/Client/Models/Entity.cs | 1 + src/Users/wrapper/v1.0/Client/Models/Group.cs | 2 +- src/Users/wrapper/v1.0/Client/Models/Note.cs | 128 +++++++++ .../wrapper/v1.0/Client/Models/OutlookItem.cs | 1 + src/Users/wrapper/v1.0/Client/Models/User.cs | 10 + src/Users/wrapper/v1.0/Client/kiota-lock.json | 7 +- 306 files changed, 16405 insertions(+), 157 deletions(-) create mode 100644 src/Applications/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Compliance/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/DeviceManagement/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Devices.CloudPrint/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Education/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Files/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Groups/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceInvitations/Count/CountRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceInvitations/GovernanceInvitationsRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceInvitations/Item/GovernanceInvitationItemRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernancePolicyTemplates/Count/CountRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernancePolicyTemplates/GovernancePolicyTemplatesRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernancePolicyTemplates/Item/TenantGovernancePolicyTemplateItemRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRelationships/Count/CountRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRelationships/GovernanceRelationshipsRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRelationships/Item/GovernanceRelationshipItemRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/Count/CountRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/GovernanceRequestsRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/Item/GovernancePolicyTemplate/GovernancePolicyTemplateRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/Item/GovernanceRequestItemRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Count/CountRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/AppB2BSignInActivityMetrics/AppB2BSignInActivityMetricsRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/B2BRegistrationMetrics/B2BRegistrationMetricsRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/B2BSignInActivityMetrics/B2BSignInActivityMetricsRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/BillingMetrics/BillingMetricsRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/MultiTenantApplicationMetrics/MultiTenantApplicationMetricsRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/RelatedTenantItemRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Refresh/RefreshRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/RelatedTenantsRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/Settings/EnableRelatedTenants/EnableRelatedTenantsRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/Settings/SettingsRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/TenantGovernanceRequestBuilder.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/ApplicationPermissionType.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/ApplicationResourcePermission.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/ApplicationsRequiredResourceAccess.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BRegistrationMetricsBase.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BRegistrationMetricsInitial.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BRegistrationMetricsRecent.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetrics.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetricsBase.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetricsInitial.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetricsRecent.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2bRegistrationMetrics.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetrics.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetricsBase.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetricsInitial.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetricsRecent.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/DelegatedAdministrationRoleAssignment.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/DelegatedAdministrationRoleAssignmentSnapshot.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceInvitation.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceInvitationCollectionResponse.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRelationship.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRelationshipCollectionResponse.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRequest.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRequestCollectionResponse.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetrics.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetricsBase.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetricsInitial.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetricsRecent.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationsToProvision.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationsToProvisionSnapshot.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelatedTenant.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelatedTenantCollectionResponse.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelationshipCreationType.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelationshipPolicy.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelationshipStatus.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RequestStatus.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RoleTemplate.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernance.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernancePolicyTemplate.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernancePolicyTemplateCollectionResponse.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernanceSetting.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernance.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitation.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitationCount.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitation_Get.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitation_List.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplate.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplateCount.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplate_Get.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplate_List.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenant.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantAppB2BSignInActivityMetric.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantB2BRegistrationMetric.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantB2BSignInActivityMetric.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantBillingMetric.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantCount.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantMultiTenantApplicationMetric.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenant_Get.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenant_List.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationship.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationshipCount.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationship_Get.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationship_List.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequest.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequestCount.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequestGovernancePolicyTemplate.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequest_Get.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequest_List.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceSetting.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/InvokeMgDirectoryTenantGovernanceRelatedTenantRefresh.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/InvokeMgDirectoryTenantGovernanceSettingEnableRelatedTenants.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceInvitation.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernancePolicyTemplate.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceRelatedTenant.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceRelationship.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceRequest.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernance.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceInvitation.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernancePolicyTemplate.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceRelatedTenant.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceRelationship.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceRequest.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceSetting.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernance.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceInvitation.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernancePolicyTemplate.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceRelatedTenant.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceRelationship.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceRequest.g.cs create mode 100644 src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceSetting.g.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/Resources/Count/CountRequestBuilder.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/Resources/Item/GroupResourceItemRequestBuilder.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/Resources/ResourcesRequestBuilder.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/Models/AccessPackageAssignmentRequestParameters.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItemApplyResult.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItemPermission.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/Models/GroupResource.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/Models/GroupResourceCollectionResponse.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResource.g.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResourceCount.g.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResource_Get.g.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResource_List.g.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Cmdlets/InvokeMgIdentityGovernanceAccessReviewDefinitionInstanceBatchApplyCustomDataProvidedResourceDecisions.g.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Cmdlets/InvokeMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceBatchApplyCustomDataProvidedResourceDecisions.g.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Cmdlets/InvokeMgIdentityGovernanceAccessReviewUnifiedInstanceBatchApplyCustomDataProvidedResourceDecisions.g.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernancePrivilegedAccessGroupResource.g.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Cmdlets/RemoveMgIdentityGovernancePrivilegedAccessGroupResource.g.cs create mode 100644 src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernancePrivilegedAccessGroupResource.g.cs create mode 100644 src/Identity.SignIns/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Security/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Sites/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Teams/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Users.Actions/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Users.Functions/wrapper/v1.0/Client/Models/Note.cs create mode 100644 src/Users/wrapper/v1.0/Client/Models/Note.cs diff --git a/src/Applications/wrapper/v1.0/Client/Models/Application.cs b/src/Applications/wrapper/v1.0/Client/Models/Application.cs index 3cdd69496fb..b79618a4b5d 100644 --- a/src/Applications/wrapper/v1.0/Client/Models/Application.cs +++ b/src/Applications/wrapper/v1.0/Client/Models/Application.cs @@ -60,7 +60,7 @@ public partial class Application : global::Microsoft.Graph.PowerShell.Applicatio #else public List AppRoles { get; set; } #endif - /// The authenticationBehaviors property + /// The set of breaking change behaviors related to token issuance that are configured for the application. Authentication behaviors are unset by default (null) and must be explicitly enabled or disabled. Nullable. Returned only on $select. Requires $select to retrieve. For more information about authentication behaviors, see Manage application authenticationBehaviors. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Applications.Client.Models.AuthenticationBehaviors? AuthenticationBehaviors { get; set; } diff --git a/src/Applications/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs b/src/Applications/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs index 1b3564d4224..e5e004419d5 100644 --- a/src/Applications/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs +++ b/src/Applications/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs @@ -14,8 +14,10 @@ public partial class AuthenticationBehaviors : IAdditionalDataHolder, IParsable { /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. public IDictionary AdditionalData { get; set; } - /// The blockAzureADGraphAccess property + /// If false, allows the app to have extended access to Azure AD Graph until August 31, 2025 when Azure AD Graph is fully retired. For more information on Azure AD retirement updates, see June 2024 update on Azure AD Graph API retirement. public bool? BlockAzureADGraphAccess { get; set; } + /// Indicates whether Cross-Origin-Opener-Policy (COOP) headers are enforced on browser-based authentication responses for the application. Set to true to enable enforcement, false to temporarily suppress enforcement, or null to use the service default. For how-to guidance, see Control Cross-Origin-Opener-Policy enforcement. + public bool? CoopEnforcement { get; set; } /// The OdataType property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable @@ -24,9 +26,9 @@ public partial class AuthenticationBehaviors : IAdditionalDataHolder, IParsable #else public string OdataType { get; set; } #endif - /// The removeUnverifiedEmailClaim property + /// If true, removes the email claim from tokens sent to an application when the email address's domain can't be verified. public bool? RemoveUnverifiedEmailClaim { get; set; } - /// The requireClientServicePrincipal property + /// If true, requires multitenant applications to have a service principal in the resource tenant as part of authorization checks before they're granted access tokens. This property is only modifiable for multitenant resource applications that rely on access from clients without a service principal and had this behavior as set to false by Microsoft. Tenant administrators should respond to security advisories sent through Azure Health Service events and the Microsoft 365 message center. public bool? RequireClientServicePrincipal { get; set; } /// /// Instantiates a new and sets the default values. @@ -54,6 +56,7 @@ public virtual IDictionary> GetFieldDeserializers() return new Dictionary> { { "blockAzureADGraphAccess", n => { BlockAzureADGraphAccess = n.GetBoolValue(); } }, + { "coopEnforcement", n => { CoopEnforcement = n.GetBoolValue(); } }, { "@odata.type", n => { OdataType = n.GetStringValue(); } }, { "removeUnverifiedEmailClaim", n => { RemoveUnverifiedEmailClaim = n.GetBoolValue(); } }, { "requireClientServicePrincipal", n => { RequireClientServicePrincipal = n.GetBoolValue(); } }, @@ -67,6 +70,7 @@ public virtual void Serialize(ISerializationWriter writer) { if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); writer.WriteBoolValue("blockAzureADGraphAccess", BlockAzureADGraphAccess); + writer.WriteBoolValue("coopEnforcement", CoopEnforcement); writer.WriteStringValue("@odata.type", OdataType); writer.WriteBoolValue("removeUnverifiedEmailClaim", RemoveUnverifiedEmailClaim); writer.WriteBoolValue("requireClientServicePrincipal", RequireClientServicePrincipal); diff --git a/src/Applications/wrapper/v1.0/Client/Models/Entity.cs b/src/Applications/wrapper/v1.0/Client/Models/Entity.cs index 1e52444113c..0f010fd3f0f 100644 --- a/src/Applications/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Applications/wrapper/v1.0/Client/Models/Entity.cs @@ -154,6 +154,7 @@ public Entity() "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Applications.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Applications.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Applications.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Applications.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Applications.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Applications.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Applications.Client.Models.OfferShiftRequest(), diff --git a/src/Applications/wrapper/v1.0/Client/Models/Group.cs b/src/Applications/wrapper/v1.0/Client/Models/Group.cs index 6d98a74d4c1..4846a240519 100644 --- a/src/Applications/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Applications/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Applications.Cli #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Applications.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Applications/wrapper/v1.0/Client/Models/Note.cs b/src/Applications/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..813a766d059 --- /dev/null +++ b/src/Applications/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Applications.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Applications.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Applications.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Applications.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Applications.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Applications.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Applications.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Applications.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Applications.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Applications.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Applications.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Applications/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Applications/wrapper/v1.0/Client/Models/OutlookItem.cs index 0ed958a0ddc..a1ef9ad3a63 100644 --- a/src/Applications/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Applications/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Applicatio "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Applications.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Applications.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Applications.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Applications.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Applications.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Applications.Client.Models.OutlookItem(), }; diff --git a/src/Applications/wrapper/v1.0/Client/Models/User.cs b/src/Applications/wrapper/v1.0/Client/Models/User.cs index 09f1b01ae55..7ca93437bd0 100644 --- a/src/Applications/wrapper/v1.0/Client/Models/User.cs +++ b/src/Applications/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Applications.Clie #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Applications.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Applications.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Applications.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Applications/wrapper/v1.0/Client/kiota-lock.json b/src/Applications/wrapper/v1.0/Client/kiota-lock.json index 57f950ecd31..b6cba90f84c 100644 --- a/src/Applications/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Applications/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "624A7B72246233217711E3656F22F551FF344C18E98CA4B609A294AA5B673A6BABE5FAA6579F71F449DB7B7B3A3D89FF6F25031C305117F10DF3E4DAFAD39649", + "descriptionHash": "5DBBA6E50E4C5C7276DB5220A478B0CFA0A2B18340C648899888920B44CBE536D233CE95B612CD9ED13163B3CECFE86C8BD910FF486E016E43D979A540CC0CD0", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Applications.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Applications.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/BackupRestore/wrapper/v1.0/Client/kiota-lock.json b/src/BackupRestore/wrapper/v1.0/Client/kiota-lock.json index d80e32bee24..6e5d6bd7928 100644 --- a/src/BackupRestore/wrapper/v1.0/Client/kiota-lock.json +++ b/src/BackupRestore/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "1506C68470483C7B108ADC0D456EF692BCC26D086EA98CDA6EE658BCDEB3A0AD00FB50EEDE467FCFDB2CDCA0452ED99A5DFC1DF81F2D96A2FE178EDE39DE2FD0", + "descriptionHash": "971976F95609BBB7E2EC157CE4B7B03EDC8644E46395461456047E27C9821350089F4B2A7B341F6B8FC2FC84054673A62C9E140DF5247D7EAF64A5FCAF68DC72", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/BackupRestore.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.BackupRestore.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Bookings/wrapper/v1.0/Client/kiota-lock.json b/src/Bookings/wrapper/v1.0/Client/kiota-lock.json index bb35e36cc4d..aba3435446b 100644 --- a/src/Bookings/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Bookings/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "E899A99E1903FA2908413362E97406549E25642814D470E541CC97C97A57811B133E172B62FD0D5F036692721868CADE9C4AADD914C87D81BDCF23752F47E340", + "descriptionHash": "F517A8D01A91704D80593D62E5F039A809EB5A218EB24508042E818A143F4BBCE5D4EDB25FDEDAC1EFDA2D82804FCE91676CA1D5595F23EE6FF2119982B3F96A", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Bookings.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Bookings.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Calendar/wrapper/v1.0/Client/kiota-lock.json b/src/Calendar/wrapper/v1.0/Client/kiota-lock.json index 0437c54581a..9b827e8d7d9 100644 --- a/src/Calendar/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Calendar/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "E92D765EBC20862D5B42619B1C313F16545DAF9B7020588D2E73115925DE6412D64586279B1D79806DF856533EA2049D567B4B07F705E8485BC5A81E99BDFA07", + "descriptionHash": "F1B2B684A74FCC834C973FEED70BC00D5D9F17F7BFABC40F688CE6356D1A786253B08618B40BB55C22E5A6DBB0CC5BA7C15124F21CE375976254F6A91F53B6A9", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Calendar.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Calendar.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/ChangeNotifications/wrapper/v1.0/Client/kiota-lock.json b/src/ChangeNotifications/wrapper/v1.0/Client/kiota-lock.json index c4393410a00..48b2f902944 100644 --- a/src/ChangeNotifications/wrapper/v1.0/Client/kiota-lock.json +++ b/src/ChangeNotifications/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "CED55EF318A6C5AADAAF8B79C3AD20306B1380DF10AAF6B285612B27AA99DC0528AE78744D367E7AAB43B4BC0E3935372EE5E3D9E5D3E98ECEC87F420B6F8DEE", + "descriptionHash": "148FDD3EA330C3467A8E26CDB67CFD21E3C6FC320F73C74B6F9FBF105D273D4046C2176BCF07EAA4C5203E6C4308F6C0E4C329ABAAFC0222772BBE3B15F911D3", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/ChangeNotifications.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.ChangeNotifications.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/CloudCommunications/wrapper/v1.0/Client/Communications/CommunicationsRequestBuilder.cs b/src/CloudCommunications/wrapper/v1.0/Client/Communications/CommunicationsRequestBuilder.cs index c4e1fee3961..0793b05e619 100644 --- a/src/CloudCommunications/wrapper/v1.0/Client/Communications/CommunicationsRequestBuilder.cs +++ b/src/CloudCommunications/wrapper/v1.0/Client/Communications/CommunicationsRequestBuilder.cs @@ -109,7 +109,7 @@ public CommunicationsRequestBuilder(string rawUrl, IRequestAdapter requestAdapte /// Update communications /// /// A - /// Represents a container that exposes navigation properties for cloud communications resources. + /// The request body /// Cancellation token to use when cancelling requests /// Configuration for the request such as headers, query parameters, and middleware options. /// When receiving a 4XX or 5XX status code @@ -153,7 +153,7 @@ public RequestInformation ToGetRequestInformation(Action /// A - /// Represents a container that exposes navigation properties for cloud communications resources. + /// The request body /// Configuration for the request such as headers, query parameters, and middleware options. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable diff --git a/src/CloudCommunications/wrapper/v1.0/Client/Models/CloudCommunications.cs b/src/CloudCommunications/wrapper/v1.0/Client/Models/CloudCommunications.cs index 588498998a7..b627b649e8f 100644 --- a/src/CloudCommunications/wrapper/v1.0/Client/Models/CloudCommunications.cs +++ b/src/CloudCommunications/wrapper/v1.0/Client/Models/CloudCommunications.cs @@ -8,11 +8,10 @@ using System; namespace Microsoft.Graph.PowerShell.CloudCommunications.Client.Models { - /// - /// Represents a container that exposes navigation properties for cloud communications resources. - /// [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 public partial class CloudCommunications : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 { /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. public IDictionary AdditionalData { get; set; } diff --git a/src/CloudCommunications/wrapper/v1.0/Client/kiota-lock.json b/src/CloudCommunications/wrapper/v1.0/Client/kiota-lock.json index 160275c49b6..ff4686b36c3 100644 --- a/src/CloudCommunications/wrapper/v1.0/Client/kiota-lock.json +++ b/src/CloudCommunications/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "6BCED37183A1E8AAFE6BF2432B9A386C034CF86B54C7950C479199FEA1D3076127AF294CC9753025D6AC65B7F6B6583081BC6A7075B7ED1B383EEFA982B84CF9", + "descriptionHash": "0D2E49A9123FAAC8F7351DF3BA666A5A9EB9520DA1F66DFB0A282666F57D37AE102678023B800F803FF7949CA405BBCEDCE6DE64CC5707AF18F8F14CF3B370EC", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/CloudCommunications.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.CloudCommunications.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Compliance/wrapper/v1.0/Client/Models/Entity.cs b/src/Compliance/wrapper/v1.0/Client/Models/Entity.cs index d1c592665fd..933f80a6db5 100644 --- a/src/Compliance/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Compliance/wrapper/v1.0/Client/Models/Entity.cs @@ -139,6 +139,7 @@ public Entity() "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.OfferShiftRequest(), diff --git a/src/Compliance/wrapper/v1.0/Client/Models/Group.cs b/src/Compliance/wrapper/v1.0/Client/Models/Group.cs index 60f74e7da9e..5e0e1302acc 100644 --- a/src/Compliance/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Compliance/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Compliance.Clien #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Compliance.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Compliance/wrapper/v1.0/Client/Models/Note.cs b/src/Compliance/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..6b3d619ad81 --- /dev/null +++ b/src/Compliance/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Compliance.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Compliance.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Compliance.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Compliance.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Compliance.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Compliance.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Compliance.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Compliance.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Compliance.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Compliance/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Compliance/wrapper/v1.0/Client/Models/OutlookItem.cs index f955373c12b..4c0aa03afaa 100644 --- a/src/Compliance/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Compliance/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Compliance "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Compliance.Client.Models.OutlookItem(), }; diff --git a/src/Compliance/wrapper/v1.0/Client/Models/User.cs b/src/Compliance/wrapper/v1.0/Client/Models/User.cs index f1374594401..95ec544c98b 100644 --- a/src/Compliance/wrapper/v1.0/Client/Models/User.cs +++ b/src/Compliance/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Compliance.Client #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Compliance.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Compliance.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Compliance.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Compliance/wrapper/v1.0/Client/kiota-lock.json b/src/Compliance/wrapper/v1.0/Client/kiota-lock.json index f3b06c601ee..367a9d5be27 100644 --- a/src/Compliance/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Compliance/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "D67D326EFA5421A1C85471FCFDFECEA2BAB59A31DFF1CCCE348CBFD450026C9ACF126486CE1440944489F8085D1128F8A995997BA15E1602F061937EA610EF0E", + "descriptionHash": "08E47B4E16D12013B78BEBC105491505E15B128E6EE69E6872C900771159BCE8801046DAA6F3A5DB2FBB3E60533FC04644ECFD660C62F0AE83BEFE32D1FBF378", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Compliance.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Compliance.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/ConfigurationManagement/wrapper/v1.0/Client/kiota-lock.json b/src/ConfigurationManagement/wrapper/v1.0/Client/kiota-lock.json index 26be0889f6b..77520bb0450 100644 --- a/src/ConfigurationManagement/wrapper/v1.0/Client/kiota-lock.json +++ b/src/ConfigurationManagement/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "FFB13158A256BB896D6C1450FAEBF861E0535ACA83546397A491601D13937CC03643299531C815A5ABBDAC62EDB699B87EC581177BDE0E1C50162813088D25E0", + "descriptionHash": "3E9B3412247A712A633CA4B24E0AE224FC6D70FCA52F20998634502155E8179C535F40236EE4F4FAA203F29ED0C7ABC9A504BBE5EDEB19A2D385C6A2B8340AA0", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/ConfigurationManagement.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.ConfigurationManagement.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/CrossDeviceExperiences/wrapper/v1.0/Client/kiota-lock.json b/src/CrossDeviceExperiences/wrapper/v1.0/Client/kiota-lock.json index 92714fdd9e1..2130ac4aa8e 100644 --- a/src/CrossDeviceExperiences/wrapper/v1.0/Client/kiota-lock.json +++ b/src/CrossDeviceExperiences/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "4DD3ACF7367124163CC930E860F59459995E9E19B5F4304047EAFC715DA491AFD866C7DE897FE1214206A43E80D777631E0CF66D77BC893C08981F8DB01080DE", + "descriptionHash": "B8CBC7C9C6034F520F3B6C4F10C30C6B7555F3BB8BBE03FF08FC1C3D3FCA914212EE884B87DF5FEA247CE109D058B3399CD4704DE0C56E4191FB989733837B0F", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/CrossDeviceExperiences.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.CrossDeviceExperiences.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/Entity.cs b/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/Entity.cs index ef064a24fde..2288bb75d5d 100644 --- a/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/Entity.cs @@ -156,6 +156,7 @@ public Entity() "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.mobileThreatDefenseConnector" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.MobileThreatDefenseConnector(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.OfferShiftRequest(), diff --git a/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/Group.cs b/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/Group.cs index 460d5f64468..e53d96c2172 100644 --- a/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/Group.cs +++ b/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.DeviceManagement #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/Note.cs b/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..1803ea45470 --- /dev/null +++ b/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/OutlookItem.cs index 713cbf11a40..eac7bd11dd5 100644 --- a/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.DeviceMana "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.OutlookItem(), }; diff --git a/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/User.cs b/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/User.cs index 9f662421e30..139340cc3ad 100644 --- a/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/User.cs +++ b/src/DeviceManagement.Administration/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.DeviceManagement. #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/DeviceManagement.Administration/wrapper/v1.0/Client/kiota-lock.json b/src/DeviceManagement.Administration/wrapper/v1.0/Client/kiota-lock.json index 56c22c82b62..0b55f50d5f7 100644 --- a/src/DeviceManagement.Administration/wrapper/v1.0/Client/kiota-lock.json +++ b/src/DeviceManagement.Administration/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "60B145A342903D4AC2081F1C25A8DAEFCEC38EFE24CD3FB12D341333C6BF17ECDD8FCF611C0F2D16C92F9D5CD16B16C69D2A6E08B2362C0F10035974C29256FD", + "descriptionHash": "102A2DB0524A1EA1AB441866BC4E7DD6FFEA12EA9D8965C39C8A55CC4A74760D7E1985BA8FA20FCB5ED5D28E53E2DAB3C22604FBF1BC4BCC6A146F1639F41B6A", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/DeviceManagement.Administration.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.DeviceManagement.Administration.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/DeviceManagement.Enrollment/wrapper/v1.0/Client/kiota-lock.json b/src/DeviceManagement.Enrollment/wrapper/v1.0/Client/kiota-lock.json index bada8cb7759..ba017173d5d 100644 --- a/src/DeviceManagement.Enrollment/wrapper/v1.0/Client/kiota-lock.json +++ b/src/DeviceManagement.Enrollment/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "BE39EDAD2F09E6551F156B0ABC4714778492B846210D987CF4169598B69539AA169498763FBAB7C8CB37ABF7DCE320E70CDCE4B425EAE21CDFB67514FA8FFDA9", + "descriptionHash": "B32E1019BA8849D13B5F2C2082EEAD396C417D31DA96D4463B547F96134E7E244955A605EB6AA3F9479FB061469C78A159CA8E7FBF8F901064763293F97C398E", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/DeviceManagement.Enrollment.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.DeviceManagement.Enrollment.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/DeviceManagement.Functions/wrapper/v1.0/Client/kiota-lock.json b/src/DeviceManagement.Functions/wrapper/v1.0/Client/kiota-lock.json index 4dc519dcc25..444a9ea221e 100644 --- a/src/DeviceManagement.Functions/wrapper/v1.0/Client/kiota-lock.json +++ b/src/DeviceManagement.Functions/wrapper/v1.0/Client/kiota-lock.json @@ -2,7 +2,7 @@ "descriptionHash": "8F32CC7341A9521C4E691E7D4543098CBF218CE13F77F59BA7EDD2997F829BB7605E29BFF72FB4D91B15541241F44663A3DA850DBDF1F9FC0EA2A38DF85C3B0A", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/DeviceManagement.Functions.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.DeviceManagement.Functions.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/DeviceManagement/wrapper/v1.0/Client/Models/Entity.cs b/src/DeviceManagement/wrapper/v1.0/Client/Models/Entity.cs index 203d8a2d1fd..8435fba9d31 100644 --- a/src/DeviceManagement/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/DeviceManagement/wrapper/v1.0/Client/Models/Entity.cs @@ -191,6 +191,7 @@ public Entity() "#microsoft.graph.mobileAppTroubleshootingEvent" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.MobileAppTroubleshootingEvent(), "#microsoft.graph.mobileThreatDefenseConnector" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.MobileThreatDefenseConnector(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.Notebook(), "#microsoft.graph.notificationMessageTemplate" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.NotificationMessageTemplate(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.OAuth2PermissionGrant(), diff --git a/src/DeviceManagement/wrapper/v1.0/Client/Models/Group.cs b/src/DeviceManagement/wrapper/v1.0/Client/Models/Group.cs index 9ce297851c0..6fc1a0876c9 100644 --- a/src/DeviceManagement/wrapper/v1.0/Client/Models/Group.cs +++ b/src/DeviceManagement/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.DeviceManagement #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/DeviceManagement/wrapper/v1.0/Client/Models/Note.cs b/src/DeviceManagement/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..a8f5f75afa7 --- /dev/null +++ b/src/DeviceManagement/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.DeviceManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/DeviceManagement/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/DeviceManagement/wrapper/v1.0/Client/Models/OutlookItem.cs index 82e15da8fe3..562b93fae59 100644 --- a/src/DeviceManagement/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/DeviceManagement/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.DeviceMana "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.OutlookItem(), }; diff --git a/src/DeviceManagement/wrapper/v1.0/Client/Models/User.cs b/src/DeviceManagement/wrapper/v1.0/Client/Models/User.cs index 65d8ecc72eb..ba626bf4fa3 100644 --- a/src/DeviceManagement/wrapper/v1.0/Client/Models/User.cs +++ b/src/DeviceManagement/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.DeviceManagement. #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.DeviceManagement.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/DeviceManagement/wrapper/v1.0/Client/kiota-lock.json b/src/DeviceManagement/wrapper/v1.0/Client/kiota-lock.json index fc8a8a637c5..39cf8960b62 100644 --- a/src/DeviceManagement/wrapper/v1.0/Client/kiota-lock.json +++ b/src/DeviceManagement/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "755A858F2631C80B4C4A6328D08CC1D42C7FF754A7C732811A00353EBDC6AFB382C356E7F7EB6000537913AC2D5FC050D609786CA9EBDB37B79F6E9C0D5A2626", + "descriptionHash": "0D499DB03BA03D23E06DD9D766B7346512AFD616F53E4B6F4C829185BAFD31F3796CA461437AE0147317EAD79A0AA5F9F7617486DB784D695DC6243DECA3C31B", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/DeviceManagement.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.DeviceManagement.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/Entity.cs b/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/Entity.cs index 8d3c76b2601..3bfba04615a 100644 --- a/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/Entity.cs @@ -138,6 +138,7 @@ public Entity() "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.OfferShiftRequest(), diff --git a/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/Group.cs b/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/Group.cs index 2caeef74b81..c282c2f016e 100644 --- a/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Devices.CloudPri #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/Note.cs b/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..6c3bc47c27f --- /dev/null +++ b/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/OutlookItem.cs index 8c261733002..946cfbc6540 100644 --- a/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Devices.Cl "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.OutlookItem(), }; diff --git a/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/User.cs b/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/User.cs index a4da68271be..5011489d669 100644 --- a/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/User.cs +++ b/src/Devices.CloudPrint/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Devices.CloudPrin #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CloudPrint.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Devices.CloudPrint/wrapper/v1.0/Client/kiota-lock.json b/src/Devices.CloudPrint/wrapper/v1.0/Client/kiota-lock.json index 975d4ddea56..414281eab6b 100644 --- a/src/Devices.CloudPrint/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Devices.CloudPrint/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "2BD2A6E55464DD02A9CB2101EC0E20396D3863B0C2CF1230126C7D80623CD48E004DB905150B60A24E008E692C4547354D5259538D2319B87AAF72BCC6E36A0E", + "descriptionHash": "CA9040F966CFC045EAA59CD677790F24B42D8A89C8998795EDCF6A09B645C348B447B1B49C054D2317619A7F40855978B04C029DAF4D6D7F147DC21904F6ED09", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Devices.CloudPrint.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Devices.CloudPrint.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/Entity.cs b/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/Entity.cs index cdebb61b595..2d1acb4cc02 100644 --- a/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/Entity.cs @@ -177,6 +177,7 @@ public Entity() "#microsoft.graph.mobileContainedApp" => new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.MobileContainedApp(), "#microsoft.graph.mobileLobApp" => new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.MobileLobApp(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.OfferShiftRequest(), diff --git a/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/Group.cs b/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/Group.cs index 4f3c28b7c8d..ee4c8931e2c 100644 --- a/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Devices.Corporat #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/Note.cs b/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..46d8f0c086a --- /dev/null +++ b/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/OutlookItem.cs index 994e2347b49..f6467e0777c 100644 --- a/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Devices.Co "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.OutlookItem(), }; diff --git a/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/User.cs b/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/User.cs index 288e168b858..b67ad7450ee 100644 --- a/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/User.cs +++ b/src/Devices.CorporateManagement/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Devices.Corporate #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Devices.CorporateManagement/wrapper/v1.0/Client/kiota-lock.json b/src/Devices.CorporateManagement/wrapper/v1.0/Client/kiota-lock.json index ffc9b21befc..3d301943f6f 100644 --- a/src/Devices.CorporateManagement/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Devices.CorporateManagement/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "10B27C9468681607AC9FD691651CA7D144B7FC4BA01FDEB1850C63AF42F69AD049B90D229153DFE59AE08C74B5C0A0A78F8B3F2D913FB7247B3E31F784625BB9", + "descriptionHash": "AE23DA729F04F40C262174CD701242E766D4D37962D54CAC3BDB4EE8D0287E56DA971F765F772ED98C1990F266DE8C5BD2C5AAAA8F6C6008420DEDC7FAE73D24", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Devices.CorporateManagement.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Devices.CorporateManagement.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Devices.ServiceAnnouncement/wrapper/v1.0/Client/kiota-lock.json b/src/Devices.ServiceAnnouncement/wrapper/v1.0/Client/kiota-lock.json index 678e91d4a7e..8af5841c2af 100644 --- a/src/Devices.ServiceAnnouncement/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Devices.ServiceAnnouncement/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "C3DF6F2855FE67E4322E9B2D7FCF6DEDF51A163BC81D78A3C53802E8E4723DAE40ADB84CC939DED7A14EB5556072375839896369447F7EF80522DBB715EFBD1A", + "descriptionHash": "2A87475A3C90B14C09279F206D1EDF6297F0178F0185056E9D069C55493F0A4217ADD1BCFC49392E1DA11A3A625D7369768E29BFF262E51EA6D6058836F667CB", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Devices.ServiceAnnouncement.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Devices.ServiceAnnouncement.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/DirectoryObjects/wrapper/v1.0/Client/kiota-lock.json b/src/DirectoryObjects/wrapper/v1.0/Client/kiota-lock.json index 441bb60bf83..2beeb0a5566 100644 --- a/src/DirectoryObjects/wrapper/v1.0/Client/kiota-lock.json +++ b/src/DirectoryObjects/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "248DAC6D898344D97A001532B36F055D8CDA92B2D1F10BD52178E89DA142C54E39523DEF3E1797CAFF2FB7BE51BA901962C8B57EA1EC30D38A7814709490936D", + "descriptionHash": "AF25131E2BB975E19A26F4BD8E5C4107F9AE894C88EA32662D91DC9CA0DF54CA4B0664B0C5D9097BFED289736AB17B772CA09E1AB351B05303A0E39D6B8F79B3", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/DirectoryObjects.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.DirectoryObjects.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Education/wrapper/v1.0/Client/Models/Entity.cs b/src/Education/wrapper/v1.0/Client/Models/Entity.cs index 3fff2894c46..26d9fee03be 100644 --- a/src/Education/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Education/wrapper/v1.0/Client/Models/Entity.cs @@ -156,6 +156,7 @@ public Entity() "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Education.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Education.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Education.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Education.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Education.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Education.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Education.Client.Models.OfferShiftRequest(), diff --git a/src/Education/wrapper/v1.0/Client/Models/Group.cs b/src/Education/wrapper/v1.0/Client/Models/Group.cs index 3426a85aa94..53b668ce3a9 100644 --- a/src/Education/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Education/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Education.Client #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Education.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Education/wrapper/v1.0/Client/Models/Note.cs b/src/Education/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..3ac51ec49c3 --- /dev/null +++ b/src/Education/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Education.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Education.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Education.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Education.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Education.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Education.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Education.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Education.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Education.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Education.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Education.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Education/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Education/wrapper/v1.0/Client/Models/OutlookItem.cs index 1c73cc520b8..14187c329b7 100644 --- a/src/Education/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Education/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Education. "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Education.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Education.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Education.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Education.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Education.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Education.Client.Models.OutlookItem(), }; diff --git a/src/Education/wrapper/v1.0/Client/Models/User.cs b/src/Education/wrapper/v1.0/Client/Models/User.cs index aada5a881f9..7e249630d23 100644 --- a/src/Education/wrapper/v1.0/Client/Models/User.cs +++ b/src/Education/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Education.Client. #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Education.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Education.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Education.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Education/wrapper/v1.0/Client/kiota-lock.json b/src/Education/wrapper/v1.0/Client/kiota-lock.json index 286bb80631b..6e1135a2167 100644 --- a/src/Education/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Education/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "01CC683D93407C647E2567CC979B69C6D415F6185A20506EB248ECC3873A9BF597DECBA2FE6BCE845792AA8C7BF8960FB53E38325C8E214E0CFD132FD78F21DA", + "descriptionHash": "C7A24AAB8CF2929CE94D9418DC6792808ABEF3382D7F53EA74AF957A3BBB8861EC33A8F40A99E0A1CA30967271387E0924667D4F2A6193418911DF15CA97EC52", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Education.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Education.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Files/wrapper/v1.0/Client/Models/Entity.cs b/src/Files/wrapper/v1.0/Client/Models/Entity.cs index 9fc93bc0d6c..2f9b7337465 100644 --- a/src/Files/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Files/wrapper/v1.0/Client/Models/Entity.cs @@ -138,6 +138,7 @@ public Entity() "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Files.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Files.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Files.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Files.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Files.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Files.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Files.Client.Models.OfferShiftRequest(), diff --git a/src/Files/wrapper/v1.0/Client/Models/Group.cs b/src/Files/wrapper/v1.0/Client/Models/Group.cs index 0c9893952f4..14f56648431 100644 --- a/src/Files/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Files/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Files.Client.Mod #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Files.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Files/wrapper/v1.0/Client/Models/Note.cs b/src/Files/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..17772b93ddd --- /dev/null +++ b/src/Files/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Files.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Files.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Files.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Files.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Files.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Files.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Files.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Files.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Files.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Files.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Files.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Files/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Files/wrapper/v1.0/Client/Models/OutlookItem.cs index 94bb11c6c10..e6ef3df14c1 100644 --- a/src/Files/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Files/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Files.Clie "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Files.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Files.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Files.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Files.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Files.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Files.Client.Models.OutlookItem(), }; diff --git a/src/Files/wrapper/v1.0/Client/Models/User.cs b/src/Files/wrapper/v1.0/Client/Models/User.cs index f0df5df0e6c..7cfe7d7db99 100644 --- a/src/Files/wrapper/v1.0/Client/Models/User.cs +++ b/src/Files/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Files.Client.Mode #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Files.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Files.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Files.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Files/wrapper/v1.0/Client/kiota-lock.json b/src/Files/wrapper/v1.0/Client/kiota-lock.json index 0c160d63d57..75a1fbf5ffe 100644 --- a/src/Files/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Files/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "1F38E1AC5F1100A04B04F291FE371BB5436F61A82074A353A87BDC7DEE9A940B8CCD959A023AA7942771FF0DE752C331F67E342503C47CB21F5F101AD71CA987", + "descriptionHash": "0C7324BEB8767E9CC8CC2767DB9A3455E8BEE5140F01A322278EF44A35B1A7646E593504AE5DB831A627766A9F64AD82E5AC6452E2259657DA5A7444041BD8E4", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Files.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Files.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Groups/wrapper/v1.0/Client/Models/Application.cs b/src/Groups/wrapper/v1.0/Client/Models/Application.cs index 4e37c97e9d3..da4a07c3f5a 100644 --- a/src/Groups/wrapper/v1.0/Client/Models/Application.cs +++ b/src/Groups/wrapper/v1.0/Client/Models/Application.cs @@ -60,7 +60,7 @@ public partial class Application : global::Microsoft.Graph.PowerShell.Groups.Cli #else public List AppRoles { get; set; } #endif - /// The authenticationBehaviors property + /// The set of breaking change behaviors related to token issuance that are configured for the application. Authentication behaviors are unset by default (null) and must be explicitly enabled or disabled. Nullable. Returned only on $select. Requires $select to retrieve. For more information about authentication behaviors, see Manage application authenticationBehaviors. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Groups.Client.Models.AuthenticationBehaviors? AuthenticationBehaviors { get; set; } diff --git a/src/Groups/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs b/src/Groups/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs index 98608bb389c..cb5b17225b8 100644 --- a/src/Groups/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs +++ b/src/Groups/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs @@ -14,8 +14,10 @@ public partial class AuthenticationBehaviors : IAdditionalDataHolder, IParsable { /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. public IDictionary AdditionalData { get; set; } - /// The blockAzureADGraphAccess property + /// If false, allows the app to have extended access to Azure AD Graph until August 31, 2025 when Azure AD Graph is fully retired. For more information on Azure AD retirement updates, see June 2024 update on Azure AD Graph API retirement. public bool? BlockAzureADGraphAccess { get; set; } + /// Indicates whether Cross-Origin-Opener-Policy (COOP) headers are enforced on browser-based authentication responses for the application. Set to true to enable enforcement, false to temporarily suppress enforcement, or null to use the service default. For how-to guidance, see Control Cross-Origin-Opener-Policy enforcement. + public bool? CoopEnforcement { get; set; } /// The OdataType property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable @@ -24,9 +26,9 @@ public partial class AuthenticationBehaviors : IAdditionalDataHolder, IParsable #else public string OdataType { get; set; } #endif - /// The removeUnverifiedEmailClaim property + /// If true, removes the email claim from tokens sent to an application when the email address's domain can't be verified. public bool? RemoveUnverifiedEmailClaim { get; set; } - /// The requireClientServicePrincipal property + /// If true, requires multitenant applications to have a service principal in the resource tenant as part of authorization checks before they're granted access tokens. This property is only modifiable for multitenant resource applications that rely on access from clients without a service principal and had this behavior as set to false by Microsoft. Tenant administrators should respond to security advisories sent through Azure Health Service events and the Microsoft 365 message center. public bool? RequireClientServicePrincipal { get; set; } /// /// Instantiates a new and sets the default values. @@ -54,6 +56,7 @@ public virtual IDictionary> GetFieldDeserializers() return new Dictionary> { { "blockAzureADGraphAccess", n => { BlockAzureADGraphAccess = n.GetBoolValue(); } }, + { "coopEnforcement", n => { CoopEnforcement = n.GetBoolValue(); } }, { "@odata.type", n => { OdataType = n.GetStringValue(); } }, { "removeUnverifiedEmailClaim", n => { RemoveUnverifiedEmailClaim = n.GetBoolValue(); } }, { "requireClientServicePrincipal", n => { RequireClientServicePrincipal = n.GetBoolValue(); } }, @@ -67,6 +70,7 @@ public virtual void Serialize(ISerializationWriter writer) { if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); writer.WriteBoolValue("blockAzureADGraphAccess", BlockAzureADGraphAccess); + writer.WriteBoolValue("coopEnforcement", CoopEnforcement); writer.WriteStringValue("@odata.type", OdataType); writer.WriteBoolValue("removeUnverifiedEmailClaim", RemoveUnverifiedEmailClaim); writer.WriteBoolValue("requireClientServicePrincipal", RequireClientServicePrincipal); diff --git a/src/Groups/wrapper/v1.0/Client/Models/Entity.cs b/src/Groups/wrapper/v1.0/Client/Models/Entity.cs index f1de715de64..32d4f4f4182 100644 --- a/src/Groups/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Groups/wrapper/v1.0/Client/Models/Entity.cs @@ -151,6 +151,7 @@ public Entity() "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Groups.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Groups.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Groups.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Groups.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Groups.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Groups.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Groups.Client.Models.OfferShiftRequest(), diff --git a/src/Groups/wrapper/v1.0/Client/Models/Group.cs b/src/Groups/wrapper/v1.0/Client/Models/Group.cs index c08c70a8289..f1363920d72 100644 --- a/src/Groups/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Groups/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Groups.Client.Mo #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Groups.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Groups/wrapper/v1.0/Client/Models/Note.cs b/src/Groups/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..08892ccc860 --- /dev/null +++ b/src/Groups/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Groups.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Groups.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Groups.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Groups.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Groups.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Groups.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Groups.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Groups.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Groups.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Groups.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Groups.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Groups/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Groups/wrapper/v1.0/Client/Models/OutlookItem.cs index db3af777cdc..b1f5b4e9f48 100644 --- a/src/Groups/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Groups/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Groups.Cli "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Groups.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Groups.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Groups.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Groups.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Groups.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Groups.Client.Models.OutlookItem(), }; diff --git a/src/Groups/wrapper/v1.0/Client/Models/User.cs b/src/Groups/wrapper/v1.0/Client/Models/User.cs index d1538369bd8..9f0890e04ce 100644 --- a/src/Groups/wrapper/v1.0/Client/Models/User.cs +++ b/src/Groups/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Groups.Client.Mod #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Groups.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Groups.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Groups.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Groups/wrapper/v1.0/Client/kiota-lock.json b/src/Groups/wrapper/v1.0/Client/kiota-lock.json index 5981dccf248..92fa9f5c831 100644 --- a/src/Groups/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Groups/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "061EB567B8A7C1AB056FBDC65B8BAABC7D4904026FE7A7DE4BA90902ACE80A4F5E9E93C41F25E8E1D638F5E71D999D304DF374E3BA5F30D51CD4AAD30A4B6564", + "descriptionHash": "356A142ADDC374AE0A3ED1F0065CB22B9C8BFC00D712CCD35BFA0E765C7FBEA26ACB01E03FAB420A40CEF4CD051D84130555ACB31870AFB5FBFDA6C5FF613744", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Groups.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Groups.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/DirectoryRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/DirectoryRequestBuilder.cs index 81de45afe54..66d92cd6ba1 100644 --- a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/DirectoryRequestBuilder.cs +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/DirectoryRequestBuilder.cs @@ -12,6 +12,7 @@ using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.RemoteTenantGroups; using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.Subscriptions; using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.SubscriptionsWithCommerceSubscriptionId; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance; using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; using Microsoft.Kiota.Abstractions.Extensions; @@ -85,6 +86,11 @@ public partial class DirectoryRequestBuilder : BaseRequestBuilder { get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.Subscriptions.SubscriptionsRequestBuilder(PathParameters, RequestAdapter); } + /// The tenantGovernance property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.TenantGovernanceRequestBuilder TenantGovernance + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.TenantGovernanceRequestBuilder(PathParameters, RequestAdapter); + } /// /// Instantiates a new and sets the default values. /// diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceInvitations/Count/CountRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceInvitations/Count/CountRequestBuilder.cs new file mode 100644 index 00000000000..440ed3ad84c --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceInvitations/Count/CountRequestBuilder.cs @@ -0,0 +1,124 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.Count +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\governanceInvitations\$count + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public CountRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceInvitations/$count{?%24filter,%24search}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public CountRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceInvitations/$count{?%24filter,%24search}", rawUrl) + { + } + /// + /// Get the number of the resource + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendPrimitiveAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get the number of the resource + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "text/plain;q=0.9"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.Count.CountRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.Count.CountRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get the number of the resource + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilderGetQueryParameters + { + /// Filter items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24filter")] + public string? Filter { get; set; } +#nullable restore +#else + [QueryParameter("%24filter")] + public string Filter { get; set; } +#endif + /// Search items by search phrases +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24search")] + public string? Search { get; set; } +#nullable restore +#else + [QueryParameter("%24search")] + public string Search { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceInvitations/GovernanceInvitationsRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceInvitations/GovernanceInvitationsRequestBuilder.cs new file mode 100644 index 00000000000..e13fcfe0c0c --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceInvitations/GovernanceInvitationsRequestBuilder.cs @@ -0,0 +1,238 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.Count; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.Item; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\governanceInvitations + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceInvitationsRequestBuilder : BaseRequestBuilder + { + /// The Count property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.Count.CountRequestBuilder Count + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.Count.CountRequestBuilder(PathParameters, RequestAdapter); + } + /// Gets an item from the Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.directory.tenantGovernance.governanceInvitations.item collection + /// Unique identifier of the item + /// A + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.Item.GovernanceInvitationItemRequestBuilder this[string position] + { + get + { + var urlTplParams = new Dictionary(PathParameters); + urlTplParams.Add("governanceInvitation%2Did", position); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.Item.GovernanceInvitationItemRequestBuilder(urlTplParams, RequestAdapter); + } + } + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public GovernanceInvitationsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceInvitations{?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public GovernanceInvitationsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceInvitations{?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", rawUrl) + { + } + /// + /// Get governanceInvitations from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitationCollectionResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Create new navigation property to governanceInvitations for directory + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPostRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get governanceInvitations from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Create new navigation property to governanceInvitations for directory + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.POST, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.GovernanceInvitationsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.GovernanceInvitationsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get governanceInvitations from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceInvitationsRequestBuilderGetQueryParameters + { + /// Include count of items + [QueryParameter("%24count")] + public bool? Count { get; set; } + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Filter items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24filter")] + public string? Filter { get; set; } +#nullable restore +#else + [QueryParameter("%24filter")] + public string Filter { get; set; } +#endif + /// Order items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24orderby")] + public string[]? Orderby { get; set; } +#nullable restore +#else + [QueryParameter("%24orderby")] + public string[] Orderby { get; set; } +#endif + /// Search items by search phrases +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24search")] + public string? Search { get; set; } +#nullable restore +#else + [QueryParameter("%24search")] + public string Search { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + /// Skip the first n items + [QueryParameter("%24skip")] + public int? Skip { get; set; } + /// Show only the first n items + [QueryParameter("%24top")] + public int? Top { get; set; } + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceInvitationsRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceInvitationsRequestBuilderPostRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceInvitations/Item/GovernanceInvitationItemRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceInvitations/Item/GovernanceInvitationItemRequestBuilder.cs new file mode 100644 index 00000000000..890a515d5b1 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceInvitations/Item/GovernanceInvitationItemRequestBuilder.cs @@ -0,0 +1,229 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.Item +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\governanceInvitations\{governanceInvitation-id} + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceInvitationItemRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public GovernanceInvitationItemRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceInvitations/{governanceInvitation%2Did}{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public GovernanceInvitationItemRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceInvitations/{governanceInvitation%2Did}{?%24expand,%24select}", rawUrl) + { + } + /// + /// Delete navigation property governanceInvitations for directory + /// + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task DeleteAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task DeleteAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToDeleteRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get governanceInvitations from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Update the navigation property governanceInvitations in directory + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPatchRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Delete navigation property governanceInvitations for directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToDeleteRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToDeleteRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.DELETE, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Get governanceInvitations from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Update the navigation property governanceInvitations in directory + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.PATCH, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.Item.GovernanceInvitationItemRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.Item.GovernanceInvitationItemRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceInvitationItemRequestBuilderDeleteRequestConfiguration : RequestConfiguration + { + } + /// + /// Get governanceInvitations from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceInvitationItemRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceInvitationItemRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceInvitationItemRequestBuilderPatchRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernancePolicyTemplates/Count/CountRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernancePolicyTemplates/Count/CountRequestBuilder.cs new file mode 100644 index 00000000000..e5f881e1074 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernancePolicyTemplates/Count/CountRequestBuilder.cs @@ -0,0 +1,124 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.Count +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\governancePolicyTemplates\$count + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public CountRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governancePolicyTemplates/$count{?%24filter,%24search}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public CountRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governancePolicyTemplates/$count{?%24filter,%24search}", rawUrl) + { + } + /// + /// Get the number of the resource + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendPrimitiveAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get the number of the resource + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "text/plain;q=0.9"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.Count.CountRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.Count.CountRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get the number of the resource + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilderGetQueryParameters + { + /// Filter items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24filter")] + public string? Filter { get; set; } +#nullable restore +#else + [QueryParameter("%24filter")] + public string Filter { get; set; } +#endif + /// Search items by search phrases +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24search")] + public string? Search { get; set; } +#nullable restore +#else + [QueryParameter("%24search")] + public string Search { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernancePolicyTemplates/GovernancePolicyTemplatesRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernancePolicyTemplates/GovernancePolicyTemplatesRequestBuilder.cs new file mode 100644 index 00000000000..bef00fcba5b --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernancePolicyTemplates/GovernancePolicyTemplatesRequestBuilder.cs @@ -0,0 +1,238 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.Count; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.Item; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\governancePolicyTemplates + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernancePolicyTemplatesRequestBuilder : BaseRequestBuilder + { + /// The Count property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.Count.CountRequestBuilder Count + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.Count.CountRequestBuilder(PathParameters, RequestAdapter); + } + /// Gets an item from the Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.directory.tenantGovernance.governancePolicyTemplates.item collection + /// Unique identifier of the item + /// A + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.Item.TenantGovernancePolicyTemplateItemRequestBuilder this[string position] + { + get + { + var urlTplParams = new Dictionary(PathParameters); + urlTplParams.Add("tenantGovernancePolicyTemplate%2Did", position); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.Item.TenantGovernancePolicyTemplateItemRequestBuilder(urlTplParams, RequestAdapter); + } + } + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public GovernancePolicyTemplatesRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governancePolicyTemplates{?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public GovernancePolicyTemplatesRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governancePolicyTemplates{?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", rawUrl) + { + } + /// + /// Get governancePolicyTemplates from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplateCollectionResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Create new navigation property to governancePolicyTemplates for directory + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPostRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get governancePolicyTemplates from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Create new navigation property to governancePolicyTemplates for directory + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.POST, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.GovernancePolicyTemplatesRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.GovernancePolicyTemplatesRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get governancePolicyTemplates from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernancePolicyTemplatesRequestBuilderGetQueryParameters + { + /// Include count of items + [QueryParameter("%24count")] + public bool? Count { get; set; } + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Filter items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24filter")] + public string? Filter { get; set; } +#nullable restore +#else + [QueryParameter("%24filter")] + public string Filter { get; set; } +#endif + /// Order items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24orderby")] + public string[]? Orderby { get; set; } +#nullable restore +#else + [QueryParameter("%24orderby")] + public string[] Orderby { get; set; } +#endif + /// Search items by search phrases +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24search")] + public string? Search { get; set; } +#nullable restore +#else + [QueryParameter("%24search")] + public string Search { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + /// Skip the first n items + [QueryParameter("%24skip")] + public int? Skip { get; set; } + /// Show only the first n items + [QueryParameter("%24top")] + public int? Top { get; set; } + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernancePolicyTemplatesRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernancePolicyTemplatesRequestBuilderPostRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernancePolicyTemplates/Item/TenantGovernancePolicyTemplateItemRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernancePolicyTemplates/Item/TenantGovernancePolicyTemplateItemRequestBuilder.cs new file mode 100644 index 00000000000..c9b06857ae9 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernancePolicyTemplates/Item/TenantGovernancePolicyTemplateItemRequestBuilder.cs @@ -0,0 +1,229 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.Item +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\governancePolicyTemplates\{tenantGovernancePolicyTemplate-id} + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class TenantGovernancePolicyTemplateItemRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public TenantGovernancePolicyTemplateItemRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governancePolicyTemplates/{tenantGovernancePolicyTemplate%2Did}{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public TenantGovernancePolicyTemplateItemRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governancePolicyTemplates/{tenantGovernancePolicyTemplate%2Did}{?%24expand,%24select}", rawUrl) + { + } + /// + /// Delete navigation property governancePolicyTemplates for directory + /// + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task DeleteAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task DeleteAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToDeleteRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get governancePolicyTemplates from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Update the navigation property governancePolicyTemplates in directory + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPatchRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Delete navigation property governancePolicyTemplates for directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToDeleteRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToDeleteRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.DELETE, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Get governancePolicyTemplates from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Update the navigation property governancePolicyTemplates in directory + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.PATCH, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.Item.TenantGovernancePolicyTemplateItemRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.Item.TenantGovernancePolicyTemplateItemRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class TenantGovernancePolicyTemplateItemRequestBuilderDeleteRequestConfiguration : RequestConfiguration + { + } + /// + /// Get governancePolicyTemplates from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class TenantGovernancePolicyTemplateItemRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class TenantGovernancePolicyTemplateItemRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class TenantGovernancePolicyTemplateItemRequestBuilderPatchRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRelationships/Count/CountRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRelationships/Count/CountRequestBuilder.cs new file mode 100644 index 00000000000..569cd77739b --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRelationships/Count/CountRequestBuilder.cs @@ -0,0 +1,124 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.Count +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\governanceRelationships\$count + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public CountRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRelationships/$count{?%24filter,%24search}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public CountRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRelationships/$count{?%24filter,%24search}", rawUrl) + { + } + /// + /// Get the number of the resource + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendPrimitiveAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get the number of the resource + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "text/plain;q=0.9"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.Count.CountRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.Count.CountRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get the number of the resource + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilderGetQueryParameters + { + /// Filter items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24filter")] + public string? Filter { get; set; } +#nullable restore +#else + [QueryParameter("%24filter")] + public string Filter { get; set; } +#endif + /// Search items by search phrases +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24search")] + public string? Search { get; set; } +#nullable restore +#else + [QueryParameter("%24search")] + public string Search { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRelationships/GovernanceRelationshipsRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRelationships/GovernanceRelationshipsRequestBuilder.cs new file mode 100644 index 00000000000..eb06734c2e0 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRelationships/GovernanceRelationshipsRequestBuilder.cs @@ -0,0 +1,238 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.Count; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.Item; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\governanceRelationships + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRelationshipsRequestBuilder : BaseRequestBuilder + { + /// The Count property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.Count.CountRequestBuilder Count + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.Count.CountRequestBuilder(PathParameters, RequestAdapter); + } + /// Gets an item from the Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.directory.tenantGovernance.governanceRelationships.item collection + /// Unique identifier of the item + /// A + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.Item.GovernanceRelationshipItemRequestBuilder this[string position] + { + get + { + var urlTplParams = new Dictionary(PathParameters); + urlTplParams.Add("governanceRelationship%2Did", position); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.Item.GovernanceRelationshipItemRequestBuilder(urlTplParams, RequestAdapter); + } + } + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public GovernanceRelationshipsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRelationships{?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public GovernanceRelationshipsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRelationships{?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", rawUrl) + { + } + /// + /// Get governanceRelationships from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationshipCollectionResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Create new navigation property to governanceRelationships for directory + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPostRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get governanceRelationships from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Create new navigation property to governanceRelationships for directory + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.POST, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.GovernanceRelationshipsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.GovernanceRelationshipsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get governanceRelationships from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRelationshipsRequestBuilderGetQueryParameters + { + /// Include count of items + [QueryParameter("%24count")] + public bool? Count { get; set; } + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Filter items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24filter")] + public string? Filter { get; set; } +#nullable restore +#else + [QueryParameter("%24filter")] + public string Filter { get; set; } +#endif + /// Order items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24orderby")] + public string[]? Orderby { get; set; } +#nullable restore +#else + [QueryParameter("%24orderby")] + public string[] Orderby { get; set; } +#endif + /// Search items by search phrases +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24search")] + public string? Search { get; set; } +#nullable restore +#else + [QueryParameter("%24search")] + public string Search { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + /// Skip the first n items + [QueryParameter("%24skip")] + public int? Skip { get; set; } + /// Show only the first n items + [QueryParameter("%24top")] + public int? Top { get; set; } + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRelationshipsRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRelationshipsRequestBuilderPostRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRelationships/Item/GovernanceRelationshipItemRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRelationships/Item/GovernanceRelationshipItemRequestBuilder.cs new file mode 100644 index 00000000000..9c3da64eafa --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRelationships/Item/GovernanceRelationshipItemRequestBuilder.cs @@ -0,0 +1,229 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.Item +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\governanceRelationships\{governanceRelationship-id} + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRelationshipItemRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public GovernanceRelationshipItemRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRelationships/{governanceRelationship%2Did}{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public GovernanceRelationshipItemRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRelationships/{governanceRelationship%2Did}{?%24expand,%24select}", rawUrl) + { + } + /// + /// Delete navigation property governanceRelationships for directory + /// + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task DeleteAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task DeleteAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToDeleteRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get governanceRelationships from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Update the navigation property governanceRelationships in directory + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPatchRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Delete navigation property governanceRelationships for directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToDeleteRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToDeleteRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.DELETE, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Get governanceRelationships from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Update the navigation property governanceRelationships in directory + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.PATCH, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.Item.GovernanceRelationshipItemRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.Item.GovernanceRelationshipItemRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRelationshipItemRequestBuilderDeleteRequestConfiguration : RequestConfiguration + { + } + /// + /// Get governanceRelationships from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRelationshipItemRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRelationshipItemRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRelationshipItemRequestBuilderPatchRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/Count/CountRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/Count/CountRequestBuilder.cs new file mode 100644 index 00000000000..0433e0a35cb --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/Count/CountRequestBuilder.cs @@ -0,0 +1,124 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Count +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\governanceRequests\$count + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public CountRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRequests/$count{?%24filter,%24search}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public CountRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRequests/$count{?%24filter,%24search}", rawUrl) + { + } + /// + /// Get the number of the resource + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendPrimitiveAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get the number of the resource + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "text/plain;q=0.9"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Count.CountRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Count.CountRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get the number of the resource + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilderGetQueryParameters + { + /// Filter items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24filter")] + public string? Filter { get; set; } +#nullable restore +#else + [QueryParameter("%24filter")] + public string Filter { get; set; } +#endif + /// Search items by search phrases +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24search")] + public string? Search { get; set; } +#nullable restore +#else + [QueryParameter("%24search")] + public string Search { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/GovernanceRequestsRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/GovernanceRequestsRequestBuilder.cs new file mode 100644 index 00000000000..ef3f2324bab --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/GovernanceRequestsRequestBuilder.cs @@ -0,0 +1,238 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Count; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Item; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\governanceRequests + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRequestsRequestBuilder : BaseRequestBuilder + { + /// The Count property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Count.CountRequestBuilder Count + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Count.CountRequestBuilder(PathParameters, RequestAdapter); + } + /// Gets an item from the Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.directory.tenantGovernance.governanceRequests.item collection + /// Unique identifier of the item + /// A + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Item.GovernanceRequestItemRequestBuilder this[string position] + { + get + { + var urlTplParams = new Dictionary(PathParameters); + urlTplParams.Add("governanceRequest%2Did", position); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Item.GovernanceRequestItemRequestBuilder(urlTplParams, RequestAdapter); + } + } + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public GovernanceRequestsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRequests{?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public GovernanceRequestsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRequests{?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", rawUrl) + { + } + /// + /// Get governanceRequests from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequestCollectionResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Create new navigation property to governanceRequests for directory + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPostRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get governanceRequests from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Create new navigation property to governanceRequests for directory + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.POST, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.GovernanceRequestsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.GovernanceRequestsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get governanceRequests from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRequestsRequestBuilderGetQueryParameters + { + /// Include count of items + [QueryParameter("%24count")] + public bool? Count { get; set; } + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Filter items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24filter")] + public string? Filter { get; set; } +#nullable restore +#else + [QueryParameter("%24filter")] + public string Filter { get; set; } +#endif + /// Order items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24orderby")] + public string[]? Orderby { get; set; } +#nullable restore +#else + [QueryParameter("%24orderby")] + public string[] Orderby { get; set; } +#endif + /// Search items by search phrases +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24search")] + public string? Search { get; set; } +#nullable restore +#else + [QueryParameter("%24search")] + public string Search { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + /// Skip the first n items + [QueryParameter("%24skip")] + public int? Skip { get; set; } + /// Show only the first n items + [QueryParameter("%24top")] + public int? Top { get; set; } + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRequestsRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRequestsRequestBuilderPostRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/Item/GovernancePolicyTemplate/GovernancePolicyTemplateRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/Item/GovernancePolicyTemplate/GovernancePolicyTemplateRequestBuilder.cs new file mode 100644 index 00000000000..2b784121c8c --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/Item/GovernancePolicyTemplate/GovernancePolicyTemplateRequestBuilder.cs @@ -0,0 +1,125 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Item.GovernancePolicyTemplate +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\governanceRequests\{governanceRequest-id}\governancePolicyTemplate + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernancePolicyTemplateRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public GovernancePolicyTemplateRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRequests/{governanceRequest%2Did}/governancePolicyTemplate{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public GovernancePolicyTemplateRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRequests/{governanceRequest%2Did}/governancePolicyTemplate{?%24expand,%24select}", rawUrl) + { + } + /// + /// Get governancePolicyTemplate from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get governancePolicyTemplate from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Item.GovernancePolicyTemplate.GovernancePolicyTemplateRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Item.GovernancePolicyTemplate.GovernancePolicyTemplateRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get governancePolicyTemplate from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernancePolicyTemplateRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernancePolicyTemplateRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/Item/GovernanceRequestItemRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/Item/GovernanceRequestItemRequestBuilder.cs new file mode 100644 index 00000000000..aa8bd3b8399 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/GovernanceRequests/Item/GovernanceRequestItemRequestBuilder.cs @@ -0,0 +1,235 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Item.GovernancePolicyTemplate; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Item +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\governanceRequests\{governanceRequest-id} + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRequestItemRequestBuilder : BaseRequestBuilder + { + /// The governancePolicyTemplate property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Item.GovernancePolicyTemplate.GovernancePolicyTemplateRequestBuilder GovernancePolicyTemplate + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Item.GovernancePolicyTemplate.GovernancePolicyTemplateRequestBuilder(PathParameters, RequestAdapter); + } + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public GovernanceRequestItemRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRequests/{governanceRequest%2Did}{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public GovernanceRequestItemRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/governanceRequests/{governanceRequest%2Did}{?%24expand,%24select}", rawUrl) + { + } + /// + /// Delete navigation property governanceRequests for directory + /// + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task DeleteAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task DeleteAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToDeleteRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get governanceRequests from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Update the navigation property governanceRequests in directory + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPatchRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Delete navigation property governanceRequests for directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToDeleteRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToDeleteRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.DELETE, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Get governanceRequests from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Update the navigation property governanceRequests in directory + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.PATCH, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Item.GovernanceRequestItemRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.Item.GovernanceRequestItemRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRequestItemRequestBuilderDeleteRequestConfiguration : RequestConfiguration + { + } + /// + /// Get governanceRequests from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRequestItemRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRequestItemRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GovernanceRequestItemRequestBuilderPatchRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Count/CountRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Count/CountRequestBuilder.cs new file mode 100644 index 00000000000..4b08a570ccc --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Count/CountRequestBuilder.cs @@ -0,0 +1,124 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Count +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\relatedTenants\$count + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public CountRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/$count{?%24filter,%24search}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public CountRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/$count{?%24filter,%24search}", rawUrl) + { + } + /// + /// Get the number of the resource + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendPrimitiveAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get the number of the resource + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "text/plain;q=0.9"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Count.CountRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Count.CountRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get the number of the resource + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilderGetQueryParameters + { + /// Filter items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24filter")] + public string? Filter { get; set; } +#nullable restore +#else + [QueryParameter("%24filter")] + public string Filter { get; set; } +#endif + /// Search items by search phrases +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24search")] + public string? Search { get; set; } +#nullable restore +#else + [QueryParameter("%24search")] + public string Search { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/AppB2BSignInActivityMetrics/AppB2BSignInActivityMetricsRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/AppB2BSignInActivityMetrics/AppB2BSignInActivityMetricsRequestBuilder.cs new file mode 100644 index 00000000000..37547652c0e --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/AppB2BSignInActivityMetrics/AppB2BSignInActivityMetricsRequestBuilder.cs @@ -0,0 +1,125 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.AppB2BSignInActivityMetrics +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\relatedTenants\{relatedTenant-id}\appB2BSignInActivityMetrics + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class AppB2BSignInActivityMetricsRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public AppB2BSignInActivityMetricsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/{relatedTenant%2Did}/appB2BSignInActivityMetrics{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public AppB2BSignInActivityMetricsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/{relatedTenant%2Did}/appB2BSignInActivityMetrics{?%24expand,%24select}", rawUrl) + { + } + /// + /// Get appB2BSignInActivityMetrics from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get appB2BSignInActivityMetrics from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.AppB2BSignInActivityMetrics.AppB2BSignInActivityMetricsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.AppB2BSignInActivityMetrics.AppB2BSignInActivityMetricsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get appB2BSignInActivityMetrics from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class AppB2BSignInActivityMetricsRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class AppB2BSignInActivityMetricsRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/B2BRegistrationMetrics/B2BRegistrationMetricsRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/B2BRegistrationMetrics/B2BRegistrationMetricsRequestBuilder.cs new file mode 100644 index 00000000000..636ca927981 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/B2BRegistrationMetrics/B2BRegistrationMetricsRequestBuilder.cs @@ -0,0 +1,125 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.B2BRegistrationMetrics +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\relatedTenants\{relatedTenant-id}\b2BRegistrationMetrics + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class B2BRegistrationMetricsRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public B2BRegistrationMetricsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/{relatedTenant%2Did}/b2BRegistrationMetrics{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public B2BRegistrationMetricsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/{relatedTenant%2Did}/b2BRegistrationMetrics{?%24expand,%24select}", rawUrl) + { + } + /// + /// Get b2BRegistrationMetrics from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2bRegistrationMetrics.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get b2BRegistrationMetrics from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.B2BRegistrationMetrics.B2BRegistrationMetricsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.B2BRegistrationMetrics.B2BRegistrationMetricsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get b2BRegistrationMetrics from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class B2BRegistrationMetricsRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class B2BRegistrationMetricsRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/B2BSignInActivityMetrics/B2BSignInActivityMetricsRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/B2BSignInActivityMetrics/B2BSignInActivityMetricsRequestBuilder.cs new file mode 100644 index 00000000000..011406309f0 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/B2BSignInActivityMetrics/B2BSignInActivityMetricsRequestBuilder.cs @@ -0,0 +1,125 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.B2BSignInActivityMetrics +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\relatedTenants\{relatedTenant-id}\b2BSignInActivityMetrics + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class B2BSignInActivityMetricsRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public B2BSignInActivityMetricsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/{relatedTenant%2Did}/b2BSignInActivityMetrics{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public B2BSignInActivityMetricsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/{relatedTenant%2Did}/b2BSignInActivityMetrics{?%24expand,%24select}", rawUrl) + { + } + /// + /// Get b2BSignInActivityMetrics from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get b2BSignInActivityMetrics from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.B2BSignInActivityMetrics.B2BSignInActivityMetricsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.B2BSignInActivityMetrics.B2BSignInActivityMetricsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get b2BSignInActivityMetrics from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class B2BSignInActivityMetricsRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class B2BSignInActivityMetricsRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/BillingMetrics/BillingMetricsRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/BillingMetrics/BillingMetricsRequestBuilder.cs new file mode 100644 index 00000000000..f9f2e178c0d --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/BillingMetrics/BillingMetricsRequestBuilder.cs @@ -0,0 +1,125 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.BillingMetrics +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\relatedTenants\{relatedTenant-id}\billingMetrics + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class BillingMetricsRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public BillingMetricsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/{relatedTenant%2Did}/billingMetrics{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public BillingMetricsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/{relatedTenant%2Did}/billingMetrics{?%24expand,%24select}", rawUrl) + { + } + /// + /// Get billingMetrics from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetrics.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get billingMetrics from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.BillingMetrics.BillingMetricsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.BillingMetrics.BillingMetricsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get billingMetrics from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class BillingMetricsRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class BillingMetricsRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/MultiTenantApplicationMetrics/MultiTenantApplicationMetricsRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/MultiTenantApplicationMetrics/MultiTenantApplicationMetricsRequestBuilder.cs new file mode 100644 index 00000000000..3c8fecee43b --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/MultiTenantApplicationMetrics/MultiTenantApplicationMetricsRequestBuilder.cs @@ -0,0 +1,125 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.MultiTenantApplicationMetrics +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\relatedTenants\{relatedTenant-id}\multiTenantApplicationMetrics + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class MultiTenantApplicationMetricsRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public MultiTenantApplicationMetricsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/{relatedTenant%2Did}/multiTenantApplicationMetrics{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public MultiTenantApplicationMetricsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/{relatedTenant%2Did}/multiTenantApplicationMetrics{?%24expand,%24select}", rawUrl) + { + } + /// + /// Get multiTenantApplicationMetrics from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetrics.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get multiTenantApplicationMetrics from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.MultiTenantApplicationMetrics.MultiTenantApplicationMetricsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.MultiTenantApplicationMetrics.MultiTenantApplicationMetricsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get multiTenantApplicationMetrics from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class MultiTenantApplicationMetricsRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class MultiTenantApplicationMetricsRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/RelatedTenantItemRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/RelatedTenantItemRequestBuilder.cs new file mode 100644 index 00000000000..3c1eb0f42ad --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Item/RelatedTenantItemRequestBuilder.cs @@ -0,0 +1,259 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.AppB2BSignInActivityMetrics; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.B2BRegistrationMetrics; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.B2BSignInActivityMetrics; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.BillingMetrics; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.MultiTenantApplicationMetrics; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\relatedTenants\{relatedTenant-id} + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class RelatedTenantItemRequestBuilder : BaseRequestBuilder + { + /// The appB2BSignInActivityMetrics property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.AppB2BSignInActivityMetrics.AppB2BSignInActivityMetricsRequestBuilder AppB2BSignInActivityMetrics + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.AppB2BSignInActivityMetrics.AppB2BSignInActivityMetricsRequestBuilder(PathParameters, RequestAdapter); + } + /// The b2BRegistrationMetrics property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.B2BRegistrationMetrics.B2BRegistrationMetricsRequestBuilder B2BRegistrationMetrics + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.B2BRegistrationMetrics.B2BRegistrationMetricsRequestBuilder(PathParameters, RequestAdapter); + } + /// The b2BSignInActivityMetrics property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.B2BSignInActivityMetrics.B2BSignInActivityMetricsRequestBuilder B2BSignInActivityMetrics + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.B2BSignInActivityMetrics.B2BSignInActivityMetricsRequestBuilder(PathParameters, RequestAdapter); + } + /// The billingMetrics property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.BillingMetrics.BillingMetricsRequestBuilder BillingMetrics + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.BillingMetrics.BillingMetricsRequestBuilder(PathParameters, RequestAdapter); + } + /// The multiTenantApplicationMetrics property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.MultiTenantApplicationMetrics.MultiTenantApplicationMetricsRequestBuilder MultiTenantApplicationMetrics + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.MultiTenantApplicationMetrics.MultiTenantApplicationMetricsRequestBuilder(PathParameters, RequestAdapter); + } + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public RelatedTenantItemRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/{relatedTenant%2Did}{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public RelatedTenantItemRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/{relatedTenant%2Did}{?%24expand,%24select}", rawUrl) + { + } + /// + /// Delete navigation property relatedTenants for directory + /// + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task DeleteAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task DeleteAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToDeleteRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get relatedTenants from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Update the navigation property relatedTenants in directory + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPatchRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Delete navigation property relatedTenants for directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToDeleteRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToDeleteRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.DELETE, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Get relatedTenants from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Update the navigation property relatedTenants in directory + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.PATCH, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.RelatedTenantItemRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.RelatedTenantItemRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class RelatedTenantItemRequestBuilderDeleteRequestConfiguration : RequestConfiguration + { + } + /// + /// Get relatedTenants from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class RelatedTenantItemRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class RelatedTenantItemRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class RelatedTenantItemRequestBuilderPatchRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Refresh/RefreshRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Refresh/RefreshRequestBuilder.cs new file mode 100644 index 00000000000..82dabcfdbb5 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/Refresh/RefreshRequestBuilder.cs @@ -0,0 +1,96 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Refresh +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\relatedTenants\refresh + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class RefreshRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public RefreshRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/refresh", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public RefreshRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants/refresh", rawUrl) + { + } + /// + /// Invoke action refresh + /// + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PostAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PostAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToPostRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Invoke action refresh + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPostRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPostRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.POST, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Refresh.RefreshRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Refresh.RefreshRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class RefreshRequestBuilderPostRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/RelatedTenantsRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/RelatedTenantsRequestBuilder.cs new file mode 100644 index 00000000000..a7670a4ff13 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/RelatedTenants/RelatedTenantsRequestBuilder.cs @@ -0,0 +1,244 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Count; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Refresh; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\relatedTenants + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class RelatedTenantsRequestBuilder : BaseRequestBuilder + { + /// The Count property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Count.CountRequestBuilder Count + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Count.CountRequestBuilder(PathParameters, RequestAdapter); + } + /// The refresh property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Refresh.RefreshRequestBuilder Refresh + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Refresh.RefreshRequestBuilder(PathParameters, RequestAdapter); + } + /// Gets an item from the Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.directory.tenantGovernance.relatedTenants.item collection + /// Unique identifier of the item + /// A + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.RelatedTenantItemRequestBuilder this[string position] + { + get + { + var urlTplParams = new Dictionary(PathParameters); + urlTplParams.Add("relatedTenant%2Did", position); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.Item.RelatedTenantItemRequestBuilder(urlTplParams, RequestAdapter); + } + } + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public RelatedTenantsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants{?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public RelatedTenantsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/relatedTenants{?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", rawUrl) + { + } + /// + /// Get relatedTenants from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenantCollectionResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Create new navigation property to relatedTenants for directory + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPostRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get relatedTenants from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Create new navigation property to relatedTenants for directory + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.POST, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.RelatedTenantsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.RelatedTenantsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get relatedTenants from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class RelatedTenantsRequestBuilderGetQueryParameters + { + /// Include count of items + [QueryParameter("%24count")] + public bool? Count { get; set; } + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Filter items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24filter")] + public string? Filter { get; set; } +#nullable restore +#else + [QueryParameter("%24filter")] + public string Filter { get; set; } +#endif + /// Order items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24orderby")] + public string[]? Orderby { get; set; } +#nullable restore +#else + [QueryParameter("%24orderby")] + public string[] Orderby { get; set; } +#endif + /// Search items by search phrases +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24search")] + public string? Search { get; set; } +#nullable restore +#else + [QueryParameter("%24search")] + public string Search { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + /// Skip the first n items + [QueryParameter("%24skip")] + public int? Skip { get; set; } + /// Show only the first n items + [QueryParameter("%24top")] + public int? Top { get; set; } + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class RelatedTenantsRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class RelatedTenantsRequestBuilderPostRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/Settings/EnableRelatedTenants/EnableRelatedTenantsRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/Settings/EnableRelatedTenants/EnableRelatedTenantsRequestBuilder.cs new file mode 100644 index 00000000000..7d6cced1ad6 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/Settings/EnableRelatedTenants/EnableRelatedTenantsRequestBuilder.cs @@ -0,0 +1,96 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.Settings.EnableRelatedTenants +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\settings\enableRelatedTenants + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class EnableRelatedTenantsRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public EnableRelatedTenantsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/settings/enableRelatedTenants", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public EnableRelatedTenantsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/settings/enableRelatedTenants", rawUrl) + { + } + /// + /// Invoke action enableRelatedTenants + /// + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PostAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PostAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToPostRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Invoke action enableRelatedTenants + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPostRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPostRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.POST, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.Settings.EnableRelatedTenants.EnableRelatedTenantsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.Settings.EnableRelatedTenants.EnableRelatedTenantsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class EnableRelatedTenantsRequestBuilderPostRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/Settings/SettingsRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/Settings/SettingsRequestBuilder.cs new file mode 100644 index 00000000000..a8e457d5244 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/Settings/SettingsRequestBuilder.cs @@ -0,0 +1,235 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.Settings.EnableRelatedTenants; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.Settings +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance\settings + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class SettingsRequestBuilder : BaseRequestBuilder + { + /// The enableRelatedTenants property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.Settings.EnableRelatedTenants.EnableRelatedTenantsRequestBuilder EnableRelatedTenants + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.Settings.EnableRelatedTenants.EnableRelatedTenantsRequestBuilder(PathParameters, RequestAdapter); + } + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public SettingsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/settings{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public SettingsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance/settings{?%24expand,%24select}", rawUrl) + { + } + /// + /// Delete navigation property settings for directory + /// + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task DeleteAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task DeleteAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToDeleteRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get settings from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Update the navigation property settings in directory + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPatchRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Delete navigation property settings for directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToDeleteRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToDeleteRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.DELETE, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Get settings from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Update the navigation property settings in directory + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.PATCH, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.Settings.SettingsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.Settings.SettingsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class SettingsRequestBuilderDeleteRequestConfiguration : RequestConfiguration + { + } + /// + /// Get settings from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class SettingsRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class SettingsRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class SettingsRequestBuilderPatchRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/TenantGovernanceRequestBuilder.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/TenantGovernanceRequestBuilder.cs new file mode 100644 index 00000000000..6387c1ffbce --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/DirectoryNamespace/TenantGovernance/TenantGovernanceRequestBuilder.cs @@ -0,0 +1,265 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.Settings; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance +{ + /// + /// Builds and executes requests for operations under \directory\tenantGovernance + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class TenantGovernanceRequestBuilder : BaseRequestBuilder + { + /// The governanceInvitations property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.GovernanceInvitationsRequestBuilder GovernanceInvitations + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceInvitations.GovernanceInvitationsRequestBuilder(PathParameters, RequestAdapter); + } + /// The governancePolicyTemplates property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.GovernancePolicyTemplatesRequestBuilder GovernancePolicyTemplates + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernancePolicyTemplates.GovernancePolicyTemplatesRequestBuilder(PathParameters, RequestAdapter); + } + /// The governanceRelationships property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.GovernanceRelationshipsRequestBuilder GovernanceRelationships + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRelationships.GovernanceRelationshipsRequestBuilder(PathParameters, RequestAdapter); + } + /// The governanceRequests property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.GovernanceRequestsRequestBuilder GovernanceRequests + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.GovernanceRequests.GovernanceRequestsRequestBuilder(PathParameters, RequestAdapter); + } + /// The relatedTenants property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.RelatedTenantsRequestBuilder RelatedTenants + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.RelatedTenants.RelatedTenantsRequestBuilder(PathParameters, RequestAdapter); + } + /// The settings property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.Settings.SettingsRequestBuilder Settings + { + get => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.Settings.SettingsRequestBuilder(PathParameters, RequestAdapter); + } + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public TenantGovernanceRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public TenantGovernanceRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/directory/tenantGovernance{?%24expand,%24select}", rawUrl) + { + } + /// + /// Delete navigation property tenantGovernance for directory + /// + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task DeleteAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task DeleteAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToDeleteRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get tenantGovernance from directory + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Update the navigation property tenantGovernance in directory + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPatchRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Delete navigation property tenantGovernance for directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToDeleteRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToDeleteRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.DELETE, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Get tenantGovernance from directory + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Update the navigation property tenantGovernance in directory + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.PATCH, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.TenantGovernanceRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.DirectoryNamespace.TenantGovernance.TenantGovernanceRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class TenantGovernanceRequestBuilderDeleteRequestConfiguration : RequestConfiguration + { + } + /// + /// Get tenantGovernance from directory + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class TenantGovernanceRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class TenantGovernanceRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class TenantGovernanceRequestBuilderPatchRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Application.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Application.cs index 12d2760ad74..30cebd94dae 100644 --- a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Application.cs +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Application.cs @@ -60,7 +60,7 @@ public partial class Application : global::Microsoft.Graph.PowerShell.Identity.D #else public List AppRoles { get; set; } #endif - /// The authenticationBehaviors property + /// The set of breaking change behaviors related to token issuance that are configured for the application. Authentication behaviors are unset by default (null) and must be explicitly enabled or disabled. Nullable. Returned only on $select. Requires $select to retrieve. For more information about authentication behaviors, see Manage application authenticationBehaviors. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.AuthenticationBehaviors? AuthenticationBehaviors { get; set; } diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/ApplicationPermissionType.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/ApplicationPermissionType.cs new file mode 100644 index 00000000000..e1a85730209 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/ApplicationPermissionType.cs @@ -0,0 +1,21 @@ +// +using System.Runtime.Serialization; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public enum ApplicationPermissionType + #pragma warning restore CS1591 + { + /// Represents a type of permission that is for an app only scenario. No user is involved. + [EnumMember(Value = "role")] + Role, + /// Represents a type of permission that is for an app and user scenario. + [EnumMember(Value = "scope")] + Scope, + /// This will help in making this enum evolable and adding more values in the future- + [EnumMember(Value = "unknownFutureValue")] + UnknownFutureValue, + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/ApplicationResourcePermission.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/ApplicationResourcePermission.cs new file mode 100644 index 00000000000..d36ab334fb3 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/ApplicationResourcePermission.cs @@ -0,0 +1,89 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class ApplicationResourcePermission : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The id property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Id { get; set; } +#nullable restore +#else + public string Id { get; set; } +#endif + /// The name property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Name { get; set; } +#nullable restore +#else + public string Name { get; set; } +#endif + /// The OdataType property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? OdataType { get; set; } +#nullable restore +#else + public string OdataType { get; set; } +#endif + /// The type property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ApplicationPermissionType? Type { get; set; } + /// + /// Instantiates a new and sets the default values. + /// + public ApplicationResourcePermission() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ApplicationResourcePermission CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ApplicationResourcePermission(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "id", n => { Id = n.GetStringValue(); } }, + { "name", n => { Name = n.GetStringValue(); } }, + { "@odata.type", n => { OdataType = n.GetStringValue(); } }, + { "type", n => { Type = n.GetEnumValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteStringValue("id", Id); + writer.WriteStringValue("name", Name); + writer.WriteStringValue("@odata.type", OdataType); + writer.WriteEnumValue("type", Type); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/ApplicationsRequiredResourceAccess.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/ApplicationsRequiredResourceAccess.cs new file mode 100644 index 00000000000..383d8209fa9 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/ApplicationsRequiredResourceAccess.cs @@ -0,0 +1,85 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class ApplicationsRequiredResourceAccess : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The OdataType property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? OdataType { get; set; } +#nullable restore +#else + public string OdataType { get; set; } +#endif + /// The permissions property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Permissions { get; set; } +#nullable restore +#else + public List Permissions { get; set; } +#endif + /// The resourceAppId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? ResourceAppId { get; set; } +#nullable restore +#else + public string ResourceAppId { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public ApplicationsRequiredResourceAccess() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ApplicationsRequiredResourceAccess CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ApplicationsRequiredResourceAccess(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "@odata.type", n => { OdataType = n.GetStringValue(); } }, + { "permissions", n => { Permissions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ApplicationResourcePermission.CreateFromDiscriminatorValue)?.AsList(); } }, + { "resourceAppId", n => { ResourceAppId = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteStringValue("@odata.type", OdataType); + writer.WriteCollectionOfObjectValues("permissions", Permissions); + writer.WriteStringValue("resourceAppId", ResourceAppId); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs index c0b0163aa6d..f3c831d6066 100644 --- a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs @@ -14,8 +14,10 @@ public partial class AuthenticationBehaviors : IAdditionalDataHolder, IParsable { /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. public IDictionary AdditionalData { get; set; } - /// The blockAzureADGraphAccess property + /// If false, allows the app to have extended access to Azure AD Graph until August 31, 2025 when Azure AD Graph is fully retired. For more information on Azure AD retirement updates, see June 2024 update on Azure AD Graph API retirement. public bool? BlockAzureADGraphAccess { get; set; } + /// Indicates whether Cross-Origin-Opener-Policy (COOP) headers are enforced on browser-based authentication responses for the application. Set to true to enable enforcement, false to temporarily suppress enforcement, or null to use the service default. For how-to guidance, see Control Cross-Origin-Opener-Policy enforcement. + public bool? CoopEnforcement { get; set; } /// The OdataType property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable @@ -24,9 +26,9 @@ public partial class AuthenticationBehaviors : IAdditionalDataHolder, IParsable #else public string OdataType { get; set; } #endif - /// The removeUnverifiedEmailClaim property + /// If true, removes the email claim from tokens sent to an application when the email address's domain can't be verified. public bool? RemoveUnverifiedEmailClaim { get; set; } - /// The requireClientServicePrincipal property + /// If true, requires multitenant applications to have a service principal in the resource tenant as part of authorization checks before they're granted access tokens. This property is only modifiable for multitenant resource applications that rely on access from clients without a service principal and had this behavior as set to false by Microsoft. Tenant administrators should respond to security advisories sent through Azure Health Service events and the Microsoft 365 message center. public bool? RequireClientServicePrincipal { get; set; } /// /// Instantiates a new and sets the default values. @@ -54,6 +56,7 @@ public virtual IDictionary> GetFieldDeserializers() return new Dictionary> { { "blockAzureADGraphAccess", n => { BlockAzureADGraphAccess = n.GetBoolValue(); } }, + { "coopEnforcement", n => { CoopEnforcement = n.GetBoolValue(); } }, { "@odata.type", n => { OdataType = n.GetStringValue(); } }, { "removeUnverifiedEmailClaim", n => { RemoveUnverifiedEmailClaim = n.GetBoolValue(); } }, { "requireClientServicePrincipal", n => { RequireClientServicePrincipal = n.GetBoolValue(); } }, @@ -67,6 +70,7 @@ public virtual void Serialize(ISerializationWriter writer) { if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); writer.WriteBoolValue("blockAzureADGraphAccess", BlockAzureADGraphAccess); + writer.WriteBoolValue("coopEnforcement", CoopEnforcement); writer.WriteStringValue("@odata.type", OdataType); writer.WriteBoolValue("removeUnverifiedEmailClaim", RemoveUnverifiedEmailClaim); writer.WriteBoolValue("requireClientServicePrincipal", RequireClientServicePrincipal); diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BRegistrationMetricsBase.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BRegistrationMetricsBase.cs new file mode 100644 index 00000000000..742937419d6 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BRegistrationMetricsBase.cs @@ -0,0 +1,64 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class B2BRegistrationMetricsBase : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The inboundTotalUsers property + public decimal? InboundTotalUsers { get; set; } + /// The outboundTotalUsers property + public decimal? OutboundTotalUsers { get; set; } + /// The watermarkDateTime property + public DateTimeOffset? WatermarkDateTime { get; set; } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsBase CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + var mappingValue = parseNode.GetChildNode("@odata.type")?.GetStringValue(); + return mappingValue switch + { + "#microsoft.graph.b2BRegistrationMetricsInitial" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsInitial(), + "#microsoft.graph.b2BRegistrationMetricsRecent" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsRecent(), + _ => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsBase(), + }; + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "inboundTotalUsers", n => { InboundTotalUsers = n.GetDecimalValue(); } }, + { "outboundTotalUsers", n => { OutboundTotalUsers = n.GetDecimalValue(); } }, + { "watermarkDateTime", n => { WatermarkDateTime = n.GetDateTimeOffsetValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDecimalValue("inboundTotalUsers", InboundTotalUsers); + writer.WriteDecimalValue("outboundTotalUsers", OutboundTotalUsers); + writer.WriteDateTimeOffsetValue("watermarkDateTime", WatermarkDateTime); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BRegistrationMetricsInitial.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BRegistrationMetricsInitial.cs new file mode 100644 index 00000000000..8225451e0cb --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BRegistrationMetricsInitial.cs @@ -0,0 +1,57 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class B2BRegistrationMetricsInitial : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsBase, IParsable + #pragma warning restore CS1591 + { + /// The createdDateTime property + public DateTimeOffset? CreatedDateTime { get; set; } + /// + /// Instantiates a new and sets the default values. + /// + public B2BRegistrationMetricsInitial() : base() + { + OdataType = "#microsoft.graph.b2BRegistrationMetricsInitial"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsInitial CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsInitial(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "createdDateTime", n => { CreatedDateTime = n.GetDateTimeOffsetValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDateTimeOffsetValue("createdDateTime", CreatedDateTime); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BRegistrationMetricsRecent.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BRegistrationMetricsRecent.cs new file mode 100644 index 00000000000..1c6ca08e88c --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BRegistrationMetricsRecent.cs @@ -0,0 +1,57 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class B2BRegistrationMetricsRecent : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsBase, IParsable + #pragma warning restore CS1591 + { + /// The updateDateTime property + public DateTimeOffset? UpdateDateTime { get; set; } + /// + /// Instantiates a new and sets the default values. + /// + public B2BRegistrationMetricsRecent() : base() + { + OdataType = "#microsoft.graph.b2BRegistrationMetricsRecent"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsRecent CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsRecent(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "updateDateTime", n => { UpdateDateTime = n.GetDateTimeOffsetValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDateTimeOffsetValue("updateDateTime", UpdateDateTime); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetrics.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetrics.cs new file mode 100644 index 00000000000..4468f39912a --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetrics.cs @@ -0,0 +1,66 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class B2BSignInActivityMetrics : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The initial property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsInitial? Initial { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsInitial Initial { get; set; } +#endif + /// The recent property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsRecent? Recent { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsRecent Recent { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "initial", n => { Initial = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsInitial.CreateFromDiscriminatorValue); } }, + { "recent", n => { Recent = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsRecent.CreateFromDiscriminatorValue); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteObjectValue("initial", Initial); + writer.WriteObjectValue("recent", Recent); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetricsBase.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetricsBase.cs new file mode 100644 index 00000000000..f5e93c9ca9d --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetricsBase.cs @@ -0,0 +1,72 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class B2BSignInActivityMetricsBase : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The inboundMonthlyTotalApplications property + public decimal? InboundMonthlyTotalApplications { get; set; } + /// The inboundMonthlyTotalUsers property + public decimal? InboundMonthlyTotalUsers { get; set; } + /// The outboundMonthlyTotalApplications property + public decimal? OutboundMonthlyTotalApplications { get; set; } + /// The outboundMonthlyTotalUsers property + public decimal? OutboundMonthlyTotalUsers { get; set; } + /// The watermarkDateTime property + public DateTimeOffset? WatermarkDateTime { get; set; } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsBase CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + var mappingValue = parseNode.GetChildNode("@odata.type")?.GetStringValue(); + return mappingValue switch + { + "#microsoft.graph.b2BSignInActivityMetricsInitial" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsInitial(), + "#microsoft.graph.b2BSignInActivityMetricsRecent" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsRecent(), + _ => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsBase(), + }; + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "inboundMonthlyTotalApplications", n => { InboundMonthlyTotalApplications = n.GetDecimalValue(); } }, + { "inboundMonthlyTotalUsers", n => { InboundMonthlyTotalUsers = n.GetDecimalValue(); } }, + { "outboundMonthlyTotalApplications", n => { OutboundMonthlyTotalApplications = n.GetDecimalValue(); } }, + { "outboundMonthlyTotalUsers", n => { OutboundMonthlyTotalUsers = n.GetDecimalValue(); } }, + { "watermarkDateTime", n => { WatermarkDateTime = n.GetDateTimeOffsetValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDecimalValue("inboundMonthlyTotalApplications", InboundMonthlyTotalApplications); + writer.WriteDecimalValue("inboundMonthlyTotalUsers", InboundMonthlyTotalUsers); + writer.WriteDecimalValue("outboundMonthlyTotalApplications", OutboundMonthlyTotalApplications); + writer.WriteDecimalValue("outboundMonthlyTotalUsers", OutboundMonthlyTotalUsers); + writer.WriteDateTimeOffsetValue("watermarkDateTime", WatermarkDateTime); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetricsInitial.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetricsInitial.cs new file mode 100644 index 00000000000..f1012dd35c3 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetricsInitial.cs @@ -0,0 +1,57 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class B2BSignInActivityMetricsInitial : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsBase, IParsable + #pragma warning restore CS1591 + { + /// The createdDateTime property + public DateTimeOffset? CreatedDateTime { get; set; } + /// + /// Instantiates a new and sets the default values. + /// + public B2BSignInActivityMetricsInitial() : base() + { + OdataType = "#microsoft.graph.b2BSignInActivityMetricsInitial"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsInitial CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsInitial(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "createdDateTime", n => { CreatedDateTime = n.GetDateTimeOffsetValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDateTimeOffsetValue("createdDateTime", CreatedDateTime); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetricsRecent.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetricsRecent.cs new file mode 100644 index 00000000000..a8e04b8d778 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2BSignInActivityMetricsRecent.cs @@ -0,0 +1,57 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class B2BSignInActivityMetricsRecent : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsBase, IParsable + #pragma warning restore CS1591 + { + /// The updateDateTime property + public DateTimeOffset? UpdateDateTime { get; set; } + /// + /// Instantiates a new and sets the default values. + /// + public B2BSignInActivityMetricsRecent() : base() + { + OdataType = "#microsoft.graph.b2BSignInActivityMetricsRecent"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsRecent CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsRecent(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "updateDateTime", n => { UpdateDateTime = n.GetDateTimeOffsetValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDateTimeOffsetValue("updateDateTime", UpdateDateTime); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2bRegistrationMetrics.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2bRegistrationMetrics.cs new file mode 100644 index 00000000000..a2bf4435d28 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/B2bRegistrationMetrics.cs @@ -0,0 +1,66 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class B2bRegistrationMetrics : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The initial property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsInitial? Initial { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsInitial Initial { get; set; } +#endif + /// The recent property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsRecent? Recent { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsRecent Recent { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2bRegistrationMetrics CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2bRegistrationMetrics(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "initial", n => { Initial = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsInitial.CreateFromDiscriminatorValue); } }, + { "recent", n => { Recent = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsRecent.CreateFromDiscriminatorValue); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteObjectValue("initial", Initial); + writer.WriteObjectValue("recent", Recent); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetrics.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetrics.cs new file mode 100644 index 00000000000..e7209f9480e --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetrics.cs @@ -0,0 +1,66 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class BillingMetrics : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The initial property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsInitial? Initial { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsInitial Initial { get; set; } +#endif + /// The recent property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsRecent? Recent { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsRecent Recent { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetrics CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetrics(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "initial", n => { Initial = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsInitial.CreateFromDiscriminatorValue); } }, + { "recent", n => { Recent = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsRecent.CreateFromDiscriminatorValue); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteObjectValue("initial", Initial); + writer.WriteObjectValue("recent", Recent); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetricsBase.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetricsBase.cs new file mode 100644 index 00000000000..4e06676a0e8 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetricsBase.cs @@ -0,0 +1,90 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class BillingMetricsBase : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The foreignAssociatedTenantBillingManagementActiveCount property + public decimal? ForeignAssociatedTenantBillingManagementActiveCount { get; set; } + /// The foreignAssociatedTenantCount property + public decimal? ForeignAssociatedTenantCount { get; set; } + /// The foreignAssociatedTenantProvisioningActiveCount property + public decimal? ForeignAssociatedTenantProvisioningActiveCount { get; set; } + /// The localAssociatedTenantBillingManagementActiveCount property + public decimal? LocalAssociatedTenantBillingManagementActiveCount { get; set; } + /// The localAssociatedTenantCount property + public decimal? LocalAssociatedTenantCount { get; set; } + /// The localAssociatedTenantIds property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? LocalAssociatedTenantIds { get; set; } +#nullable restore +#else + public List LocalAssociatedTenantIds { get; set; } +#endif + /// The localAssociatedTenantProvisioningActiveCount property + public decimal? LocalAssociatedTenantProvisioningActiveCount { get; set; } + /// The watermarkDateTime property + public DateTimeOffset? WatermarkDateTime { get; set; } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsBase CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + var mappingValue = parseNode.GetChildNode("@odata.type")?.GetStringValue(); + return mappingValue switch + { + "#microsoft.graph.billingMetricsInitial" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsInitial(), + "#microsoft.graph.billingMetricsRecent" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsRecent(), + _ => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsBase(), + }; + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "foreignAssociatedTenantBillingManagementActiveCount", n => { ForeignAssociatedTenantBillingManagementActiveCount = n.GetDecimalValue(); } }, + { "foreignAssociatedTenantCount", n => { ForeignAssociatedTenantCount = n.GetDecimalValue(); } }, + { "foreignAssociatedTenantProvisioningActiveCount", n => { ForeignAssociatedTenantProvisioningActiveCount = n.GetDecimalValue(); } }, + { "localAssociatedTenantBillingManagementActiveCount", n => { LocalAssociatedTenantBillingManagementActiveCount = n.GetDecimalValue(); } }, + { "localAssociatedTenantCount", n => { LocalAssociatedTenantCount = n.GetDecimalValue(); } }, + { "localAssociatedTenantIds", n => { LocalAssociatedTenantIds = n.GetCollectionOfPrimitiveValues()?.AsList(); } }, + { "localAssociatedTenantProvisioningActiveCount", n => { LocalAssociatedTenantProvisioningActiveCount = n.GetDecimalValue(); } }, + { "watermarkDateTime", n => { WatermarkDateTime = n.GetDateTimeOffsetValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDecimalValue("foreignAssociatedTenantBillingManagementActiveCount", ForeignAssociatedTenantBillingManagementActiveCount); + writer.WriteDecimalValue("foreignAssociatedTenantCount", ForeignAssociatedTenantCount); + writer.WriteDecimalValue("foreignAssociatedTenantProvisioningActiveCount", ForeignAssociatedTenantProvisioningActiveCount); + writer.WriteDecimalValue("localAssociatedTenantBillingManagementActiveCount", LocalAssociatedTenantBillingManagementActiveCount); + writer.WriteDecimalValue("localAssociatedTenantCount", LocalAssociatedTenantCount); + writer.WriteCollectionOfPrimitiveValues("localAssociatedTenantIds", LocalAssociatedTenantIds); + writer.WriteDecimalValue("localAssociatedTenantProvisioningActiveCount", LocalAssociatedTenantProvisioningActiveCount); + writer.WriteDateTimeOffsetValue("watermarkDateTime", WatermarkDateTime); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetricsInitial.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetricsInitial.cs new file mode 100644 index 00000000000..fdadd44dbc6 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetricsInitial.cs @@ -0,0 +1,50 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class BillingMetricsInitial : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsBase, IParsable + #pragma warning restore CS1591 + { + /// The createdDateTime property + public DateTimeOffset? CreatedDateTime { get; set; } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsInitial CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsInitial(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "createdDateTime", n => { CreatedDateTime = n.GetDateTimeOffsetValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDateTimeOffsetValue("createdDateTime", CreatedDateTime); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetricsRecent.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetricsRecent.cs new file mode 100644 index 00000000000..aa82edfc097 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/BillingMetricsRecent.cs @@ -0,0 +1,50 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class BillingMetricsRecent : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsBase, IParsable + #pragma warning restore CS1591 + { + /// The updateDateTime property + public DateTimeOffset? UpdateDateTime { get; set; } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsRecent CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsRecent(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "updateDateTime", n => { UpdateDateTime = n.GetDateTimeOffsetValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDateTimeOffsetValue("updateDateTime", UpdateDateTime); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/DelegatedAdministrationRoleAssignment.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/DelegatedAdministrationRoleAssignment.cs new file mode 100644 index 00000000000..9f894a03445 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/DelegatedAdministrationRoleAssignment.cs @@ -0,0 +1,95 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class DelegatedAdministrationRoleAssignment : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The group property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Group? Group { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Group Group { get; set; } +#endif + /// The groupDisplayName property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GroupDisplayName { get; set; } +#nullable restore +#else + public string GroupDisplayName { get; set; } +#endif + /// The OdataType property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? OdataType { get; set; } +#nullable restore +#else + public string OdataType { get; set; } +#endif + /// The roleTemplates property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? RoleTemplates { get; set; } +#nullable restore +#else + public List RoleTemplates { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public DelegatedAdministrationRoleAssignment() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.DelegatedAdministrationRoleAssignment CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.DelegatedAdministrationRoleAssignment(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "group", n => { Group = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Group.CreateFromDiscriminatorValue); } }, + { "groupDisplayName", n => { GroupDisplayName = n.GetStringValue(); } }, + { "@odata.type", n => { OdataType = n.GetStringValue(); } }, + { "roleTemplates", n => { RoleTemplates = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RoleTemplate.CreateFromDiscriminatorValue)?.AsList(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteObjectValue("group", Group); + writer.WriteStringValue("groupDisplayName", GroupDisplayName); + writer.WriteStringValue("@odata.type", OdataType); + writer.WriteCollectionOfObjectValues("roleTemplates", RoleTemplates); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/DelegatedAdministrationRoleAssignmentSnapshot.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/DelegatedAdministrationRoleAssignmentSnapshot.cs new file mode 100644 index 00000000000..3f4e489b96b --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/DelegatedAdministrationRoleAssignmentSnapshot.cs @@ -0,0 +1,95 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class DelegatedAdministrationRoleAssignmentSnapshot : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The groupDisplayName property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GroupDisplayName { get; set; } +#nullable restore +#else + public string GroupDisplayName { get; set; } +#endif + /// The groupId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GroupId { get; set; } +#nullable restore +#else + public string GroupId { get; set; } +#endif + /// The OdataType property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? OdataType { get; set; } +#nullable restore +#else + public string OdataType { get; set; } +#endif + /// The roleTemplates property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? RoleTemplates { get; set; } +#nullable restore +#else + public List RoleTemplates { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public DelegatedAdministrationRoleAssignmentSnapshot() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.DelegatedAdministrationRoleAssignmentSnapshot CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.DelegatedAdministrationRoleAssignmentSnapshot(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "groupDisplayName", n => { GroupDisplayName = n.GetStringValue(); } }, + { "groupId", n => { GroupId = n.GetStringValue(); } }, + { "@odata.type", n => { OdataType = n.GetStringValue(); } }, + { "roleTemplates", n => { RoleTemplates = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RoleTemplate.CreateFromDiscriminatorValue)?.AsList(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteStringValue("groupDisplayName", GroupDisplayName); + writer.WriteStringValue("groupId", GroupId); + writer.WriteStringValue("@odata.type", OdataType); + writer.WriteCollectionOfObjectValues("roleTemplates", RoleTemplates); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/DirectoryObject1.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/DirectoryObject1.cs index 46a9d823f1e..a223af50aca 100644 --- a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/DirectoryObject1.cs +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/DirectoryObject1.cs @@ -100,6 +100,14 @@ public partial class DirectoryObject1 : global::Microsoft.Graph.PowerShell.Ident #nullable restore #else public List Subscriptions { get; set; } +#endif + /// The tenantGovernance property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance? TenantGovernance { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance TenantGovernance { get; set; } #endif /// /// Creates a new instance of the appropriate class based on discriminator value @@ -130,6 +138,7 @@ public override IDictionary> GetFieldDeserializers() { "recovery", n => { Recovery = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.EntraRecoveryServices.Recovery.CreateFromDiscriminatorValue); } }, { "remoteTenantGroups", n => { RemoteTenantGroups = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RemoteTenantGroup.CreateFromDiscriminatorValue)?.AsList(); } }, { "subscriptions", n => { Subscriptions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.CompanySubscription.CreateFromDiscriminatorValue)?.AsList(); } }, + { "tenantGovernance", n => { TenantGovernance = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance.CreateFromDiscriminatorValue); } }, }; } /// @@ -151,6 +160,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteObjectValue("recovery", Recovery); writer.WriteCollectionOfObjectValues("remoteTenantGroups", RemoteTenantGroups); writer.WriteCollectionOfObjectValues("subscriptions", Subscriptions); + writer.WriteObjectValue("tenantGovernance", TenantGovernance); } } } diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Entity.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Entity.cs index f519a16e039..1eadc313de5 100644 --- a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Entity.cs @@ -68,9 +68,21 @@ public Entity() "#microsoft.graph.attributeSet" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.AttributeSet(), "#microsoft.graph.authentication" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Authentication(), "#microsoft.graph.authenticationMethod" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.AuthenticationMethod(), + "#microsoft.graph.b2bRegistrationMetrics" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2bRegistrationMetrics(), + "#microsoft.graph.b2BRegistrationMetricsBase" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsBase(), + "#microsoft.graph.b2BRegistrationMetricsInitial" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsInitial(), + "#microsoft.graph.b2BRegistrationMetricsRecent" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BRegistrationMetricsRecent(), + "#microsoft.graph.b2BSignInActivityMetrics" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics(), + "#microsoft.graph.b2BSignInActivityMetricsBase" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsBase(), + "#microsoft.graph.b2BSignInActivityMetricsInitial" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsInitial(), + "#microsoft.graph.b2BSignInActivityMetricsRecent" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetricsRecent(), "#microsoft.graph.baseItem" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BaseItem(), "#microsoft.graph.baseItemVersion" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BaseItemVersion(), "#microsoft.graph.baseSitePage" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BaseSitePage(), + "#microsoft.graph.billingMetrics" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetrics(), + "#microsoft.graph.billingMetricsBase" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsBase(), + "#microsoft.graph.billingMetricsInitial" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsInitial(), + "#microsoft.graph.billingMetricsRecent" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetricsRecent(), "#microsoft.graph.bulkUpload" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BulkUpload(), "#microsoft.graph.calendar" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Calendar(), "#microsoft.graph.calendarGroup" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.CalendarGroup(), @@ -142,6 +154,9 @@ public Entity() "#microsoft.graph.federatedIdentityCredential" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.FederatedIdentityCredential(), "#microsoft.graph.fido2AuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Fido2AuthenticationMethod(), "#microsoft.graph.fieldValueSet" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.FieldValueSet(), + "#microsoft.graph.governanceInvitation" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation(), + "#microsoft.graph.governanceRelationship" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship(), + "#microsoft.graph.governanceRequest" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest(), "#microsoft.graph.group" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Group(), "#microsoft.graph.groupLifecyclePolicy" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GroupLifecyclePolicy(), "#microsoft.graph.groupSetting" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GroupSetting(), @@ -172,7 +187,12 @@ public Entity() "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Message(), "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), + "#microsoft.graph.multiTenantApplicationMetrics" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetrics(), + "#microsoft.graph.multiTenantApplicationMetricsBase" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsBase(), + "#microsoft.graph.multiTenantApplicationMetricsInitial" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsInitial(), + "#microsoft.graph.multiTenantApplicationMetricsRecent" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsRecent(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.OfferShiftRequest(), @@ -235,6 +255,7 @@ public Entity() "#microsoft.graph.profileSource" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ProfileSource(), "#microsoft.graph.pronounsSettings" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.PronounsSettings(), "#microsoft.graph.publicKeyInfrastructureRoot" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.PublicKeyInfrastructureRoot(), + "#microsoft.graph.relatedTenant" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant(), "#microsoft.graph.remoteDesktopSecurityConfiguration" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RemoteDesktopSecurityConfiguration(), "#microsoft.graph.remoteTenantGroup" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RemoteTenantGroup(), "#microsoft.graph.resourceSpecificPermissionGrant" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ResourceSpecificPermissionGrant(), @@ -279,6 +300,9 @@ public Entity() "#microsoft.graph.teamworkTag" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TeamworkTag(), "#microsoft.graph.teamworkTagMember" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TeamworkTagMember(), "#microsoft.graph.temporaryAccessPassAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TemporaryAccessPassAuthenticationMethod(), + "#microsoft.graph.tenantGovernance" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance(), + "#microsoft.graph.tenantGovernancePolicyTemplate" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate(), + "#microsoft.graph.tenantGovernanceSetting" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting(), "#microsoft.graph.termStore.group" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TermStore.Group(), "#microsoft.graph.termStore.relation" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TermStore.Relation(), "#microsoft.graph.termStore.set" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TermStore.Set(), diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceInvitation.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceInvitation.cs new file mode 100644 index 00000000000..b18c36c2711 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceInvitation.cs @@ -0,0 +1,94 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class GovernanceInvitation : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The createdDateTime property + public DateTimeOffset? CreatedDateTime { get; set; } + /// The expirationDateTime property + public DateTimeOffset? ExpirationDateTime { get; set; } + /// The governedTenantId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GovernedTenantId { get; set; } +#nullable restore +#else + public string GovernedTenantId { get; set; } +#endif + /// The governedTenantName property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GovernedTenantName { get; set; } +#nullable restore +#else + public string GovernedTenantName { get; set; } +#endif + /// The governingTenantId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GoverningTenantId { get; set; } +#nullable restore +#else + public string GoverningTenantId { get; set; } +#endif + /// The governingTenantName property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GoverningTenantName { get; set; } +#nullable restore +#else + public string GoverningTenantName { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "createdDateTime", n => { CreatedDateTime = n.GetDateTimeOffsetValue(); } }, + { "expirationDateTime", n => { ExpirationDateTime = n.GetDateTimeOffsetValue(); } }, + { "governedTenantId", n => { GovernedTenantId = n.GetStringValue(); } }, + { "governedTenantName", n => { GovernedTenantName = n.GetStringValue(); } }, + { "governingTenantId", n => { GoverningTenantId = n.GetStringValue(); } }, + { "governingTenantName", n => { GoverningTenantName = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDateTimeOffsetValue("createdDateTime", CreatedDateTime); + writer.WriteDateTimeOffsetValue("expirationDateTime", ExpirationDateTime); + writer.WriteStringValue("governedTenantId", GovernedTenantId); + writer.WriteStringValue("governedTenantName", GovernedTenantName); + writer.WriteStringValue("governingTenantId", GoverningTenantId); + writer.WriteStringValue("governingTenantName", GoverningTenantName); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceInvitationCollectionResponse.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceInvitationCollectionResponse.cs new file mode 100644 index 00000000000..3bb8978ffe0 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceInvitationCollectionResponse.cs @@ -0,0 +1,56 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class GovernanceInvitationCollectionResponse : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BaseCollectionPaginationCountResponse, IParsable + #pragma warning restore CS1591 + { + /// The value property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Value { get; set; } +#nullable restore +#else + public List Value { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitationCollectionResponse CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitationCollectionResponse(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "value", n => { Value = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation.CreateFromDiscriminatorValue)?.AsList(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("value", Value); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRelationship.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRelationship.cs new file mode 100644 index 00000000000..5a812c0bc22 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRelationship.cs @@ -0,0 +1,108 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class GovernanceRelationship : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The createdType property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipCreationType? CreatedType { get; set; } + /// The creationDateTime property + public DateTimeOffset? CreationDateTime { get; set; } + /// The governedTenantId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GovernedTenantId { get; set; } +#nullable restore +#else + public string GovernedTenantId { get; set; } +#endif + /// The governedTenantName property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GovernedTenantName { get; set; } +#nullable restore +#else + public string GovernedTenantName { get; set; } +#endif + /// The governingTenantId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GoverningTenantId { get; set; } +#nullable restore +#else + public string GoverningTenantId { get; set; } +#endif + /// The governingTenantName property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GoverningTenantName { get; set; } +#nullable restore +#else + public string GoverningTenantName { get; set; } +#endif + /// The policySnapshot property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipPolicy? PolicySnapshot { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipPolicy PolicySnapshot { get; set; } +#endif + /// The status property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipStatus? Status { get; set; } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "createdType", n => { CreatedType = n.GetEnumValue(); } }, + { "creationDateTime", n => { CreationDateTime = n.GetDateTimeOffsetValue(); } }, + { "governedTenantId", n => { GovernedTenantId = n.GetStringValue(); } }, + { "governedTenantName", n => { GovernedTenantName = n.GetStringValue(); } }, + { "governingTenantId", n => { GoverningTenantId = n.GetStringValue(); } }, + { "governingTenantName", n => { GoverningTenantName = n.GetStringValue(); } }, + { "policySnapshot", n => { PolicySnapshot = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipPolicy.CreateFromDiscriminatorValue); } }, + { "status", n => { Status = n.GetEnumValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteEnumValue("createdType", CreatedType); + writer.WriteDateTimeOffsetValue("creationDateTime", CreationDateTime); + writer.WriteStringValue("governedTenantId", GovernedTenantId); + writer.WriteStringValue("governedTenantName", GovernedTenantName); + writer.WriteStringValue("governingTenantId", GoverningTenantId); + writer.WriteStringValue("governingTenantName", GoverningTenantName); + writer.WriteObjectValue("policySnapshot", PolicySnapshot); + writer.WriteEnumValue("status", Status); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRelationshipCollectionResponse.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRelationshipCollectionResponse.cs new file mode 100644 index 00000000000..d0324bc7742 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRelationshipCollectionResponse.cs @@ -0,0 +1,56 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class GovernanceRelationshipCollectionResponse : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BaseCollectionPaginationCountResponse, IParsable + #pragma warning restore CS1591 + { + /// The value property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Value { get; set; } +#nullable restore +#else + public List Value { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationshipCollectionResponse CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationshipCollectionResponse(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "value", n => { Value = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship.CreateFromDiscriminatorValue)?.AsList(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("value", Value); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRequest.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRequest.cs new file mode 100644 index 00000000000..6c1b9383239 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRequest.cs @@ -0,0 +1,118 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class GovernanceRequest : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The expirationDateTime property + public DateTimeOffset? ExpirationDateTime { get; set; } + /// The governancePolicyTemplate property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate? GovernancePolicyTemplate { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate GovernancePolicyTemplate { get; set; } +#endif + /// The governedTenantId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GovernedTenantId { get; set; } +#nullable restore +#else + public string GovernedTenantId { get; set; } +#endif + /// The governedTenantName property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GovernedTenantName { get; set; } +#nullable restore +#else + public string GovernedTenantName { get; set; } +#endif + /// The governingTenantId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GoverningTenantId { get; set; } +#nullable restore +#else + public string GoverningTenantId { get; set; } +#endif + /// The governingTenantName property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? GoverningTenantName { get; set; } +#nullable restore +#else + public string GoverningTenantName { get; set; } +#endif + /// The policySnapshot property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipPolicy? PolicySnapshot { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipPolicy PolicySnapshot { get; set; } +#endif + /// The requestDateTime property + public DateTimeOffset? RequestDateTime { get; set; } + /// The status property + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RequestStatus? Status { get; set; } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "expirationDateTime", n => { ExpirationDateTime = n.GetDateTimeOffsetValue(); } }, + { "governancePolicyTemplate", n => { GovernancePolicyTemplate = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate.CreateFromDiscriminatorValue); } }, + { "governedTenantId", n => { GovernedTenantId = n.GetStringValue(); } }, + { "governedTenantName", n => { GovernedTenantName = n.GetStringValue(); } }, + { "governingTenantId", n => { GoverningTenantId = n.GetStringValue(); } }, + { "governingTenantName", n => { GoverningTenantName = n.GetStringValue(); } }, + { "policySnapshot", n => { PolicySnapshot = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipPolicy.CreateFromDiscriminatorValue); } }, + { "requestDateTime", n => { RequestDateTime = n.GetDateTimeOffsetValue(); } }, + { "status", n => { Status = n.GetEnumValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDateTimeOffsetValue("expirationDateTime", ExpirationDateTime); + writer.WriteObjectValue("governancePolicyTemplate", GovernancePolicyTemplate); + writer.WriteStringValue("governedTenantId", GovernedTenantId); + writer.WriteStringValue("governedTenantName", GovernedTenantName); + writer.WriteStringValue("governingTenantId", GoverningTenantId); + writer.WriteStringValue("governingTenantName", GoverningTenantName); + writer.WriteObjectValue("policySnapshot", PolicySnapshot); + writer.WriteDateTimeOffsetValue("requestDateTime", RequestDateTime); + writer.WriteEnumValue("status", Status); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRequestCollectionResponse.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRequestCollectionResponse.cs new file mode 100644 index 00000000000..5b88b218f17 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/GovernanceRequestCollectionResponse.cs @@ -0,0 +1,56 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class GovernanceRequestCollectionResponse : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BaseCollectionPaginationCountResponse, IParsable + #pragma warning restore CS1591 + { + /// The value property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Value { get; set; } +#nullable restore +#else + public List Value { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequestCollectionResponse CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequestCollectionResponse(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "value", n => { Value = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest.CreateFromDiscriminatorValue)?.AsList(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("value", Value); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Group.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Group.cs index 017483437cd..e914c05090f 100644 --- a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Identity.Directo #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetrics.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetrics.cs new file mode 100644 index 00000000000..83213e296f6 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetrics.cs @@ -0,0 +1,66 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class MultiTenantApplicationMetrics : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The initial property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsInitial? Initial { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsInitial Initial { get; set; } +#endif + /// The recent property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsRecent? Recent { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsRecent Recent { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetrics CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetrics(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "initial", n => { Initial = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsInitial.CreateFromDiscriminatorValue); } }, + { "recent", n => { Recent = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsRecent.CreateFromDiscriminatorValue); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteObjectValue("initial", Initial); + writer.WriteObjectValue("recent", Recent); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetricsBase.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetricsBase.cs new file mode 100644 index 00000000000..3369ac362ce --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetricsBase.cs @@ -0,0 +1,64 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class MultiTenantApplicationMetricsBase : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The inboundMonthlyTotalApplications property + public decimal? InboundMonthlyTotalApplications { get; set; } + /// The outboundMonthlyTotalApplications property + public decimal? OutboundMonthlyTotalApplications { get; set; } + /// The watermarkDateTime property + public DateTimeOffset? WatermarkDateTime { get; set; } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsBase CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + var mappingValue = parseNode.GetChildNode("@odata.type")?.GetStringValue(); + return mappingValue switch + { + "#microsoft.graph.multiTenantApplicationMetricsInitial" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsInitial(), + "#microsoft.graph.multiTenantApplicationMetricsRecent" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsRecent(), + _ => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsBase(), + }; + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "inboundMonthlyTotalApplications", n => { InboundMonthlyTotalApplications = n.GetDecimalValue(); } }, + { "outboundMonthlyTotalApplications", n => { OutboundMonthlyTotalApplications = n.GetDecimalValue(); } }, + { "watermarkDateTime", n => { WatermarkDateTime = n.GetDateTimeOffsetValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDecimalValue("inboundMonthlyTotalApplications", InboundMonthlyTotalApplications); + writer.WriteDecimalValue("outboundMonthlyTotalApplications", OutboundMonthlyTotalApplications); + writer.WriteDateTimeOffsetValue("watermarkDateTime", WatermarkDateTime); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetricsInitial.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetricsInitial.cs new file mode 100644 index 00000000000..2e29124f899 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetricsInitial.cs @@ -0,0 +1,50 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class MultiTenantApplicationMetricsInitial : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsBase, IParsable + #pragma warning restore CS1591 + { + /// The createdDateTime property + public DateTimeOffset? CreatedDateTime { get; set; } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsInitial CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsInitial(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "createdDateTime", n => { CreatedDateTime = n.GetDateTimeOffsetValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDateTimeOffsetValue("createdDateTime", CreatedDateTime); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetricsRecent.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetricsRecent.cs new file mode 100644 index 00000000000..79855b8abb7 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationMetricsRecent.cs @@ -0,0 +1,50 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class MultiTenantApplicationMetricsRecent : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsBase, IParsable + #pragma warning restore CS1591 + { + /// The updateDateTime property + public DateTimeOffset? UpdateDateTime { get; set; } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsRecent CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetricsRecent(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "updateDateTime", n => { UpdateDateTime = n.GetDateTimeOffsetValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDateTimeOffsetValue("updateDateTime", UpdateDateTime); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationsToProvision.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationsToProvision.cs new file mode 100644 index 00000000000..5c3f09df4fb --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationsToProvision.cs @@ -0,0 +1,105 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class MultiTenantApplicationsToProvision : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The appId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? AppId { get; set; } +#nullable restore +#else + public string AppId { get; set; } +#endif + /// The displayName property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? DisplayName { get; set; } +#nullable restore +#else + public string DisplayName { get; set; } +#endif + /// The objectId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? ObjectId { get; set; } +#nullable restore +#else + public string ObjectId { get; set; } +#endif + /// The OdataType property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? OdataType { get; set; } +#nullable restore +#else + public string OdataType { get; set; } +#endif + /// The requiredResourceAccesses property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? RequiredResourceAccesses { get; set; } +#nullable restore +#else + public List RequiredResourceAccesses { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public MultiTenantApplicationsToProvision() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationsToProvision CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationsToProvision(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "appId", n => { AppId = n.GetStringValue(); } }, + { "displayName", n => { DisplayName = n.GetStringValue(); } }, + { "objectId", n => { ObjectId = n.GetStringValue(); } }, + { "@odata.type", n => { OdataType = n.GetStringValue(); } }, + { "requiredResourceAccesses", n => { RequiredResourceAccesses = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ApplicationsRequiredResourceAccess.CreateFromDiscriminatorValue)?.AsList(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteStringValue("appId", AppId); + writer.WriteStringValue("displayName", DisplayName); + writer.WriteStringValue("objectId", ObjectId); + writer.WriteStringValue("@odata.type", OdataType); + writer.WriteCollectionOfObjectValues("requiredResourceAccesses", RequiredResourceAccesses); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationsToProvisionSnapshot.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationsToProvisionSnapshot.cs new file mode 100644 index 00000000000..e9fc8e2b95d --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/MultiTenantApplicationsToProvisionSnapshot.cs @@ -0,0 +1,105 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class MultiTenantApplicationsToProvisionSnapshot : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The appId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? AppId { get; set; } +#nullable restore +#else + public string AppId { get; set; } +#endif + /// The displayName property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? DisplayName { get; set; } +#nullable restore +#else + public string DisplayName { get; set; } +#endif + /// The objectId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? ObjectId { get; set; } +#nullable restore +#else + public string ObjectId { get; set; } +#endif + /// The OdataType property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? OdataType { get; set; } +#nullable restore +#else + public string OdataType { get; set; } +#endif + /// The requiredResourceAccesses property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? RequiredResourceAccesses { get; set; } +#nullable restore +#else + public List RequiredResourceAccesses { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public MultiTenantApplicationsToProvisionSnapshot() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationsToProvisionSnapshot CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationsToProvisionSnapshot(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "appId", n => { AppId = n.GetStringValue(); } }, + { "displayName", n => { DisplayName = n.GetStringValue(); } }, + { "objectId", n => { ObjectId = n.GetStringValue(); } }, + { "@odata.type", n => { OdataType = n.GetStringValue(); } }, + { "requiredResourceAccesses", n => { RequiredResourceAccesses = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ApplicationsRequiredResourceAccess.CreateFromDiscriminatorValue)?.AsList(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteStringValue("appId", AppId); + writer.WriteStringValue("displayName", DisplayName); + writer.WriteStringValue("objectId", ObjectId); + writer.WriteStringValue("@odata.type", OdataType); + writer.WriteCollectionOfObjectValues("requiredResourceAccesses", RequiredResourceAccesses); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Note.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..54d6079181b --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/OutlookItem.cs index da038ae1a8a..a7edfee3fe1 100644 --- a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Identity.D "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.OutlookItem(), }; diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelatedTenant.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelatedTenant.cs new file mode 100644 index 00000000000..77c15b78ee1 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelatedTenant.cs @@ -0,0 +1,103 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class RelatedTenant : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The appB2BSignInActivityMetrics property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics? AppB2BSignInActivityMetrics { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics AppB2BSignInActivityMetrics { get; set; } +#endif + /// The b2BRegistrationMetrics property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2bRegistrationMetrics? B2BRegistrationMetrics { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2bRegistrationMetrics B2BRegistrationMetrics { get; set; } +#endif + /// The b2BSignInActivityMetrics property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics? B2BSignInActivityMetrics { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics B2BSignInActivityMetrics { get; set; } +#endif + /// The billingMetrics property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetrics? BillingMetrics { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetrics BillingMetrics { get; set; } +#endif + /// The createdDateTime property + public DateTimeOffset? CreatedDateTime { get; set; } + /// Indicates whether this tenant is a Microsoft infrastructure tenant. + public bool? IsMicrosoftInfrastructure { get; private set; } + /// The multiTenantApplicationMetrics property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetrics? MultiTenantApplicationMetrics { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetrics MultiTenantApplicationMetrics { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "appB2BSignInActivityMetrics", n => { AppB2BSignInActivityMetrics = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics.CreateFromDiscriminatorValue); } }, + { "b2BRegistrationMetrics", n => { B2BRegistrationMetrics = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2bRegistrationMetrics.CreateFromDiscriminatorValue); } }, + { "b2BSignInActivityMetrics", n => { B2BSignInActivityMetrics = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics.CreateFromDiscriminatorValue); } }, + { "billingMetrics", n => { BillingMetrics = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetrics.CreateFromDiscriminatorValue); } }, + { "createdDateTime", n => { CreatedDateTime = n.GetDateTimeOffsetValue(); } }, + { "isMicrosoftInfrastructure", n => { IsMicrosoftInfrastructure = n.GetBoolValue(); } }, + { "multiTenantApplicationMetrics", n => { MultiTenantApplicationMetrics = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetrics.CreateFromDiscriminatorValue); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteObjectValue("appB2BSignInActivityMetrics", AppB2BSignInActivityMetrics); + writer.WriteObjectValue("b2BRegistrationMetrics", B2BRegistrationMetrics); + writer.WriteObjectValue("b2BSignInActivityMetrics", B2BSignInActivityMetrics); + writer.WriteObjectValue("billingMetrics", BillingMetrics); + writer.WriteDateTimeOffsetValue("createdDateTime", CreatedDateTime); + writer.WriteObjectValue("multiTenantApplicationMetrics", MultiTenantApplicationMetrics); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelatedTenantCollectionResponse.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelatedTenantCollectionResponse.cs new file mode 100644 index 00000000000..5352674555f --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelatedTenantCollectionResponse.cs @@ -0,0 +1,56 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class RelatedTenantCollectionResponse : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BaseCollectionPaginationCountResponse, IParsable + #pragma warning restore CS1591 + { + /// The value property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Value { get; set; } +#nullable restore +#else + public List Value { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenantCollectionResponse CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenantCollectionResponse(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "value", n => { Value = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant.CreateFromDiscriminatorValue)?.AsList(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("value", Value); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelationshipCreationType.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelationshipCreationType.cs new file mode 100644 index 00000000000..e54c2e63d51 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelationshipCreationType.cs @@ -0,0 +1,21 @@ +// +using System.Runtime.Serialization; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public enum RelationshipCreationType + #pragma warning restore CS1591 + { + /// Represents a relationship between two tenants that was created by an explicit approval from the governed tenant admin. + [EnumMember(Value = "approvedByAdmin")] + ApprovedByAdmin, + /// Represents a relationship between the add-on tenant and the tenant from which it was created. + [EnumMember(Value = "addOnTenant")] + AddOnTenant, + /// This will help in making this enum evolvable and adding more values in the future- + [EnumMember(Value = "unknownFutureValue")] + UnknownFutureValue, + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelationshipPolicy.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelationshipPolicy.cs new file mode 100644 index 00000000000..3468533be2d --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelationshipPolicy.cs @@ -0,0 +1,102 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class RelationshipPolicy : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The delegatedAdministrationRoleAssignments property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? DelegatedAdministrationRoleAssignments { get; set; } +#nullable restore +#else + public List DelegatedAdministrationRoleAssignments { get; set; } +#endif + /// The governedTenantCanTerminate property + public bool? GovernedTenantCanTerminate { get; set; } + /// The multiTenantApplicationsToProvision property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiTenantApplicationsToProvision { get; set; } +#nullable restore +#else + public List MultiTenantApplicationsToProvision { get; set; } +#endif + /// The OdataType property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? OdataType { get; set; } +#nullable restore +#else + public string OdataType { get; set; } +#endif + /// The policyId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? PolicyId { get; set; } +#nullable restore +#else + public string PolicyId { get; set; } +#endif + /// The version property + public int? Version { get; private set; } + /// + /// Instantiates a new and sets the default values. + /// + public RelationshipPolicy() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipPolicy CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipPolicy(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "delegatedAdministrationRoleAssignments", n => { DelegatedAdministrationRoleAssignments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.DelegatedAdministrationRoleAssignmentSnapshot.CreateFromDiscriminatorValue)?.AsList(); } }, + { "governedTenantCanTerminate", n => { GovernedTenantCanTerminate = n.GetBoolValue(); } }, + { "multiTenantApplicationsToProvision", n => { MultiTenantApplicationsToProvision = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationsToProvisionSnapshot.CreateFromDiscriminatorValue)?.AsList(); } }, + { "@odata.type", n => { OdataType = n.GetStringValue(); } }, + { "policyId", n => { PolicyId = n.GetStringValue(); } }, + { "version", n => { Version = n.GetIntValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteCollectionOfObjectValues("delegatedAdministrationRoleAssignments", DelegatedAdministrationRoleAssignments); + writer.WriteBoolValue("governedTenantCanTerminate", GovernedTenantCanTerminate); + writer.WriteCollectionOfObjectValues("multiTenantApplicationsToProvision", MultiTenantApplicationsToProvision); + writer.WriteStringValue("@odata.type", OdataType); + writer.WriteStringValue("policyId", PolicyId); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelationshipStatus.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelationshipStatus.cs new file mode 100644 index 00000000000..935c4a6f674 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RelationshipStatus.cs @@ -0,0 +1,24 @@ +// +using System.Runtime.Serialization; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public enum RelationshipStatus + #pragma warning restore CS1591 + { + /// Represents a relationship that is currently active. + [EnumMember(Value = "active")] + Active, + /// Represents a relationship that has been terminated. + [EnumMember(Value = "terminated")] + Terminated, + /// Represents a relationship that has been requested to be terminated by governing tenant. + [EnumMember(Value = "terminationRequestedByGoverningTenant")] + TerminationRequestedByGoverningTenant, + /// This will help in making this enum evolable and adding more values in the future- + [EnumMember(Value = "unknownFutureValue")] + UnknownFutureValue, + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RequestStatus.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RequestStatus.cs new file mode 100644 index 00000000000..ada7a5b381c --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RequestStatus.cs @@ -0,0 +1,24 @@ +// +using System.Runtime.Serialization; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public enum RequestStatus + #pragma warning restore CS1591 + { + /// Represents a governance request that is pending + [EnumMember(Value = "pending")] + Pending, + /// Represents a governance request that was accepted + [EnumMember(Value = "accepted")] + Accepted, + /// Represents a governance request that was rejected + [EnumMember(Value = "rejected")] + Rejected, + /// This will help in making this enum evolable and adding more values in the future- + [EnumMember(Value = "unknownFutureValue")] + UnknownFutureValue, + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RoleTemplate.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RoleTemplate.cs new file mode 100644 index 00000000000..65bdcb61462 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/RoleTemplate.cs @@ -0,0 +1,85 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class RoleTemplate : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The id property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Id { get; set; } +#nullable restore +#else + public string Id { get; set; } +#endif + /// The name property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Name { get; set; } +#nullable restore +#else + public string Name { get; set; } +#endif + /// The OdataType property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? OdataType { get; set; } +#nullable restore +#else + public string OdataType { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public RoleTemplate() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RoleTemplate CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RoleTemplate(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "id", n => { Id = n.GetStringValue(); } }, + { "name", n => { Name = n.GetStringValue(); } }, + { "@odata.type", n => { OdataType = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteStringValue("id", Id); + writer.WriteStringValue("name", Name); + writer.WriteStringValue("@odata.type", OdataType); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernance.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernance.cs new file mode 100644 index 00000000000..feacad12ab7 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernance.cs @@ -0,0 +1,106 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class TenantGovernance : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The governanceInvitations property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? GovernanceInvitations { get; set; } +#nullable restore +#else + public List GovernanceInvitations { get; set; } +#endif + /// The governancePolicyTemplates property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? GovernancePolicyTemplates { get; set; } +#nullable restore +#else + public List GovernancePolicyTemplates { get; set; } +#endif + /// The governanceRelationships property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? GovernanceRelationships { get; set; } +#nullable restore +#else + public List GovernanceRelationships { get; set; } +#endif + /// The governanceRequests property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? GovernanceRequests { get; set; } +#nullable restore +#else + public List GovernanceRequests { get; set; } +#endif + /// The relatedTenants property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? RelatedTenants { get; set; } +#nullable restore +#else + public List RelatedTenants { get; set; } +#endif + /// The settings property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting? Settings { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting Settings { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "governanceInvitations", n => { GovernanceInvitations = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation.CreateFromDiscriminatorValue)?.AsList(); } }, + { "governancePolicyTemplates", n => { GovernancePolicyTemplates = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate.CreateFromDiscriminatorValue)?.AsList(); } }, + { "governanceRelationships", n => { GovernanceRelationships = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship.CreateFromDiscriminatorValue)?.AsList(); } }, + { "governanceRequests", n => { GovernanceRequests = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest.CreateFromDiscriminatorValue)?.AsList(); } }, + { "relatedTenants", n => { RelatedTenants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant.CreateFromDiscriminatorValue)?.AsList(); } }, + { "settings", n => { Settings = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting.CreateFromDiscriminatorValue); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("governanceInvitations", GovernanceInvitations); + writer.WriteCollectionOfObjectValues("governancePolicyTemplates", GovernancePolicyTemplates); + writer.WriteCollectionOfObjectValues("governanceRelationships", GovernanceRelationships); + writer.WriteCollectionOfObjectValues("governanceRequests", GovernanceRequests); + writer.WriteCollectionOfObjectValues("relatedTenants", RelatedTenants); + writer.WriteObjectValue("settings", Settings); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernancePolicyTemplate.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernancePolicyTemplate.cs new file mode 100644 index 00000000000..cc45eb042a4 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernancePolicyTemplate.cs @@ -0,0 +1,108 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class TenantGovernancePolicyTemplate : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The createdDateTime property + public DateTimeOffset? CreatedDateTime { get; set; } + /// The delegatedAdministrationRoleAssignments property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? DelegatedAdministrationRoleAssignments { get; set; } +#nullable restore +#else + public List DelegatedAdministrationRoleAssignments { get; set; } +#endif + /// The description property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Description { get; set; } +#nullable restore +#else + public string Description { get; set; } +#endif + /// The displayName property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? DisplayName { get; set; } +#nullable restore +#else + public string DisplayName { get; set; } +#endif + /// The governedTenantCanTerminate property + public bool? GovernedTenantCanTerminate { get; set; } + /// The lastModifiedDateTime property + public DateTimeOffset? LastModifiedDateTime { get; set; } + /// The multiTenantApplicationsToProvision property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiTenantApplicationsToProvision { get; set; } +#nullable restore +#else + public List MultiTenantApplicationsToProvision { get; set; } +#endif + /// The version property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Version { get; set; } +#nullable restore +#else + public string Version { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "createdDateTime", n => { CreatedDateTime = n.GetDateTimeOffsetValue(); } }, + { "delegatedAdministrationRoleAssignments", n => { DelegatedAdministrationRoleAssignments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.DelegatedAdministrationRoleAssignment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "description", n => { Description = n.GetStringValue(); } }, + { "displayName", n => { DisplayName = n.GetStringValue(); } }, + { "governedTenantCanTerminate", n => { GovernedTenantCanTerminate = n.GetBoolValue(); } }, + { "lastModifiedDateTime", n => { LastModifiedDateTime = n.GetDateTimeOffsetValue(); } }, + { "multiTenantApplicationsToProvision", n => { MultiTenantApplicationsToProvision = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationsToProvision.CreateFromDiscriminatorValue)?.AsList(); } }, + { "version", n => { Version = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteDateTimeOffsetValue("createdDateTime", CreatedDateTime); + writer.WriteCollectionOfObjectValues("delegatedAdministrationRoleAssignments", DelegatedAdministrationRoleAssignments); + writer.WriteStringValue("description", Description); + writer.WriteStringValue("displayName", DisplayName); + writer.WriteBoolValue("governedTenantCanTerminate", GovernedTenantCanTerminate); + writer.WriteDateTimeOffsetValue("lastModifiedDateTime", LastModifiedDateTime); + writer.WriteCollectionOfObjectValues("multiTenantApplicationsToProvision", MultiTenantApplicationsToProvision); + writer.WriteStringValue("version", Version); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernancePolicyTemplateCollectionResponse.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernancePolicyTemplateCollectionResponse.cs new file mode 100644 index 00000000000..f224719961b --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernancePolicyTemplateCollectionResponse.cs @@ -0,0 +1,56 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class TenantGovernancePolicyTemplateCollectionResponse : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BaseCollectionPaginationCountResponse, IParsable + #pragma warning restore CS1591 + { + /// The value property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Value { get; set; } +#nullable restore +#else + public List Value { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplateCollectionResponse CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplateCollectionResponse(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "value", n => { Value = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate.CreateFromDiscriminatorValue)?.AsList(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("value", Value); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernanceSetting.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernanceSetting.cs new file mode 100644 index 00000000000..24a00ea320f --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/TenantGovernanceSetting.cs @@ -0,0 +1,54 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class TenantGovernanceSetting : global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Entity, IParsable + #pragma warning restore CS1591 + { + /// The canReceiveInvitations property + public bool? CanReceiveInvitations { get; set; } + /// The isRelatedTenantsEnabled property + public bool? IsRelatedTenantsEnabled { get; set; } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "canReceiveInvitations", n => { CanReceiveInvitations = n.GetBoolValue(); } }, + { "isRelatedTenantsEnabled", n => { IsRelatedTenantsEnabled = n.GetBoolValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteBoolValue("canReceiveInvitations", CanReceiveInvitations); + writer.WriteBoolValue("isRelatedTenantsEnabled", IsRelatedTenantsEnabled); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/User.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/User.cs index bdc24c1a203..92451a14c09 100644 --- a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/User.cs +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Identity.Director #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/kiota-lock.json b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/kiota-lock.json index a34a8073de8..d68ef1385e2 100644 --- a/src/Identity.DirectoryManagement/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "3A953DFBBAD968DC31074E2ED9DE6A78F9208EACF663CA258E80D0DA26456A338D77517DE653358CEBF110E9A890C1DA87B992ACAE801D36BB36859C0F158B4D", + "descriptionHash": "A6BF5B9E9D88FD2905D0D378A6E407F703CA75E9EB825AC79EB3A35BB8BE44D1D9D5EE623698B9FD7478662B0355552B6DDC4E79AE899ADE8A85F951DC1AAC98", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Identity.DirectoryManagement.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernance.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernance.g.cs new file mode 100644 index 00000000000..8b320995c35 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernance.g.cs @@ -0,0 +1,64 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernance")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance))] + public class GetMgDirectoryTenantGovernanceCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance? result; + try + { + result = client.Directory.TenantGovernance.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitation.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitation.g.cs new file mode 100644 index 00000000000..1879fd30a4e --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitation.g.cs @@ -0,0 +1,91 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Management.Automation.Runspaces; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governanceInvitations")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceInvitation", DefaultParameterSetName = "List")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitationCollectionResponse), ParameterSetName = new[] { "List" })] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation), ParameterSetName = new[] { "Get" })] + public class GetMgDirectoryTenantGovernanceInvitationCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, ParameterSetName = "Get", Position = 0)] + public string GovernanceInvitationId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public string? Filter { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + [Alias("OrderBy")] + public string[]? Sort { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public string? Search { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public int Top { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public int Skip { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public SwitchParameter Count { get; set; } + + // Declared here because the binder rejects a parameter the dispatcher does not accept + // before ProcessRecord ever runs; once declared, the wholesale BoundParameters splat + // forwards it to the list worker with no further plumbing. + [Parameter(Mandatory = false, ParameterSetName = "List")] + public SwitchParameter All { get; set; } + + + + + + // Delegates to Get-MgDirectoryTenantGovernanceInvitation_Get or Get-MgDirectoryTenantGovernanceInvitation_List, the two cmdlets + // that actually call Graph. + protected override void ProcessRecord() + { + var internalCmdletName = ParameterSetName == "Get" ? "Get-MgDirectoryTenantGovernanceInvitation_Get" : "Get-MgDirectoryTenantGovernanceInvitation_List"; + try + { + InvokeCommand.InvokeScript( + "param($BoundParameters, $CmdletName) & $CmdletName @BoundParameters", + false, + PipelineResultTypes.Output | PipelineResultTypes.Error, + null, + MyInvocation.BoundParameters, internalCmdletName); + } + // The workers signal failure via ThrowTerminatingError, which InvokeScript surfaces + // as a RuntimeException carrying the worker's ErrorRecord. Rethrow that record + // unchanged so the caller sees the worker's error identity (NoGraphSession, + // GraphRequestFailed, ...) instead of every failure collapsing into a generic + // dispatcher error. A pipeline stop is a RuntimeException too and must NOT be + // rethrown as a terminating error - both filters here let it pass to the engine. + catch (RuntimeException rex) when (rex is not PipelineStoppedException && rex.ErrorRecord is not null) + { + ThrowTerminatingError(rex.ErrorRecord); + return; + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, ParameterSetName == "Get" ? GovernanceInvitationId : null); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitationCount.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitationCount.g.cs new file mode 100644 index 00000000000..4f608072ef0 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitationCount.g.cs @@ -0,0 +1,61 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governanceInvitations/$count")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceInvitationCount")] + [OutputType(typeof(int))] + public class GetMgDirectoryTenantGovernanceInvitationCountCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + public string? Filter { get; set; } + + [Parameter(Mandatory = false)] + public string? Search { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + int? result; + try + { + result = client.Directory.TenantGovernance.GovernanceInvitations.Count.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Filter))) + requestConfiguration.QueryParameters.Filter = Filter; + + if (this.IsParameterBound(nameof(Search))) + requestConfiguration.QueryParameters.Search = Search; + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitation_Get.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitation_Get.g.cs new file mode 100644 index 00000000000..79a788ad934 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitation_Get.g.cs @@ -0,0 +1,65 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governanceInvitations/{governanceInvitation-id}")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceInvitation_Get")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation))] + public class GetMgDirectoryTenantGovernanceInvitation_GetCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string GovernanceInvitationId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation? result; + try + { + result = client.Directory.TenantGovernance.GovernanceInvitations[GovernanceInvitationId].GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GovernanceInvitationId); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitation_List.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitation_List.g.cs new file mode 100644 index 00000000000..0963de9304c --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceInvitation_List.g.cs @@ -0,0 +1,141 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governanceInvitations")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceInvitation_List")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation))] + public class GetMgDirectoryTenantGovernanceInvitation_ListCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + public string? Filter { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + [Parameter(Mandatory = false)] + [Alias("OrderBy")] + public string[]? Sort { get; set; } + + [Parameter(Mandatory = false)] + public string? Search { get; set; } + + [Parameter(Mandatory = false)] + public int Top { get; set; } + + [Parameter(Mandatory = false)] + public int Skip { get; set; } + + [Parameter(Mandatory = false)] + public SwitchParameter Count { get; set; } + + // Follows every @odata.nextLink until the collection is exhausted (a bound -Top caps + // the total). Without it only the first page returns, plus a truncation warning when + // more pages existed. + [Parameter(Mandatory = false)] + public SwitchParameter All { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitationCollectionResponse? result; + try + { + result = client.Directory.TenantGovernance.GovernanceInvitations.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Filter))) + requestConfiguration.QueryParameters.Filter = Filter; + + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + if (this.IsParameterBound(nameof(Sort))) + requestConfiguration.QueryParameters.Orderby = Sort; + + if (this.IsParameterBound(nameof(Search))) + requestConfiguration.QueryParameters.Search = Search; + + if (this.IsParameterBound(nameof(Top))) + requestConfiguration.QueryParameters.Top = Top; + + if (this.IsParameterBound(nameof(Skip))) + requestConfiguration.QueryParameters.Skip = Skip; + + if (Count.IsPresent) + requestConfiguration.QueryParameters.Count = true; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + + // A collection response and its Value are both nullable on the kiota client; an + // empty page writes nothing rather than dereferencing null. Each page streams to + // the pipeline before the next request is issued, matching the published SDK. + if (result?.Value is { } items) + WriteObject(items, enumerateCollection: true); + + if (All.IsPresent) + { + var fetched = result?.Value?.Count ?? 0; + var nextLink = result?.OdataNextLink; + while (!string.IsNullOrEmpty(nextLink) && !Stopping && (!this.IsParameterBound(nameof(Top)) || fetched < Top)) + { + // The nextLink already carries the original query state, and a raw-URL + // builder ignores templated query parameters anyway - so the continuation + // re-applies headers only; query bindings here would be dead code. + result = client.Directory.TenantGovernance.GovernanceInvitations.WithUrl(nextLink).GetAsync(requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }, StoppingToken).GetAwaiter().GetResult(); + if (result?.Value is { } page) + { + WriteObject(page, enumerateCollection: true); + fetched += page.Count; + } + nextLink = result?.OdataNextLink; + } + } + else if (!string.IsNullOrEmpty(result?.OdataNextLink)) + { + // Deliberately stronger than the published SDK, which truncates silently; + // approved in the design spec. One line, no extra request. + WriteWarning("More results are available. Use -All to return all pages."); + } + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplate.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplate.g.cs new file mode 100644 index 00000000000..c7979619026 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplate.g.cs @@ -0,0 +1,91 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Management.Automation.Runspaces; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governancePolicyTemplates")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernancePolicyTemplate", DefaultParameterSetName = "List")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplateCollectionResponse), ParameterSetName = new[] { "List" })] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate), ParameterSetName = new[] { "Get" })] + public class GetMgDirectoryTenantGovernancePolicyTemplateCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, ParameterSetName = "Get", Position = 0)] + public string TenantGovernancePolicyTemplateId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public string? Filter { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + [Alias("OrderBy")] + public string[]? Sort { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public string? Search { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public int Top { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public int Skip { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public SwitchParameter Count { get; set; } + + // Declared here because the binder rejects a parameter the dispatcher does not accept + // before ProcessRecord ever runs; once declared, the wholesale BoundParameters splat + // forwards it to the list worker with no further plumbing. + [Parameter(Mandatory = false, ParameterSetName = "List")] + public SwitchParameter All { get; set; } + + + + + + // Delegates to Get-MgDirectoryTenantGovernancePolicyTemplate_Get or Get-MgDirectoryTenantGovernancePolicyTemplate_List, the two cmdlets + // that actually call Graph. + protected override void ProcessRecord() + { + var internalCmdletName = ParameterSetName == "Get" ? "Get-MgDirectoryTenantGovernancePolicyTemplate_Get" : "Get-MgDirectoryTenantGovernancePolicyTemplate_List"; + try + { + InvokeCommand.InvokeScript( + "param($BoundParameters, $CmdletName) & $CmdletName @BoundParameters", + false, + PipelineResultTypes.Output | PipelineResultTypes.Error, + null, + MyInvocation.BoundParameters, internalCmdletName); + } + // The workers signal failure via ThrowTerminatingError, which InvokeScript surfaces + // as a RuntimeException carrying the worker's ErrorRecord. Rethrow that record + // unchanged so the caller sees the worker's error identity (NoGraphSession, + // GraphRequestFailed, ...) instead of every failure collapsing into a generic + // dispatcher error. A pipeline stop is a RuntimeException too and must NOT be + // rethrown as a terminating error - both filters here let it pass to the engine. + catch (RuntimeException rex) when (rex is not PipelineStoppedException && rex.ErrorRecord is not null) + { + ThrowTerminatingError(rex.ErrorRecord); + return; + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, ParameterSetName == "Get" ? TenantGovernancePolicyTemplateId : null); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplateCount.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplateCount.g.cs new file mode 100644 index 00000000000..6dad4a25fec --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplateCount.g.cs @@ -0,0 +1,61 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governancePolicyTemplates/$count")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernancePolicyTemplateCount")] + [OutputType(typeof(int))] + public class GetMgDirectoryTenantGovernancePolicyTemplateCountCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + public string? Filter { get; set; } + + [Parameter(Mandatory = false)] + public string? Search { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + int? result; + try + { + result = client.Directory.TenantGovernance.GovernancePolicyTemplates.Count.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Filter))) + requestConfiguration.QueryParameters.Filter = Filter; + + if (this.IsParameterBound(nameof(Search))) + requestConfiguration.QueryParameters.Search = Search; + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplate_Get.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplate_Get.g.cs new file mode 100644 index 00000000000..5627a6090d6 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplate_Get.g.cs @@ -0,0 +1,65 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governancePolicyTemplates/{tenantGovernancePolicyTemplate-id}")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernancePolicyTemplate_Get")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate))] + public class GetMgDirectoryTenantGovernancePolicyTemplate_GetCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string TenantGovernancePolicyTemplateId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate? result; + try + { + result = client.Directory.TenantGovernance.GovernancePolicyTemplates[TenantGovernancePolicyTemplateId].GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, TenantGovernancePolicyTemplateId); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplate_List.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplate_List.g.cs new file mode 100644 index 00000000000..5d055bd6613 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernancePolicyTemplate_List.g.cs @@ -0,0 +1,141 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governancePolicyTemplates")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernancePolicyTemplate_List")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate))] + public class GetMgDirectoryTenantGovernancePolicyTemplate_ListCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + public string? Filter { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + [Parameter(Mandatory = false)] + [Alias("OrderBy")] + public string[]? Sort { get; set; } + + [Parameter(Mandatory = false)] + public string? Search { get; set; } + + [Parameter(Mandatory = false)] + public int Top { get; set; } + + [Parameter(Mandatory = false)] + public int Skip { get; set; } + + [Parameter(Mandatory = false)] + public SwitchParameter Count { get; set; } + + // Follows every @odata.nextLink until the collection is exhausted (a bound -Top caps + // the total). Without it only the first page returns, plus a truncation warning when + // more pages existed. + [Parameter(Mandatory = false)] + public SwitchParameter All { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplateCollectionResponse? result; + try + { + result = client.Directory.TenantGovernance.GovernancePolicyTemplates.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Filter))) + requestConfiguration.QueryParameters.Filter = Filter; + + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + if (this.IsParameterBound(nameof(Sort))) + requestConfiguration.QueryParameters.Orderby = Sort; + + if (this.IsParameterBound(nameof(Search))) + requestConfiguration.QueryParameters.Search = Search; + + if (this.IsParameterBound(nameof(Top))) + requestConfiguration.QueryParameters.Top = Top; + + if (this.IsParameterBound(nameof(Skip))) + requestConfiguration.QueryParameters.Skip = Skip; + + if (Count.IsPresent) + requestConfiguration.QueryParameters.Count = true; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + + // A collection response and its Value are both nullable on the kiota client; an + // empty page writes nothing rather than dereferencing null. Each page streams to + // the pipeline before the next request is issued, matching the published SDK. + if (result?.Value is { } items) + WriteObject(items, enumerateCollection: true); + + if (All.IsPresent) + { + var fetched = result?.Value?.Count ?? 0; + var nextLink = result?.OdataNextLink; + while (!string.IsNullOrEmpty(nextLink) && !Stopping && (!this.IsParameterBound(nameof(Top)) || fetched < Top)) + { + // The nextLink already carries the original query state, and a raw-URL + // builder ignores templated query parameters anyway - so the continuation + // re-applies headers only; query bindings here would be dead code. + result = client.Directory.TenantGovernance.GovernancePolicyTemplates.WithUrl(nextLink).GetAsync(requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }, StoppingToken).GetAwaiter().GetResult(); + if (result?.Value is { } page) + { + WriteObject(page, enumerateCollection: true); + fetched += page.Count; + } + nextLink = result?.OdataNextLink; + } + } + else if (!string.IsNullOrEmpty(result?.OdataNextLink)) + { + // Deliberately stronger than the published SDK, which truncates silently; + // approved in the design spec. One line, no extra request. + WriteWarning("More results are available. Use -All to return all pages."); + } + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenant.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenant.g.cs new file mode 100644 index 00000000000..7b2505d9a7e --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenant.g.cs @@ -0,0 +1,91 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Management.Automation.Runspaces; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/relatedTenants")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRelatedTenant", DefaultParameterSetName = "List")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenantCollectionResponse), ParameterSetName = new[] { "List" })] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant), ParameterSetName = new[] { "Get" })] + public class GetMgDirectoryTenantGovernanceRelatedTenantCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, ParameterSetName = "Get", Position = 0)] + public string RelatedTenantId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public string? Filter { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + [Alias("OrderBy")] + public string[]? Sort { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public string? Search { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public int Top { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public int Skip { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public SwitchParameter Count { get; set; } + + // Declared here because the binder rejects a parameter the dispatcher does not accept + // before ProcessRecord ever runs; once declared, the wholesale BoundParameters splat + // forwards it to the list worker with no further plumbing. + [Parameter(Mandatory = false, ParameterSetName = "List")] + public SwitchParameter All { get; set; } + + + + + + // Delegates to Get-MgDirectoryTenantGovernanceRelatedTenant_Get or Get-MgDirectoryTenantGovernanceRelatedTenant_List, the two cmdlets + // that actually call Graph. + protected override void ProcessRecord() + { + var internalCmdletName = ParameterSetName == "Get" ? "Get-MgDirectoryTenantGovernanceRelatedTenant_Get" : "Get-MgDirectoryTenantGovernanceRelatedTenant_List"; + try + { + InvokeCommand.InvokeScript( + "param($BoundParameters, $CmdletName) & $CmdletName @BoundParameters", + false, + PipelineResultTypes.Output | PipelineResultTypes.Error, + null, + MyInvocation.BoundParameters, internalCmdletName); + } + // The workers signal failure via ThrowTerminatingError, which InvokeScript surfaces + // as a RuntimeException carrying the worker's ErrorRecord. Rethrow that record + // unchanged so the caller sees the worker's error identity (NoGraphSession, + // GraphRequestFailed, ...) instead of every failure collapsing into a generic + // dispatcher error. A pipeline stop is a RuntimeException too and must NOT be + // rethrown as a terminating error - both filters here let it pass to the engine. + catch (RuntimeException rex) when (rex is not PipelineStoppedException && rex.ErrorRecord is not null) + { + ThrowTerminatingError(rex.ErrorRecord); + return; + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, ParameterSetName == "Get" ? RelatedTenantId : null); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantAppB2BSignInActivityMetric.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantAppB2BSignInActivityMetric.g.cs new file mode 100644 index 00000000000..cc4f5fa691d --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantAppB2BSignInActivityMetric.g.cs @@ -0,0 +1,65 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/relatedTenants/{relatedTenant-id}/appB2BSignInActivityMetrics")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRelatedTenantAppB2BSignInActivityMetric")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics))] + public class GetMgDirectoryTenantGovernanceRelatedTenantAppB2BSignInActivityMetricCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string RelatedTenantId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics? result; + try + { + result = client.Directory.TenantGovernance.RelatedTenants[RelatedTenantId].AppB2BSignInActivityMetrics.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, RelatedTenantId); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantB2BRegistrationMetric.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantB2BRegistrationMetric.g.cs new file mode 100644 index 00000000000..e5cbb4527e0 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantB2BRegistrationMetric.g.cs @@ -0,0 +1,65 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/relatedTenants/{relatedTenant-id}/b2BRegistrationMetrics")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRelatedTenantB2BRegistrationMetric")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2bRegistrationMetrics))] + public class GetMgDirectoryTenantGovernanceRelatedTenantB2BRegistrationMetricCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string RelatedTenantId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2bRegistrationMetrics? result; + try + { + result = client.Directory.TenantGovernance.RelatedTenants[RelatedTenantId].B2BRegistrationMetrics.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, RelatedTenantId); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantB2BSignInActivityMetric.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantB2BSignInActivityMetric.g.cs new file mode 100644 index 00000000000..6226e25a829 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantB2BSignInActivityMetric.g.cs @@ -0,0 +1,65 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/relatedTenants/{relatedTenant-id}/b2BSignInActivityMetrics")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRelatedTenantB2BSignInActivityMetric")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics))] + public class GetMgDirectoryTenantGovernanceRelatedTenantB2BSignInActivityMetricCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string RelatedTenantId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.B2BSignInActivityMetrics? result; + try + { + result = client.Directory.TenantGovernance.RelatedTenants[RelatedTenantId].B2BSignInActivityMetrics.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, RelatedTenantId); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantBillingMetric.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantBillingMetric.g.cs new file mode 100644 index 00000000000..84c665b59a7 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantBillingMetric.g.cs @@ -0,0 +1,65 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/relatedTenants/{relatedTenant-id}/billingMetrics")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRelatedTenantBillingMetric")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetrics))] + public class GetMgDirectoryTenantGovernanceRelatedTenantBillingMetricCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string RelatedTenantId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.BillingMetrics? result; + try + { + result = client.Directory.TenantGovernance.RelatedTenants[RelatedTenantId].BillingMetrics.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, RelatedTenantId); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantCount.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantCount.g.cs new file mode 100644 index 00000000000..31cc8326eba --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantCount.g.cs @@ -0,0 +1,61 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/relatedTenants/$count")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRelatedTenantCount")] + [OutputType(typeof(int))] + public class GetMgDirectoryTenantGovernanceRelatedTenantCountCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + public string? Filter { get; set; } + + [Parameter(Mandatory = false)] + public string? Search { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + int? result; + try + { + result = client.Directory.TenantGovernance.RelatedTenants.Count.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Filter))) + requestConfiguration.QueryParameters.Filter = Filter; + + if (this.IsParameterBound(nameof(Search))) + requestConfiguration.QueryParameters.Search = Search; + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantMultiTenantApplicationMetric.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantMultiTenantApplicationMetric.g.cs new file mode 100644 index 00000000000..cf9e1fe2699 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenantMultiTenantApplicationMetric.g.cs @@ -0,0 +1,65 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/relatedTenants/{relatedTenant-id}/multiTenantApplicationMetrics")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRelatedTenantMultiTenantApplicationMetric")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetrics))] + public class GetMgDirectoryTenantGovernanceRelatedTenantMultiTenantApplicationMetricCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string RelatedTenantId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationMetrics? result; + try + { + result = client.Directory.TenantGovernance.RelatedTenants[RelatedTenantId].MultiTenantApplicationMetrics.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, RelatedTenantId); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenant_Get.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenant_Get.g.cs new file mode 100644 index 00000000000..dd9d06d1bda --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenant_Get.g.cs @@ -0,0 +1,65 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/relatedTenants/{relatedTenant-id}")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRelatedTenant_Get")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant))] + public class GetMgDirectoryTenantGovernanceRelatedTenant_GetCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string RelatedTenantId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant? result; + try + { + result = client.Directory.TenantGovernance.RelatedTenants[RelatedTenantId].GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, RelatedTenantId); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenant_List.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenant_List.g.cs new file mode 100644 index 00000000000..4deb24e5a65 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelatedTenant_List.g.cs @@ -0,0 +1,141 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/relatedTenants")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRelatedTenant_List")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant))] + public class GetMgDirectoryTenantGovernanceRelatedTenant_ListCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + public string? Filter { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + [Parameter(Mandatory = false)] + [Alias("OrderBy")] + public string[]? Sort { get; set; } + + [Parameter(Mandatory = false)] + public string? Search { get; set; } + + [Parameter(Mandatory = false)] + public int Top { get; set; } + + [Parameter(Mandatory = false)] + public int Skip { get; set; } + + [Parameter(Mandatory = false)] + public SwitchParameter Count { get; set; } + + // Follows every @odata.nextLink until the collection is exhausted (a bound -Top caps + // the total). Without it only the first page returns, plus a truncation warning when + // more pages existed. + [Parameter(Mandatory = false)] + public SwitchParameter All { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenantCollectionResponse? result; + try + { + result = client.Directory.TenantGovernance.RelatedTenants.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Filter))) + requestConfiguration.QueryParameters.Filter = Filter; + + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + if (this.IsParameterBound(nameof(Sort))) + requestConfiguration.QueryParameters.Orderby = Sort; + + if (this.IsParameterBound(nameof(Search))) + requestConfiguration.QueryParameters.Search = Search; + + if (this.IsParameterBound(nameof(Top))) + requestConfiguration.QueryParameters.Top = Top; + + if (this.IsParameterBound(nameof(Skip))) + requestConfiguration.QueryParameters.Skip = Skip; + + if (Count.IsPresent) + requestConfiguration.QueryParameters.Count = true; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + + // A collection response and its Value are both nullable on the kiota client; an + // empty page writes nothing rather than dereferencing null. Each page streams to + // the pipeline before the next request is issued, matching the published SDK. + if (result?.Value is { } items) + WriteObject(items, enumerateCollection: true); + + if (All.IsPresent) + { + var fetched = result?.Value?.Count ?? 0; + var nextLink = result?.OdataNextLink; + while (!string.IsNullOrEmpty(nextLink) && !Stopping && (!this.IsParameterBound(nameof(Top)) || fetched < Top)) + { + // The nextLink already carries the original query state, and a raw-URL + // builder ignores templated query parameters anyway - so the continuation + // re-applies headers only; query bindings here would be dead code. + result = client.Directory.TenantGovernance.RelatedTenants.WithUrl(nextLink).GetAsync(requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }, StoppingToken).GetAwaiter().GetResult(); + if (result?.Value is { } page) + { + WriteObject(page, enumerateCollection: true); + fetched += page.Count; + } + nextLink = result?.OdataNextLink; + } + } + else if (!string.IsNullOrEmpty(result?.OdataNextLink)) + { + // Deliberately stronger than the published SDK, which truncates silently; + // approved in the design spec. One line, no extra request. + WriteWarning("More results are available. Use -All to return all pages."); + } + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationship.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationship.g.cs new file mode 100644 index 00000000000..1652e52943e --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationship.g.cs @@ -0,0 +1,91 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Management.Automation.Runspaces; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governanceRelationships")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRelationship", DefaultParameterSetName = "List")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationshipCollectionResponse), ParameterSetName = new[] { "List" })] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship), ParameterSetName = new[] { "Get" })] + public class GetMgDirectoryTenantGovernanceRelationshipCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, ParameterSetName = "Get", Position = 0)] + public string GovernanceRelationshipId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public string? Filter { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + [Alias("OrderBy")] + public string[]? Sort { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public string? Search { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public int Top { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public int Skip { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public SwitchParameter Count { get; set; } + + // Declared here because the binder rejects a parameter the dispatcher does not accept + // before ProcessRecord ever runs; once declared, the wholesale BoundParameters splat + // forwards it to the list worker with no further plumbing. + [Parameter(Mandatory = false, ParameterSetName = "List")] + public SwitchParameter All { get; set; } + + + + + + // Delegates to Get-MgDirectoryTenantGovernanceRelationship_Get or Get-MgDirectoryTenantGovernanceRelationship_List, the two cmdlets + // that actually call Graph. + protected override void ProcessRecord() + { + var internalCmdletName = ParameterSetName == "Get" ? "Get-MgDirectoryTenantGovernanceRelationship_Get" : "Get-MgDirectoryTenantGovernanceRelationship_List"; + try + { + InvokeCommand.InvokeScript( + "param($BoundParameters, $CmdletName) & $CmdletName @BoundParameters", + false, + PipelineResultTypes.Output | PipelineResultTypes.Error, + null, + MyInvocation.BoundParameters, internalCmdletName); + } + // The workers signal failure via ThrowTerminatingError, which InvokeScript surfaces + // as a RuntimeException carrying the worker's ErrorRecord. Rethrow that record + // unchanged so the caller sees the worker's error identity (NoGraphSession, + // GraphRequestFailed, ...) instead of every failure collapsing into a generic + // dispatcher error. A pipeline stop is a RuntimeException too and must NOT be + // rethrown as a terminating error - both filters here let it pass to the engine. + catch (RuntimeException rex) when (rex is not PipelineStoppedException && rex.ErrorRecord is not null) + { + ThrowTerminatingError(rex.ErrorRecord); + return; + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, ParameterSetName == "Get" ? GovernanceRelationshipId : null); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationshipCount.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationshipCount.g.cs new file mode 100644 index 00000000000..61da8c455c5 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationshipCount.g.cs @@ -0,0 +1,61 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governanceRelationships/$count")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRelationshipCount")] + [OutputType(typeof(int))] + public class GetMgDirectoryTenantGovernanceRelationshipCountCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + public string? Filter { get; set; } + + [Parameter(Mandatory = false)] + public string? Search { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + int? result; + try + { + result = client.Directory.TenantGovernance.GovernanceRelationships.Count.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Filter))) + requestConfiguration.QueryParameters.Filter = Filter; + + if (this.IsParameterBound(nameof(Search))) + requestConfiguration.QueryParameters.Search = Search; + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationship_Get.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationship_Get.g.cs new file mode 100644 index 00000000000..a9bfd1a937c --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationship_Get.g.cs @@ -0,0 +1,65 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governanceRelationships/{governanceRelationship-id}")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRelationship_Get")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship))] + public class GetMgDirectoryTenantGovernanceRelationship_GetCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string GovernanceRelationshipId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship? result; + try + { + result = client.Directory.TenantGovernance.GovernanceRelationships[GovernanceRelationshipId].GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GovernanceRelationshipId); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationship_List.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationship_List.g.cs new file mode 100644 index 00000000000..e6f02b91a12 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRelationship_List.g.cs @@ -0,0 +1,141 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governanceRelationships")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRelationship_List")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship))] + public class GetMgDirectoryTenantGovernanceRelationship_ListCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + public string? Filter { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + [Parameter(Mandatory = false)] + [Alias("OrderBy")] + public string[]? Sort { get; set; } + + [Parameter(Mandatory = false)] + public string? Search { get; set; } + + [Parameter(Mandatory = false)] + public int Top { get; set; } + + [Parameter(Mandatory = false)] + public int Skip { get; set; } + + [Parameter(Mandatory = false)] + public SwitchParameter Count { get; set; } + + // Follows every @odata.nextLink until the collection is exhausted (a bound -Top caps + // the total). Without it only the first page returns, plus a truncation warning when + // more pages existed. + [Parameter(Mandatory = false)] + public SwitchParameter All { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationshipCollectionResponse? result; + try + { + result = client.Directory.TenantGovernance.GovernanceRelationships.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Filter))) + requestConfiguration.QueryParameters.Filter = Filter; + + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + if (this.IsParameterBound(nameof(Sort))) + requestConfiguration.QueryParameters.Orderby = Sort; + + if (this.IsParameterBound(nameof(Search))) + requestConfiguration.QueryParameters.Search = Search; + + if (this.IsParameterBound(nameof(Top))) + requestConfiguration.QueryParameters.Top = Top; + + if (this.IsParameterBound(nameof(Skip))) + requestConfiguration.QueryParameters.Skip = Skip; + + if (Count.IsPresent) + requestConfiguration.QueryParameters.Count = true; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + + // A collection response and its Value are both nullable on the kiota client; an + // empty page writes nothing rather than dereferencing null. Each page streams to + // the pipeline before the next request is issued, matching the published SDK. + if (result?.Value is { } items) + WriteObject(items, enumerateCollection: true); + + if (All.IsPresent) + { + var fetched = result?.Value?.Count ?? 0; + var nextLink = result?.OdataNextLink; + while (!string.IsNullOrEmpty(nextLink) && !Stopping && (!this.IsParameterBound(nameof(Top)) || fetched < Top)) + { + // The nextLink already carries the original query state, and a raw-URL + // builder ignores templated query parameters anyway - so the continuation + // re-applies headers only; query bindings here would be dead code. + result = client.Directory.TenantGovernance.GovernanceRelationships.WithUrl(nextLink).GetAsync(requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }, StoppingToken).GetAwaiter().GetResult(); + if (result?.Value is { } page) + { + WriteObject(page, enumerateCollection: true); + fetched += page.Count; + } + nextLink = result?.OdataNextLink; + } + } + else if (!string.IsNullOrEmpty(result?.OdataNextLink)) + { + // Deliberately stronger than the published SDK, which truncates silently; + // approved in the design spec. One line, no extra request. + WriteWarning("More results are available. Use -All to return all pages."); + } + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequest.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequest.g.cs new file mode 100644 index 00000000000..1607e2aa28e --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequest.g.cs @@ -0,0 +1,91 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Management.Automation.Runspaces; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governanceRequests")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRequest", DefaultParameterSetName = "List")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequestCollectionResponse), ParameterSetName = new[] { "List" })] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest), ParameterSetName = new[] { "Get" })] + public class GetMgDirectoryTenantGovernanceRequestCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, ParameterSetName = "Get", Position = 0)] + public string GovernanceRequestId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public string? Filter { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + [Alias("OrderBy")] + public string[]? Sort { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public string? Search { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public int Top { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public int Skip { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public SwitchParameter Count { get; set; } + + // Declared here because the binder rejects a parameter the dispatcher does not accept + // before ProcessRecord ever runs; once declared, the wholesale BoundParameters splat + // forwards it to the list worker with no further plumbing. + [Parameter(Mandatory = false, ParameterSetName = "List")] + public SwitchParameter All { get; set; } + + + + + + // Delegates to Get-MgDirectoryTenantGovernanceRequest_Get or Get-MgDirectoryTenantGovernanceRequest_List, the two cmdlets + // that actually call Graph. + protected override void ProcessRecord() + { + var internalCmdletName = ParameterSetName == "Get" ? "Get-MgDirectoryTenantGovernanceRequest_Get" : "Get-MgDirectoryTenantGovernanceRequest_List"; + try + { + InvokeCommand.InvokeScript( + "param($BoundParameters, $CmdletName) & $CmdletName @BoundParameters", + false, + PipelineResultTypes.Output | PipelineResultTypes.Error, + null, + MyInvocation.BoundParameters, internalCmdletName); + } + // The workers signal failure via ThrowTerminatingError, which InvokeScript surfaces + // as a RuntimeException carrying the worker's ErrorRecord. Rethrow that record + // unchanged so the caller sees the worker's error identity (NoGraphSession, + // GraphRequestFailed, ...) instead of every failure collapsing into a generic + // dispatcher error. A pipeline stop is a RuntimeException too and must NOT be + // rethrown as a terminating error - both filters here let it pass to the engine. + catch (RuntimeException rex) when (rex is not PipelineStoppedException && rex.ErrorRecord is not null) + { + ThrowTerminatingError(rex.ErrorRecord); + return; + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, ParameterSetName == "Get" ? GovernanceRequestId : null); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequestCount.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequestCount.g.cs new file mode 100644 index 00000000000..bf6092b171a --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequestCount.g.cs @@ -0,0 +1,61 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governanceRequests/$count")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRequestCount")] + [OutputType(typeof(int))] + public class GetMgDirectoryTenantGovernanceRequestCountCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + public string? Filter { get; set; } + + [Parameter(Mandatory = false)] + public string? Search { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + int? result; + try + { + result = client.Directory.TenantGovernance.GovernanceRequests.Count.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Filter))) + requestConfiguration.QueryParameters.Filter = Filter; + + if (this.IsParameterBound(nameof(Search))) + requestConfiguration.QueryParameters.Search = Search; + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequestGovernancePolicyTemplate.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequestGovernancePolicyTemplate.g.cs new file mode 100644 index 00000000000..3e8b670d24d --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequestGovernancePolicyTemplate.g.cs @@ -0,0 +1,65 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governanceRequests/{governanceRequest-id}/governancePolicyTemplate")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRequestGovernancePolicyTemplate")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate))] + public class GetMgDirectoryTenantGovernanceRequestGovernancePolicyTemplateCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string GovernanceRequestId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate? result; + try + { + result = client.Directory.TenantGovernance.GovernanceRequests[GovernanceRequestId].GovernancePolicyTemplate.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GovernanceRequestId); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequest_Get.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequest_Get.g.cs new file mode 100644 index 00000000000..ac239ccfac3 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequest_Get.g.cs @@ -0,0 +1,65 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governanceRequests/{governanceRequest-id}")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRequest_Get")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest))] + public class GetMgDirectoryTenantGovernanceRequest_GetCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string GovernanceRequestId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest? result; + try + { + result = client.Directory.TenantGovernance.GovernanceRequests[GovernanceRequestId].GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GovernanceRequestId); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequest_List.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequest_List.g.cs new file mode 100644 index 00000000000..58a988cf452 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceRequest_List.g.cs @@ -0,0 +1,141 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/governanceRequests")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceRequest_List")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest))] + public class GetMgDirectoryTenantGovernanceRequest_ListCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + public string? Filter { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + [Parameter(Mandatory = false)] + [Alias("OrderBy")] + public string[]? Sort { get; set; } + + [Parameter(Mandatory = false)] + public string? Search { get; set; } + + [Parameter(Mandatory = false)] + public int Top { get; set; } + + [Parameter(Mandatory = false)] + public int Skip { get; set; } + + [Parameter(Mandatory = false)] + public SwitchParameter Count { get; set; } + + // Follows every @odata.nextLink until the collection is exhausted (a bound -Top caps + // the total). Without it only the first page returns, plus a truncation warning when + // more pages existed. + [Parameter(Mandatory = false)] + public SwitchParameter All { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequestCollectionResponse? result; + try + { + result = client.Directory.TenantGovernance.GovernanceRequests.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Filter))) + requestConfiguration.QueryParameters.Filter = Filter; + + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + if (this.IsParameterBound(nameof(Sort))) + requestConfiguration.QueryParameters.Orderby = Sort; + + if (this.IsParameterBound(nameof(Search))) + requestConfiguration.QueryParameters.Search = Search; + + if (this.IsParameterBound(nameof(Top))) + requestConfiguration.QueryParameters.Top = Top; + + if (this.IsParameterBound(nameof(Skip))) + requestConfiguration.QueryParameters.Skip = Skip; + + if (Count.IsPresent) + requestConfiguration.QueryParameters.Count = true; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + + // A collection response and its Value are both nullable on the kiota client; an + // empty page writes nothing rather than dereferencing null. Each page streams to + // the pipeline before the next request is issued, matching the published SDK. + if (result?.Value is { } items) + WriteObject(items, enumerateCollection: true); + + if (All.IsPresent) + { + var fetched = result?.Value?.Count ?? 0; + var nextLink = result?.OdataNextLink; + while (!string.IsNullOrEmpty(nextLink) && !Stopping && (!this.IsParameterBound(nameof(Top)) || fetched < Top)) + { + // The nextLink already carries the original query state, and a raw-URL + // builder ignores templated query parameters anyway - so the continuation + // re-applies headers only; query bindings here would be dead code. + result = client.Directory.TenantGovernance.GovernanceRequests.WithUrl(nextLink).GetAsync(requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }, StoppingToken).GetAwaiter().GetResult(); + if (result?.Value is { } page) + { + WriteObject(page, enumerateCollection: true); + fetched += page.Count; + } + nextLink = result?.OdataNextLink; + } + } + else if (!string.IsNullOrEmpty(result?.OdataNextLink)) + { + // Deliberately stronger than the published SDK, which truncates silently; + // approved in the design spec. One line, no extra request. + WriteWarning("More results are available. Use -All to return all pages."); + } + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceSetting.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceSetting.g.cs new file mode 100644 index 00000000000..ccce69ce188 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/GetMgDirectoryTenantGovernanceSetting.g.cs @@ -0,0 +1,64 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("GET", "/directory/tenantGovernance/settings")] + [Cmdlet(VerbsCommon.Get, "MgDirectoryTenantGovernanceSetting")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting))] + public class GetMgDirectoryTenantGovernanceSettingCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting? result; + try + { + result = client.Directory.TenantGovernance.Settings.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/InvokeMgDirectoryTenantGovernanceRelatedTenantRefresh.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/InvokeMgDirectoryTenantGovernanceRelatedTenantRefresh.g.cs new file mode 100644 index 00000000000..1c469464e18 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/InvokeMgDirectoryTenantGovernanceRelatedTenantRefresh.g.cs @@ -0,0 +1,58 @@ +#nullable enable + +using System; +using System.Collections.Generic; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("POST", "/directory/tenantGovernance/relatedTenants/refresh")] + [Cmdlet(VerbsLifecycle.Invoke, "MgDirectoryTenantGovernanceRelatedTenantRefresh", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + + public class InvokeMgDirectoryTenantGovernanceRelatedTenantRefreshCommand : GraphClientCmdlet + { + + + + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(null, "Invoke")) + return; + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + + try + { + client.Directory.TenantGovernance.RelatedTenants.Refresh.PostAsync(requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }) + .GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/InvokeMgDirectoryTenantGovernanceSettingEnableRelatedTenants.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/InvokeMgDirectoryTenantGovernanceSettingEnableRelatedTenants.g.cs new file mode 100644 index 00000000000..f23ffeb619d --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/InvokeMgDirectoryTenantGovernanceSettingEnableRelatedTenants.g.cs @@ -0,0 +1,58 @@ +#nullable enable + +using System; +using System.Collections.Generic; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("POST", "/directory/tenantGovernance/settings/enableRelatedTenants")] + [Cmdlet(VerbsLifecycle.Invoke, "MgDirectoryTenantGovernanceSettingEnableRelatedTenants", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + + public class InvokeMgDirectoryTenantGovernanceSettingEnableRelatedTenantsCommand : GraphClientCmdlet + { + + + + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(null, "Invoke")) + return; + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + + try + { + client.Directory.TenantGovernance.Settings.EnableRelatedTenants.PostAsync(requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }) + .GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceInvitation.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceInvitation.g.cs new file mode 100644 index 00000000000..413f32186d1 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceInvitation.g.cs @@ -0,0 +1,94 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("POST", "/directory/tenantGovernance/governanceInvitations")] + [Cmdlet(VerbsCommon.New, "MgDirectoryTenantGovernanceInvitation", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation))] + public class NewMgDirectoryTenantGovernanceInvitationCommand : GraphClientCmdlet + { + + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? CreatedDateTime { get; set; } + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? ExpirationDateTime { get; set; } + + [Parameter(Mandatory = false)] + public string? GovernedTenantId { get; set; } + + [Parameter(Mandatory = false)] + public string? GovernedTenantName { get; set; } + + [Parameter(Mandatory = false)] + public string? GoverningTenantId { get; set; } + + [Parameter(Mandatory = false)] + public string? GoverningTenantName { get; set; } + + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(null, "New")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation(); + + if (this.IsParameterBound(nameof(CreatedDateTime))) + body.CreatedDateTime = CreatedDateTime; + + if (this.IsParameterBound(nameof(ExpirationDateTime))) + body.ExpirationDateTime = ExpirationDateTime; + + if (this.IsParameterBound(nameof(GovernedTenantId))) + body.GovernedTenantId = GovernedTenantId; + + if (this.IsParameterBound(nameof(GovernedTenantName))) + body.GovernedTenantName = GovernedTenantName; + + if (this.IsParameterBound(nameof(GoverningTenantId))) + body.GoverningTenantId = GoverningTenantId; + + if (this.IsParameterBound(nameof(GoverningTenantName))) + body.GoverningTenantName = GoverningTenantName; + + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation? result; + try + { + result = client.Directory.TenantGovernance.GovernanceInvitations.PostAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, body); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernancePolicyTemplate.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernancePolicyTemplate.g.cs new file mode 100644 index 00000000000..56fa5038c83 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernancePolicyTemplate.g.cs @@ -0,0 +1,104 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("POST", "/directory/tenantGovernance/governancePolicyTemplates")] + [Cmdlet(VerbsCommon.New, "MgDirectoryTenantGovernancePolicyTemplate", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate))] + public class NewMgDirectoryTenantGovernancePolicyTemplateCommand : GraphClientCmdlet + { + + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? CreatedDateTime { get; set; } + + [Parameter(Mandatory = false)] + public string? Description { get; set; } + + [Parameter(Mandatory = false)] + public string? DisplayName { get; set; } + + [Parameter(Mandatory = false)] + public bool? GovernedTenantCanTerminate { get; set; } + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? LastModifiedDateTime { get; set; } + + [Parameter(Mandatory = false)] + public string? Version { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.DelegatedAdministrationRoleAssignment[]? DelegatedAdministrationRoleAssignments { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationsToProvision[]? MultiTenantApplicationsToProvision { get; set; } + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(null, "New")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate(); + + if (this.IsParameterBound(nameof(CreatedDateTime))) + body.CreatedDateTime = CreatedDateTime; + + if (this.IsParameterBound(nameof(Description))) + body.Description = Description; + + if (this.IsParameterBound(nameof(DisplayName))) + body.DisplayName = DisplayName; + + if (this.IsParameterBound(nameof(GovernedTenantCanTerminate))) + body.GovernedTenantCanTerminate = GovernedTenantCanTerminate; + + if (this.IsParameterBound(nameof(LastModifiedDateTime))) + body.LastModifiedDateTime = LastModifiedDateTime; + + if (this.IsParameterBound(nameof(Version))) + body.Version = Version; + + if (this.IsParameterBound(nameof(DelegatedAdministrationRoleAssignments))) + body.DelegatedAdministrationRoleAssignments = DelegatedAdministrationRoleAssignments!.ToList(); + + if (this.IsParameterBound(nameof(MultiTenantApplicationsToProvision))) + body.MultiTenantApplicationsToProvision = MultiTenantApplicationsToProvision!.ToList(); + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate? result; + try + { + result = client.Directory.TenantGovernance.GovernancePolicyTemplates.PostAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, body); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceRelatedTenant.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceRelatedTenant.g.cs new file mode 100644 index 00000000000..b39690a1397 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceRelatedTenant.g.cs @@ -0,0 +1,64 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("POST", "/directory/tenantGovernance/relatedTenants")] + [Cmdlet(VerbsCommon.New, "MgDirectoryTenantGovernanceRelatedTenant", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant))] + public class NewMgDirectoryTenantGovernanceRelatedTenantCommand : GraphClientCmdlet + { + + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? CreatedDateTime { get; set; } + + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(null, "New")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant(); + + if (this.IsParameterBound(nameof(CreatedDateTime))) + body.CreatedDateTime = CreatedDateTime; + + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant? result; + try + { + result = client.Directory.TenantGovernance.RelatedTenants.PostAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, body); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceRelationship.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceRelationship.g.cs new file mode 100644 index 00000000000..90944973dd7 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceRelationship.g.cs @@ -0,0 +1,104 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("POST", "/directory/tenantGovernance/governanceRelationships")] + [Cmdlet(VerbsCommon.New, "MgDirectoryTenantGovernanceRelationship", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship))] + public class NewMgDirectoryTenantGovernanceRelationshipCommand : GraphClientCmdlet + { + + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? CreationDateTime { get; set; } + + [Parameter(Mandatory = false)] + public string? GovernedTenantId { get; set; } + + [Parameter(Mandatory = false)] + public string? GovernedTenantName { get; set; } + + [Parameter(Mandatory = false)] + public string? GoverningTenantId { get; set; } + + [Parameter(Mandatory = false)] + public string? GoverningTenantName { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipCreationType? CreatedType { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipPolicy? PolicySnapshot { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipStatus? Status { get; set; } + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(null, "New")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship(); + + if (this.IsParameterBound(nameof(CreationDateTime))) + body.CreationDateTime = CreationDateTime; + + if (this.IsParameterBound(nameof(GovernedTenantId))) + body.GovernedTenantId = GovernedTenantId; + + if (this.IsParameterBound(nameof(GovernedTenantName))) + body.GovernedTenantName = GovernedTenantName; + + if (this.IsParameterBound(nameof(GoverningTenantId))) + body.GoverningTenantId = GoverningTenantId; + + if (this.IsParameterBound(nameof(GoverningTenantName))) + body.GoverningTenantName = GoverningTenantName; + + if (this.IsParameterBound(nameof(CreatedType))) + body.CreatedType = CreatedType; + + if (this.IsParameterBound(nameof(PolicySnapshot))) + body.PolicySnapshot = PolicySnapshot; + + if (this.IsParameterBound(nameof(Status))) + body.Status = Status; + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship? result; + try + { + result = client.Directory.TenantGovernance.GovernanceRelationships.PostAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, body); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceRequest.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceRequest.g.cs new file mode 100644 index 00000000000..cd24a09a01b --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/NewMgDirectoryTenantGovernanceRequest.g.cs @@ -0,0 +1,104 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("POST", "/directory/tenantGovernance/governanceRequests")] + [Cmdlet(VerbsCommon.New, "MgDirectoryTenantGovernanceRequest", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest))] + public class NewMgDirectoryTenantGovernanceRequestCommand : GraphClientCmdlet + { + + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? ExpirationDateTime { get; set; } + + [Parameter(Mandatory = false)] + public string? GovernedTenantId { get; set; } + + [Parameter(Mandatory = false)] + public string? GovernedTenantName { get; set; } + + [Parameter(Mandatory = false)] + public string? GoverningTenantId { get; set; } + + [Parameter(Mandatory = false)] + public string? GoverningTenantName { get; set; } + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? RequestDateTime { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipPolicy? PolicySnapshot { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RequestStatus? Status { get; set; } + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(null, "New")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest(); + + if (this.IsParameterBound(nameof(ExpirationDateTime))) + body.ExpirationDateTime = ExpirationDateTime; + + if (this.IsParameterBound(nameof(GovernedTenantId))) + body.GovernedTenantId = GovernedTenantId; + + if (this.IsParameterBound(nameof(GovernedTenantName))) + body.GovernedTenantName = GovernedTenantName; + + if (this.IsParameterBound(nameof(GoverningTenantId))) + body.GoverningTenantId = GoverningTenantId; + + if (this.IsParameterBound(nameof(GoverningTenantName))) + body.GoverningTenantName = GoverningTenantName; + + if (this.IsParameterBound(nameof(RequestDateTime))) + body.RequestDateTime = RequestDateTime; + + if (this.IsParameterBound(nameof(PolicySnapshot))) + body.PolicySnapshot = PolicySnapshot; + + if (this.IsParameterBound(nameof(Status))) + body.Status = Status; + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest? result; + try + { + result = client.Directory.TenantGovernance.GovernanceRequests.PostAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, body); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernance.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernance.g.cs new file mode 100644 index 00000000000..ad4d57a147a --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernance.g.cs @@ -0,0 +1,55 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("DELETE", "/directory/tenantGovernance")] + [Cmdlet(VerbsCommon.Remove, "MgDirectoryTenantGovernance", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.High)] + public class RemoveMgDirectoryTenantGovernanceCommand : GraphClientCmdlet + { + + + + [Parameter(Mandatory = false, + HelpMessage = "Sets the 'If-Match' request header (for example an ETag for optimistic concurrency; some Graph APIs require it even where the spec marks it optional).")] + public string? IfMatch { get; set; } + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(null, "Remove")) + return; + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + // DeleteAsync returns a plain Task: a standard delete response has no body. + try + { + client.Directory.TenantGovernance.DeleteAsync(requestConfiguration => + { + + if (this.IsParameterBound(nameof(IfMatch))) + requestConfiguration.Headers.Add("If-Match", IfMatch!); + + AddRequestHeaders(requestConfiguration.Headers); + }) + .GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceInvitation.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceInvitation.g.cs new file mode 100644 index 00000000000..dca44e47f98 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceInvitation.g.cs @@ -0,0 +1,56 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("DELETE", "/directory/tenantGovernance/governanceInvitations/{governanceInvitation-id}")] + [Cmdlet(VerbsCommon.Remove, "MgDirectoryTenantGovernanceInvitation", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.High)] + public class RemoveMgDirectoryTenantGovernanceInvitationCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string GovernanceInvitationId { get; set; } = string.Empty; + + + [Parameter(Mandatory = false, + HelpMessage = "Sets the 'If-Match' request header (for example an ETag for optimistic concurrency; some Graph APIs require it even where the spec marks it optional).")] + public string? IfMatch { get; set; } + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(GovernanceInvitationId, "Remove")) + return; + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + // DeleteAsync returns a plain Task: a standard delete response has no body. + try + { + client.Directory.TenantGovernance.GovernanceInvitations[GovernanceInvitationId].DeleteAsync(requestConfiguration => + { + + if (this.IsParameterBound(nameof(IfMatch))) + requestConfiguration.Headers.Add("If-Match", IfMatch!); + + AddRequestHeaders(requestConfiguration.Headers); + }) + .GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GovernanceInvitationId); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernancePolicyTemplate.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernancePolicyTemplate.g.cs new file mode 100644 index 00000000000..6128fdcb980 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernancePolicyTemplate.g.cs @@ -0,0 +1,56 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("DELETE", "/directory/tenantGovernance/governancePolicyTemplates/{tenantGovernancePolicyTemplate-id}")] + [Cmdlet(VerbsCommon.Remove, "MgDirectoryTenantGovernancePolicyTemplate", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.High)] + public class RemoveMgDirectoryTenantGovernancePolicyTemplateCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string TenantGovernancePolicyTemplateId { get; set; } = string.Empty; + + + [Parameter(Mandatory = false, + HelpMessage = "Sets the 'If-Match' request header (for example an ETag for optimistic concurrency; some Graph APIs require it even where the spec marks it optional).")] + public string? IfMatch { get; set; } + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(TenantGovernancePolicyTemplateId, "Remove")) + return; + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + // DeleteAsync returns a plain Task: a standard delete response has no body. + try + { + client.Directory.TenantGovernance.GovernancePolicyTemplates[TenantGovernancePolicyTemplateId].DeleteAsync(requestConfiguration => + { + + if (this.IsParameterBound(nameof(IfMatch))) + requestConfiguration.Headers.Add("If-Match", IfMatch!); + + AddRequestHeaders(requestConfiguration.Headers); + }) + .GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, TenantGovernancePolicyTemplateId); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceRelatedTenant.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceRelatedTenant.g.cs new file mode 100644 index 00000000000..1409b33964d --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceRelatedTenant.g.cs @@ -0,0 +1,56 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("DELETE", "/directory/tenantGovernance/relatedTenants/{relatedTenant-id}")] + [Cmdlet(VerbsCommon.Remove, "MgDirectoryTenantGovernanceRelatedTenant", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.High)] + public class RemoveMgDirectoryTenantGovernanceRelatedTenantCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string RelatedTenantId { get; set; } = string.Empty; + + + [Parameter(Mandatory = false, + HelpMessage = "Sets the 'If-Match' request header (for example an ETag for optimistic concurrency; some Graph APIs require it even where the spec marks it optional).")] + public string? IfMatch { get; set; } + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(RelatedTenantId, "Remove")) + return; + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + // DeleteAsync returns a plain Task: a standard delete response has no body. + try + { + client.Directory.TenantGovernance.RelatedTenants[RelatedTenantId].DeleteAsync(requestConfiguration => + { + + if (this.IsParameterBound(nameof(IfMatch))) + requestConfiguration.Headers.Add("If-Match", IfMatch!); + + AddRequestHeaders(requestConfiguration.Headers); + }) + .GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, RelatedTenantId); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceRelationship.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceRelationship.g.cs new file mode 100644 index 00000000000..34ed0480fb1 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceRelationship.g.cs @@ -0,0 +1,56 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("DELETE", "/directory/tenantGovernance/governanceRelationships/{governanceRelationship-id}")] + [Cmdlet(VerbsCommon.Remove, "MgDirectoryTenantGovernanceRelationship", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.High)] + public class RemoveMgDirectoryTenantGovernanceRelationshipCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string GovernanceRelationshipId { get; set; } = string.Empty; + + + [Parameter(Mandatory = false, + HelpMessage = "Sets the 'If-Match' request header (for example an ETag for optimistic concurrency; some Graph APIs require it even where the spec marks it optional).")] + public string? IfMatch { get; set; } + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(GovernanceRelationshipId, "Remove")) + return; + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + // DeleteAsync returns a plain Task: a standard delete response has no body. + try + { + client.Directory.TenantGovernance.GovernanceRelationships[GovernanceRelationshipId].DeleteAsync(requestConfiguration => + { + + if (this.IsParameterBound(nameof(IfMatch))) + requestConfiguration.Headers.Add("If-Match", IfMatch!); + + AddRequestHeaders(requestConfiguration.Headers); + }) + .GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GovernanceRelationshipId); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceRequest.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceRequest.g.cs new file mode 100644 index 00000000000..37c6bbcd2db --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceRequest.g.cs @@ -0,0 +1,56 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("DELETE", "/directory/tenantGovernance/governanceRequests/{governanceRequest-id}")] + [Cmdlet(VerbsCommon.Remove, "MgDirectoryTenantGovernanceRequest", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.High)] + public class RemoveMgDirectoryTenantGovernanceRequestCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string GovernanceRequestId { get; set; } = string.Empty; + + + [Parameter(Mandatory = false, + HelpMessage = "Sets the 'If-Match' request header (for example an ETag for optimistic concurrency; some Graph APIs require it even where the spec marks it optional).")] + public string? IfMatch { get; set; } + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(GovernanceRequestId, "Remove")) + return; + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + // DeleteAsync returns a plain Task: a standard delete response has no body. + try + { + client.Directory.TenantGovernance.GovernanceRequests[GovernanceRequestId].DeleteAsync(requestConfiguration => + { + + if (this.IsParameterBound(nameof(IfMatch))) + requestConfiguration.Headers.Add("If-Match", IfMatch!); + + AddRequestHeaders(requestConfiguration.Headers); + }) + .GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GovernanceRequestId); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceSetting.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceSetting.g.cs new file mode 100644 index 00000000000..74fc7cb1351 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/RemoveMgDirectoryTenantGovernanceSetting.g.cs @@ -0,0 +1,55 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("DELETE", "/directory/tenantGovernance/settings")] + [Cmdlet(VerbsCommon.Remove, "MgDirectoryTenantGovernanceSetting", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.High)] + public class RemoveMgDirectoryTenantGovernanceSettingCommand : GraphClientCmdlet + { + + + + [Parameter(Mandatory = false, + HelpMessage = "Sets the 'If-Match' request header (for example an ETag for optimistic concurrency; some Graph APIs require it even where the spec marks it optional).")] + public string? IfMatch { get; set; } + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(null, "Remove")) + return; + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + // DeleteAsync returns a plain Task: a standard delete response has no body. + try + { + client.Directory.TenantGovernance.Settings.DeleteAsync(requestConfiguration => + { + + if (this.IsParameterBound(nameof(IfMatch))) + requestConfiguration.Headers.Add("If-Match", IfMatch!); + + AddRequestHeaders(requestConfiguration.Headers); + }) + .GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernance.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernance.g.cs new file mode 100644 index 00000000000..873f955a4c1 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernance.g.cs @@ -0,0 +1,75 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("PATCH", "/directory/tenantGovernance")] + [Cmdlet(VerbsData.Update, "MgDirectoryTenantGovernance", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance))] + public class UpdateMgDirectoryTenantGovernanceCommand : GraphClientCmdlet + { + + + + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(null, "Update")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance(); + + + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernance? result; + try + { + result = client.Directory.TenantGovernance.PatchAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + + + if (result is null) + { + WriteVerbose("PATCH succeeded with no response body, re-fetching the updated resource."); + try + { + result = client.Directory.TenantGovernance.GetAsync().GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + } + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceInvitation.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceInvitation.g.cs new file mode 100644 index 00000000000..05f90d30221 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceInvitation.g.cs @@ -0,0 +1,110 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("PATCH", "/directory/tenantGovernance/governanceInvitations/{governanceInvitation-id}")] + [Cmdlet(VerbsData.Update, "MgDirectoryTenantGovernanceInvitation", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation))] + public class UpdateMgDirectoryTenantGovernanceInvitationCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string GovernanceInvitationId { get; set; } = string.Empty; + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? CreatedDateTime { get; set; } + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? ExpirationDateTime { get; set; } + + [Parameter(Mandatory = false)] + public string? GovernedTenantId { get; set; } + + [Parameter(Mandatory = false)] + public string? GovernedTenantName { get; set; } + + [Parameter(Mandatory = false)] + public string? GoverningTenantId { get; set; } + + [Parameter(Mandatory = false)] + public string? GoverningTenantName { get; set; } + + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(GovernanceInvitationId, "Update")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation(); + + if (this.IsParameterBound(nameof(CreatedDateTime))) + body.CreatedDateTime = CreatedDateTime; + + if (this.IsParameterBound(nameof(ExpirationDateTime))) + body.ExpirationDateTime = ExpirationDateTime; + + if (this.IsParameterBound(nameof(GovernedTenantId))) + body.GovernedTenantId = GovernedTenantId; + + if (this.IsParameterBound(nameof(GovernedTenantName))) + body.GovernedTenantName = GovernedTenantName; + + if (this.IsParameterBound(nameof(GoverningTenantId))) + body.GoverningTenantId = GoverningTenantId; + + if (this.IsParameterBound(nameof(GoverningTenantName))) + body.GoverningTenantName = GoverningTenantName; + + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceInvitation? result; + try + { + result = client.Directory.TenantGovernance.GovernanceInvitations[GovernanceInvitationId].PatchAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GovernanceInvitationId); + return; + } + + + if (result is null) + { + WriteVerbose("PATCH succeeded with no response body, re-fetching the updated resource."); + try + { + result = client.Directory.TenantGovernance.GovernanceInvitations[GovernanceInvitationId].GetAsync().GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GovernanceInvitationId); + return; + } + } + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernancePolicyTemplate.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernancePolicyTemplate.g.cs new file mode 100644 index 00000000000..d17707dcaa8 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernancePolicyTemplate.g.cs @@ -0,0 +1,120 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("PATCH", "/directory/tenantGovernance/governancePolicyTemplates/{tenantGovernancePolicyTemplate-id}")] + [Cmdlet(VerbsData.Update, "MgDirectoryTenantGovernancePolicyTemplate", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate))] + public class UpdateMgDirectoryTenantGovernancePolicyTemplateCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string TenantGovernancePolicyTemplateId { get; set; } = string.Empty; + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? CreatedDateTime { get; set; } + + [Parameter(Mandatory = false)] + public string? Description { get; set; } + + [Parameter(Mandatory = false)] + public string? DisplayName { get; set; } + + [Parameter(Mandatory = false)] + public bool? GovernedTenantCanTerminate { get; set; } + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? LastModifiedDateTime { get; set; } + + [Parameter(Mandatory = false)] + public string? Version { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.DelegatedAdministrationRoleAssignment[]? DelegatedAdministrationRoleAssignments { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.MultiTenantApplicationsToProvision[]? MultiTenantApplicationsToProvision { get; set; } + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(TenantGovernancePolicyTemplateId, "Update")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate(); + + if (this.IsParameterBound(nameof(CreatedDateTime))) + body.CreatedDateTime = CreatedDateTime; + + if (this.IsParameterBound(nameof(Description))) + body.Description = Description; + + if (this.IsParameterBound(nameof(DisplayName))) + body.DisplayName = DisplayName; + + if (this.IsParameterBound(nameof(GovernedTenantCanTerminate))) + body.GovernedTenantCanTerminate = GovernedTenantCanTerminate; + + if (this.IsParameterBound(nameof(LastModifiedDateTime))) + body.LastModifiedDateTime = LastModifiedDateTime; + + if (this.IsParameterBound(nameof(Version))) + body.Version = Version; + + if (this.IsParameterBound(nameof(DelegatedAdministrationRoleAssignments))) + body.DelegatedAdministrationRoleAssignments = DelegatedAdministrationRoleAssignments!.ToList(); + + if (this.IsParameterBound(nameof(MultiTenantApplicationsToProvision))) + body.MultiTenantApplicationsToProvision = MultiTenantApplicationsToProvision!.ToList(); + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernancePolicyTemplate? result; + try + { + result = client.Directory.TenantGovernance.GovernancePolicyTemplates[TenantGovernancePolicyTemplateId].PatchAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, TenantGovernancePolicyTemplateId); + return; + } + + + if (result is null) + { + WriteVerbose("PATCH succeeded with no response body, re-fetching the updated resource."); + try + { + result = client.Directory.TenantGovernance.GovernancePolicyTemplates[TenantGovernancePolicyTemplateId].GetAsync().GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, TenantGovernancePolicyTemplateId); + return; + } + } + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceRelatedTenant.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceRelatedTenant.g.cs new file mode 100644 index 00000000000..a99c9fd5e83 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceRelatedTenant.g.cs @@ -0,0 +1,80 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("PATCH", "/directory/tenantGovernance/relatedTenants/{relatedTenant-id}")] + [Cmdlet(VerbsData.Update, "MgDirectoryTenantGovernanceRelatedTenant", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant))] + public class UpdateMgDirectoryTenantGovernanceRelatedTenantCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string RelatedTenantId { get; set; } = string.Empty; + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? CreatedDateTime { get; set; } + + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(RelatedTenantId, "Update")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant(); + + if (this.IsParameterBound(nameof(CreatedDateTime))) + body.CreatedDateTime = CreatedDateTime; + + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelatedTenant? result; + try + { + result = client.Directory.TenantGovernance.RelatedTenants[RelatedTenantId].PatchAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, RelatedTenantId); + return; + } + + + if (result is null) + { + WriteVerbose("PATCH succeeded with no response body, re-fetching the updated resource."); + try + { + result = client.Directory.TenantGovernance.RelatedTenants[RelatedTenantId].GetAsync().GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, RelatedTenantId); + return; + } + } + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceRelationship.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceRelationship.g.cs new file mode 100644 index 00000000000..8745ba6a74a --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceRelationship.g.cs @@ -0,0 +1,120 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("PATCH", "/directory/tenantGovernance/governanceRelationships/{governanceRelationship-id}")] + [Cmdlet(VerbsData.Update, "MgDirectoryTenantGovernanceRelationship", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship))] + public class UpdateMgDirectoryTenantGovernanceRelationshipCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string GovernanceRelationshipId { get; set; } = string.Empty; + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? CreationDateTime { get; set; } + + [Parameter(Mandatory = false)] + public string? GovernedTenantId { get; set; } + + [Parameter(Mandatory = false)] + public string? GovernedTenantName { get; set; } + + [Parameter(Mandatory = false)] + public string? GoverningTenantId { get; set; } + + [Parameter(Mandatory = false)] + public string? GoverningTenantName { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipCreationType? CreatedType { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipPolicy? PolicySnapshot { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipStatus? Status { get; set; } + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(GovernanceRelationshipId, "Update")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship(); + + if (this.IsParameterBound(nameof(CreationDateTime))) + body.CreationDateTime = CreationDateTime; + + if (this.IsParameterBound(nameof(GovernedTenantId))) + body.GovernedTenantId = GovernedTenantId; + + if (this.IsParameterBound(nameof(GovernedTenantName))) + body.GovernedTenantName = GovernedTenantName; + + if (this.IsParameterBound(nameof(GoverningTenantId))) + body.GoverningTenantId = GoverningTenantId; + + if (this.IsParameterBound(nameof(GoverningTenantName))) + body.GoverningTenantName = GoverningTenantName; + + if (this.IsParameterBound(nameof(CreatedType))) + body.CreatedType = CreatedType; + + if (this.IsParameterBound(nameof(PolicySnapshot))) + body.PolicySnapshot = PolicySnapshot; + + if (this.IsParameterBound(nameof(Status))) + body.Status = Status; + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRelationship? result; + try + { + result = client.Directory.TenantGovernance.GovernanceRelationships[GovernanceRelationshipId].PatchAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GovernanceRelationshipId); + return; + } + + + if (result is null) + { + WriteVerbose("PATCH succeeded with no response body, re-fetching the updated resource."); + try + { + result = client.Directory.TenantGovernance.GovernanceRelationships[GovernanceRelationshipId].GetAsync().GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GovernanceRelationshipId); + return; + } + } + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceRequest.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceRequest.g.cs new file mode 100644 index 00000000000..c0ed79bc40d --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceRequest.g.cs @@ -0,0 +1,120 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("PATCH", "/directory/tenantGovernance/governanceRequests/{governanceRequest-id}")] + [Cmdlet(VerbsData.Update, "MgDirectoryTenantGovernanceRequest", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest))] + public class UpdateMgDirectoryTenantGovernanceRequestCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string GovernanceRequestId { get; set; } = string.Empty; + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? ExpirationDateTime { get; set; } + + [Parameter(Mandatory = false)] + public string? GovernedTenantId { get; set; } + + [Parameter(Mandatory = false)] + public string? GovernedTenantName { get; set; } + + [Parameter(Mandatory = false)] + public string? GoverningTenantId { get; set; } + + [Parameter(Mandatory = false)] + public string? GoverningTenantName { get; set; } + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? RequestDateTime { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RelationshipPolicy? PolicySnapshot { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.RequestStatus? Status { get; set; } + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(GovernanceRequestId, "Update")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest(); + + if (this.IsParameterBound(nameof(ExpirationDateTime))) + body.ExpirationDateTime = ExpirationDateTime; + + if (this.IsParameterBound(nameof(GovernedTenantId))) + body.GovernedTenantId = GovernedTenantId; + + if (this.IsParameterBound(nameof(GovernedTenantName))) + body.GovernedTenantName = GovernedTenantName; + + if (this.IsParameterBound(nameof(GoverningTenantId))) + body.GoverningTenantId = GoverningTenantId; + + if (this.IsParameterBound(nameof(GoverningTenantName))) + body.GoverningTenantName = GoverningTenantName; + + if (this.IsParameterBound(nameof(RequestDateTime))) + body.RequestDateTime = RequestDateTime; + + if (this.IsParameterBound(nameof(PolicySnapshot))) + body.PolicySnapshot = PolicySnapshot; + + if (this.IsParameterBound(nameof(Status))) + body.Status = Status; + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.GovernanceRequest? result; + try + { + result = client.Directory.TenantGovernance.GovernanceRequests[GovernanceRequestId].PatchAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GovernanceRequestId); + return; + } + + + if (result is null) + { + WriteVerbose("PATCH succeeded with no response body, re-fetching the updated resource."); + try + { + result = client.Directory.TenantGovernance.GovernanceRequests[GovernanceRequestId].GetAsync().GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GovernanceRequestId); + return; + } + } + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceSetting.g.cs b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceSetting.g.cs new file mode 100644 index 00000000000..6c779da3439 --- /dev/null +++ b/src/Identity.DirectoryManagement/wrapper/v1.0/Cmdlets/UpdateMgDirectoryTenantGovernanceSetting.g.cs @@ -0,0 +1,85 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client; +using Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.DirectoryManagement +{ + [GraphRoute("PATCH", "/directory/tenantGovernance/settings")] + [Cmdlet(VerbsData.Update, "MgDirectoryTenantGovernanceSetting", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting))] + public class UpdateMgDirectoryTenantGovernanceSettingCommand : GraphClientCmdlet + { + + + [Parameter(Mandatory = false)] + public bool? CanReceiveInvitations { get; set; } + + [Parameter(Mandatory = false)] + public bool? IsRelatedTenantsEnabled { get; set; } + + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(null, "Update")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting(); + + if (this.IsParameterBound(nameof(CanReceiveInvitations))) + body.CanReceiveInvitations = CanReceiveInvitations; + + if (this.IsParameterBound(nameof(IsRelatedTenantsEnabled))) + body.IsRelatedTenantsEnabled = IsRelatedTenantsEnabled; + + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.DirectoryManagement.Client.Models.TenantGovernanceSetting? result; + try + { + result = client.Directory.TenantGovernance.Settings.PatchAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + + + if (result is null) + { + WriteVerbose("PATCH succeeded with no response body, re-fetching the updated resource."); + try + { + result = client.Directory.TenantGovernance.Settings.GetAsync().GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + } + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Definitions/Item/Instances/Item/AccessReviewInstanceItemRequestBuilder.cs b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Definitions/Item/Instances/Item/AccessReviewInstanceItemRequestBuilder.cs index 2e1ab77ba03..61403860f7e 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Definitions/Item/Instances/Item/AccessReviewInstanceItemRequestBuilder.cs +++ b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Definitions/Item/Instances/Item/AccessReviewInstanceItemRequestBuilder.cs @@ -2,6 +2,7 @@ #pragma warning disable CS0618 using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.AcceptRecommendations; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.ApplyDecisions; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchRecordDecisions; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.ContactedReviewers; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.Decisions; @@ -37,6 +38,11 @@ public partial class AccessReviewInstanceItemRequestBuilder : BaseRequestBuilder { get => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.ApplyDecisions.ApplyDecisionsRequestBuilder(PathParameters, RequestAdapter); } + /// The batchApplyCustomDataProvidedResourceDecisions property + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder BatchApplyCustomDataProvidedResourceDecisions + { + get => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder(PathParameters, RequestAdapter); + } /// The batchRecordDecisions property public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchRecordDecisions.BatchRecordDecisionsRequestBuilder BatchRecordDecisions { diff --git a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody.cs b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody.cs new file mode 100644 index 00000000000..5cbc3d4a7f9 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody.cs @@ -0,0 +1,80 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The applyDescription property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? ApplyDescription { get; set; } +#nullable restore +#else + public string ApplyDescription { get; set; } +#endif + /// The applyResult property + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemApplyResult? ApplyResult { get; set; } + /// The customDataProvidedResourceId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? CustomDataProvidedResourceId { get; set; } +#nullable restore +#else + public string CustomDataProvidedResourceId { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "applyDescription", n => { ApplyDescription = n.GetStringValue(); } }, + { "applyResult", n => { ApplyResult = n.GetEnumValue(); } }, + { "customDataProvidedResourceId", n => { CustomDataProvidedResourceId = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteStringValue("applyDescription", ApplyDescription); + writer.WriteEnumValue("applyResult", ApplyResult); + writer.WriteStringValue("customDataProvidedResourceId", CustomDataProvidedResourceId); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder.cs b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder.cs new file mode 100644 index 00000000000..3a8dff75458 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder.cs @@ -0,0 +1,101 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions +{ + /// + /// Builds and executes requests for operations under \identityGovernance\accessReviews\definitions\{accessReviewScheduleDefinition-id}\instances\{accessReviewInstance-id}\batchApplyCustomDataProvidedResourceDecisions + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/identityGovernance/accessReviews/definitions/{accessReviewScheduleDefinition%2Did}/instances/{accessReviewInstance%2Did}/batchApplyCustomDataProvidedResourceDecisions", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/identityGovernance/accessReviews/definitions/{accessReviewScheduleDefinition%2Did}/instances/{accessReviewInstance%2Did}/batchApplyCustomDataProvidedResourceDecisions", rawUrl) + { + } + /// + /// Invoke action batchApplyCustomDataProvidedResourceDecisions + /// + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPostRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Invoke action batchApplyCustomDataProvidedResourceDecisions + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.POST, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class BatchApplyCustomDataProvidedResourceDecisionsRequestBuilderPostRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Definitions/Item/Instances/Item/AccessReviewInstanceItemRequestBuilder.cs b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Definitions/Item/Instances/Item/AccessReviewInstanceItemRequestBuilder.cs index 3dcbb3f579e..aaf8e84a9df 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Definitions/Item/Instances/Item/AccessReviewInstanceItemRequestBuilder.cs +++ b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Definitions/Item/Instances/Item/AccessReviewInstanceItemRequestBuilder.cs @@ -2,6 +2,7 @@ #pragma warning disable CS0618 using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.AcceptRecommendations; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.ApplyDecisions; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchRecordDecisions; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.ContactedReviewers; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.Decisions; @@ -37,6 +38,11 @@ public partial class AccessReviewInstanceItemRequestBuilder : BaseRequestBuilder { get => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.ApplyDecisions.ApplyDecisionsRequestBuilder(PathParameters, RequestAdapter); } + /// The batchApplyCustomDataProvidedResourceDecisions property + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder BatchApplyCustomDataProvidedResourceDecisions + { + get => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder(PathParameters, RequestAdapter); + } /// The batchRecordDecisions property public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchRecordDecisions.BatchRecordDecisionsRequestBuilder BatchRecordDecisions { diff --git a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody.cs b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody.cs new file mode 100644 index 00000000000..2b22039ca3d --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody.cs @@ -0,0 +1,80 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The applyDescription property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? ApplyDescription { get; set; } +#nullable restore +#else + public string ApplyDescription { get; set; } +#endif + /// The applyResult property + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemApplyResult? ApplyResult { get; set; } + /// The customDataProvidedResourceId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? CustomDataProvidedResourceId { get; set; } +#nullable restore +#else + public string CustomDataProvidedResourceId { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "applyDescription", n => { ApplyDescription = n.GetStringValue(); } }, + { "applyResult", n => { ApplyResult = n.GetEnumValue(); } }, + { "customDataProvidedResourceId", n => { CustomDataProvidedResourceId = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteStringValue("applyDescription", ApplyDescription); + writer.WriteEnumValue("applyResult", ApplyResult); + writer.WriteStringValue("customDataProvidedResourceId", CustomDataProvidedResourceId); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder.cs b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder.cs new file mode 100644 index 00000000000..fce81cc275e --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Definitions/Item/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder.cs @@ -0,0 +1,101 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions +{ + /// + /// Builds and executes requests for operations under \identityGovernance\accessReviews\unified\definitions\{accessReviewScheduleDefinition-id}\instances\{accessReviewInstance-id}\batchApplyCustomDataProvidedResourceDecisions + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/identityGovernance/accessReviews/unified/definitions/{accessReviewScheduleDefinition%2Did}/instances/{accessReviewInstance%2Did}/batchApplyCustomDataProvidedResourceDecisions", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/identityGovernance/accessReviews/unified/definitions/{accessReviewScheduleDefinition%2Did}/instances/{accessReviewInstance%2Did}/batchApplyCustomDataProvidedResourceDecisions", rawUrl) + { + } + /// + /// Invoke action batchApplyCustomDataProvidedResourceDecisions + /// + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPostRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Invoke action batchApplyCustomDataProvidedResourceDecisions + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.POST, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class BatchApplyCustomDataProvidedResourceDecisionsRequestBuilderPostRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Instances/Item/AccessReviewInstanceItemRequestBuilder.cs b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Instances/Item/AccessReviewInstanceItemRequestBuilder.cs index ca31c8e7603..ecaa4fd7382 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Instances/Item/AccessReviewInstanceItemRequestBuilder.cs +++ b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Instances/Item/AccessReviewInstanceItemRequestBuilder.cs @@ -2,6 +2,7 @@ #pragma warning disable CS0618 using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.AcceptRecommendations; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.ApplyDecisions; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchRecordDecisions; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.ContactedReviewers; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.Decisions; @@ -37,6 +38,11 @@ public partial class AccessReviewInstanceItemRequestBuilder : BaseRequestBuilder { get => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.ApplyDecisions.ApplyDecisionsRequestBuilder(PathParameters, RequestAdapter); } + /// The batchApplyCustomDataProvidedResourceDecisions property + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder BatchApplyCustomDataProvidedResourceDecisions + { + get => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder(PathParameters, RequestAdapter); + } /// The batchRecordDecisions property public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchRecordDecisions.BatchRecordDecisionsRequestBuilder BatchRecordDecisions { diff --git a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody.cs b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody.cs new file mode 100644 index 00000000000..8e2b2e97869 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody.cs @@ -0,0 +1,80 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The applyDescription property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? ApplyDescription { get; set; } +#nullable restore +#else + public string ApplyDescription { get; set; } +#endif + /// The applyResult property + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemApplyResult? ApplyResult { get; set; } + /// The customDataProvidedResourceId property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? CustomDataProvidedResourceId { get; set; } +#nullable restore +#else + public string CustomDataProvidedResourceId { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "applyDescription", n => { ApplyDescription = n.GetStringValue(); } }, + { "applyResult", n => { ApplyResult = n.GetEnumValue(); } }, + { "customDataProvidedResourceId", n => { CustomDataProvidedResourceId = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteStringValue("applyDescription", ApplyDescription); + writer.WriteEnumValue("applyResult", ApplyResult); + writer.WriteStringValue("customDataProvidedResourceId", CustomDataProvidedResourceId); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder.cs b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder.cs new file mode 100644 index 00000000000..3b52dc33463 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/AccessReviews/Unified/Instances/Item/BatchApplyCustomDataProvidedResourceDecisions/BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder.cs @@ -0,0 +1,101 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions +{ + /// + /// Builds and executes requests for operations under \identityGovernance\accessReviews\unified\instances\{accessReviewInstance-id}\batchApplyCustomDataProvidedResourceDecisions + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/identityGovernance/accessReviews/unified/instances/{accessReviewInstance%2Did}/batchApplyCustomDataProvidedResourceDecisions", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/identityGovernance/accessReviews/unified/instances/{accessReviewInstance%2Did}/batchApplyCustomDataProvidedResourceDecisions", rawUrl) + { + } + /// + /// Invoke action batchApplyCustomDataProvidedResourceDecisions + /// + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPostRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Invoke action batchApplyCustomDataProvidedResourceDecisions + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.POST, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class BatchApplyCustomDataProvidedResourceDecisionsRequestBuilderPostRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/GroupRequestBuilder.cs b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/GroupRequestBuilder.cs index f3f88502217..02418d8bb3f 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/GroupRequestBuilder.cs +++ b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/GroupRequestBuilder.cs @@ -7,6 +7,7 @@ using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.EligibilityScheduleInstances; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.EligibilityScheduleRequests; using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.EligibilitySchedules; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources; using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors; using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; using Microsoft.Kiota.Abstractions.Extensions; @@ -60,6 +61,11 @@ public partial class GroupRequestBuilder : BaseRequestBuilder { get => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.EligibilitySchedules.EligibilitySchedulesRequestBuilder(PathParameters, RequestAdapter); } + /// The resources property + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.ResourcesRequestBuilder Resources + { + get => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.ResourcesRequestBuilder(PathParameters, RequestAdapter); + } /// /// Instantiates a new and sets the default values. /// diff --git a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/Resources/Count/CountRequestBuilder.cs b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/Resources/Count/CountRequestBuilder.cs new file mode 100644 index 00000000000..8c8cb4481db --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/Resources/Count/CountRequestBuilder.cs @@ -0,0 +1,124 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.Count +{ + /// + /// Builds and executes requests for operations under \identityGovernance\privilegedAccess\group\resources\$count + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public CountRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/identityGovernance/privilegedAccess/group/resources/$count{?%24filter,%24search}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public CountRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/identityGovernance/privilegedAccess/group/resources/$count{?%24filter,%24search}", rawUrl) + { + } + /// + /// Get the number of the resource + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendPrimitiveAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get the number of the resource + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "text/plain;q=0.9"); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.Count.CountRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.Count.CountRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get the number of the resource + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilderGetQueryParameters + { + /// Filter items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24filter")] + public string? Filter { get; set; } +#nullable restore +#else + [QueryParameter("%24filter")] + public string Filter { get; set; } +#endif + /// Search items by search phrases +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24search")] + public string? Search { get; set; } +#nullable restore +#else + [QueryParameter("%24search")] + public string Search { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class CountRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/Resources/Item/GroupResourceItemRequestBuilder.cs b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/Resources/Item/GroupResourceItemRequestBuilder.cs new file mode 100644 index 00000000000..a95316289b1 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/Resources/Item/GroupResourceItemRequestBuilder.cs @@ -0,0 +1,229 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.Item +{ + /// + /// Builds and executes requests for operations under \identityGovernance\privilegedAccess\group\resources\{groupResource-id} + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GroupResourceItemRequestBuilder : BaseRequestBuilder + { + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public GroupResourceItemRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/identityGovernance/privilegedAccess/group/resources/{groupResource%2Did}{?%24expand,%24select}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public GroupResourceItemRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/identityGovernance/privilegedAccess/group/resources/{groupResource%2Did}{?%24expand,%24select}", rawUrl) + { + } + /// + /// Delete navigation property resources for identityGovernance + /// + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task DeleteAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task DeleteAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToDeleteRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + await RequestAdapter.SendNoContentAsync(requestInfo, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get resources from identityGovernance + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Update the navigation property resources in identityGovernance + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PatchAsync(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPatchRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Delete navigation property resources for identityGovernance + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToDeleteRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToDeleteRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.DELETE, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Get resources from identityGovernance + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Update the navigation property resources in identityGovernance + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPatchRequestInformation(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.PATCH, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.Item.GroupResourceItemRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.Item.GroupResourceItemRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GroupResourceItemRequestBuilderDeleteRequestConfiguration : RequestConfiguration + { + } + /// + /// Get resources from identityGovernance + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GroupResourceItemRequestBuilderGetQueryParameters + { + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GroupResourceItemRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class GroupResourceItemRequestBuilderPatchRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/Resources/ResourcesRequestBuilder.cs b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/Resources/ResourcesRequestBuilder.cs new file mode 100644 index 00000000000..22ab9fb946b --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/IdentityGovernance/PrivilegedAccess/Group/Resources/ResourcesRequestBuilder.cs @@ -0,0 +1,238 @@ +// +#pragma warning disable CS0618 +using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.Count; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.Item; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using Microsoft.Kiota.Abstractions; +using System.Collections.Generic; +using System.IO; +using System.Threading.Tasks; +using System.Threading; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources +{ + /// + /// Builds and executes requests for operations under \identityGovernance\privilegedAccess\group\resources + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class ResourcesRequestBuilder : BaseRequestBuilder + { + /// The Count property + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.Count.CountRequestBuilder Count + { + get => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.Count.CountRequestBuilder(PathParameters, RequestAdapter); + } + /// Gets an item from the Microsoft.Graph.PowerShell.Identity.Governance.Client.identityGovernance.privilegedAccess.group.resources.item collection + /// Unique identifier of the item + /// A + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.Item.GroupResourceItemRequestBuilder this[string position] + { + get + { + var urlTplParams = new Dictionary(PathParameters); + urlTplParams.Add("groupResource%2Did", position); + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.Item.GroupResourceItemRequestBuilder(urlTplParams, RequestAdapter); + } + } + /// + /// Instantiates a new and sets the default values. + /// + /// Path parameters for the request + /// The request adapter to use to execute the requests. + public ResourcesRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/identityGovernance/privilegedAccess/group/resources{?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", pathParameters) + { + } + /// + /// Instantiates a new and sets the default values. + /// + /// The raw URL to use for the request builder. + /// The request adapter to use to execute the requests. + public ResourcesRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/identityGovernance/privilegedAccess/group/resources{?%24count,%24expand,%24filter,%24orderby,%24search,%24select,%24skip,%24top}", rawUrl) + { + } + /// + /// Get resources from identityGovernance + /// + /// A + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task GetAsync(Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task GetAsync(Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + var requestInfo = ToGetRequestInformation(requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResourceCollectionResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Create new navigation property to resources for identityGovernance + /// + /// A + /// The request body + /// Cancellation token to use when cancelling requests + /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 4XX or 5XX status code +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource body, Action>? requestConfiguration = default, CancellationToken cancellationToken = default) + { +#nullable restore +#else + public async Task PostAsync(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource body, Action> requestConfiguration = default, CancellationToken cancellationToken = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = ToPostRequestInformation(body, requestConfiguration); + var errorMapping = new Dictionary> + { + { "XXX", global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ODataErrors.ODataError.CreateFromDiscriminatorValue }, + }; + return await RequestAdapter.SendAsync(requestInfo, global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); + } + /// + /// Get resources from identityGovernance + /// + /// A + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToGetRequestInformation(Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToGetRequestInformation(Action> requestConfiguration = default) + { +#endif + var requestInfo = new RequestInformation(Method.GET, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + return requestInfo; + } + /// + /// Create new navigation property to resources for identityGovernance + /// + /// A + /// The request body + /// Configuration for the request such as headers, query parameters, and middleware options. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource body, Action>? requestConfiguration = default) + { +#nullable restore +#else + public RequestInformation ToPostRequestInformation(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource body, Action> requestConfiguration = default) + { +#endif + if(ReferenceEquals(body, null)) throw new ArgumentNullException(nameof(body)); + var requestInfo = new RequestInformation(Method.POST, UrlTemplate, PathParameters); + requestInfo.Configure(requestConfiguration); + requestInfo.Headers.TryAdd("Accept", "application/json"); + requestInfo.SetContentFromParsable(RequestAdapter, "application/json", body); + return requestInfo; + } + /// + /// Returns a request builder with the provided arbitrary URL. Using this method means any other path or query parameters are ignored. + /// + /// A + /// The raw URL to use for the request builder. + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.ResourcesRequestBuilder WithUrl(string rawUrl) + { + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.PrivilegedAccess.Group.Resources.ResourcesRequestBuilder(rawUrl, RequestAdapter); + } + /// + /// Get resources from identityGovernance + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class ResourcesRequestBuilderGetQueryParameters + { + /// Include count of items + [QueryParameter("%24count")] + public bool? Count { get; set; } + /// Expand related entities +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24expand")] + public string[]? Expand { get; set; } +#nullable restore +#else + [QueryParameter("%24expand")] + public string[] Expand { get; set; } +#endif + /// Filter items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24filter")] + public string? Filter { get; set; } +#nullable restore +#else + [QueryParameter("%24filter")] + public string Filter { get; set; } +#endif + /// Order items by property values +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24orderby")] + public string[]? Orderby { get; set; } +#nullable restore +#else + [QueryParameter("%24orderby")] + public string[] Orderby { get; set; } +#endif + /// Search items by search phrases +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24search")] + public string? Search { get; set; } +#nullable restore +#else + [QueryParameter("%24search")] + public string Search { get; set; } +#endif + /// Select properties to be returned +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("%24select")] + public string[]? Select { get; set; } +#nullable restore +#else + [QueryParameter("%24select")] + public string[] Select { get; set; } +#endif + /// Skip the first n items + [QueryParameter("%24skip")] + public int? Skip { get; set; } + /// Show only the first n items + [QueryParameter("%24top")] + public int? Top { get; set; } + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class ResourcesRequestBuilderGetRequestConfiguration : RequestConfiguration + { + } + /// + /// Configuration for the request such as headers, query parameters, and middleware options. + /// + [Obsolete("This class is deprecated. Please use the generic RequestConfiguration class generated by the generator.")] + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + public partial class ResourcesRequestBuilderPostRequestConfiguration : RequestConfiguration + { + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessPackageAssignmentRequest.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessPackageAssignmentRequest.cs index c27c2f74451..6cd8efbdc21 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessPackageAssignmentRequest.cs +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessPackageAssignmentRequest.cs @@ -55,6 +55,14 @@ public partial class AccessPackageAssignmentRequest : global::Microsoft.Graph.Po #nullable restore #else public string Justification { get; set; } +#endif + /// The parameters property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessPackageAssignmentRequestParameters? Parameters { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessPackageAssignmentRequestParameters Parameters { get; set; } #endif /// The subject who requested or, if a direct assignment, was assigned. Read-only. Nullable. Supports $expand. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -109,6 +117,7 @@ public override IDictionary> GetFieldDeserializers() { "createdDateTime", n => { CreatedDateTime = n.GetDateTimeOffsetValue(); } }, { "customExtensionCalloutInstances", n => { CustomExtensionCalloutInstances = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.CustomExtensionCalloutInstance.CreateFromDiscriminatorValue)?.AsList(); } }, { "justification", n => { Justification = n.GetStringValue(); } }, + { "parameters", n => { Parameters = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessPackageAssignmentRequestParameters.CreateFromDiscriminatorValue); } }, { "requestType", n => { RequestType = n.GetEnumValue(); } }, { "requestor", n => { Requestor = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessPackageSubject.CreateFromDiscriminatorValue); } }, { "schedule", n => { Schedule = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.EntitlementManagementSchedule.CreateFromDiscriminatorValue); } }, @@ -131,6 +140,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteDateTimeOffsetValue("createdDateTime", CreatedDateTime); writer.WriteCollectionOfObjectValues("customExtensionCalloutInstances", CustomExtensionCalloutInstances); writer.WriteStringValue("justification", Justification); + writer.WriteObjectValue("parameters", Parameters); writer.WriteObjectValue("requestor", Requestor); writer.WriteEnumValue("requestType", RequestType); writer.WriteObjectValue("schedule", Schedule); diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessPackageAssignmentRequestParameters.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessPackageAssignmentRequestParameters.cs new file mode 100644 index 00000000000..f6a8f0c312d --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessPackageAssignmentRequestParameters.cs @@ -0,0 +1,69 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class AccessPackageAssignmentRequestParameters : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The bypassApproval property + public bool? BypassApproval { get; set; } + /// The OdataType property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? OdataType { get; set; } +#nullable restore +#else + public string OdataType { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public AccessPackageAssignmentRequestParameters() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessPackageAssignmentRequestParameters CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessPackageAssignmentRequestParameters(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "bypassApproval", n => { BypassApproval = n.GetBoolValue(); } }, + { "@odata.type", n => { OdataType = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteBoolValue("bypassApproval", BypassApproval); + writer.WriteStringValue("@odata.type", OdataType); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItem.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItem.cs index e4649ea6a34..c105f336e1b 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItem.cs +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItem.cs @@ -69,6 +69,14 @@ public partial class AccessReviewInstanceDecisionItem : global::Microsoft.Graph. #nullable restore #else public string Justification { get; set; } +#endif + /// The permission property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission Permission { get; set; } #endif /// Every decision item in an access review represents a principal's access to a resource. This property represents details of the principal. For example, if a decision item represents access of User 'Bob' to Group 'Sales' - The principal is 'Bob' and the resource is 'Sales'. Principals can be of two types - userIdentity and servicePrincipalIdentity. Supports $select. Read-only. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -146,6 +154,7 @@ public override IDictionary> GetFieldDeserializers() { "decision", n => { Decision = n.GetStringValue(); } }, { "insights", n => { Insights = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GovernanceInsight.CreateFromDiscriminatorValue)?.AsList(); } }, { "justification", n => { Justification = n.GetStringValue(); } }, + { "permission", n => { Permission = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission.CreateFromDiscriminatorValue); } }, { "principal", n => { Principal = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity.CreateFromDiscriminatorValue); } }, { "principalLink", n => { PrincipalLink = n.GetStringValue(); } }, { "recommendation", n => { Recommendation = n.GetStringValue(); } }, @@ -171,6 +180,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteStringValue("decision", Decision); writer.WriteCollectionOfObjectValues("insights", Insights); writer.WriteStringValue("justification", Justification); + writer.WriteObjectValue("permission", Permission); writer.WriteObjectValue("principal", Principal); writer.WriteStringValue("principalLink", PrincipalLink); writer.WriteStringValue("recommendation", Recommendation); diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItemApplyResult.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItemApplyResult.cs new file mode 100644 index 00000000000..0a9f3dee98e --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItemApplyResult.cs @@ -0,0 +1,36 @@ +// +using System.Runtime.Serialization; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public enum AccessReviewInstanceDecisionItemApplyResult + #pragma warning restore CS1591 + { + [EnumMember(Value = "new")] + #pragma warning disable CS1591 + New, + #pragma warning restore CS1591 + [EnumMember(Value = "appliedSuccessfully")] + #pragma warning disable CS1591 + AppliedSuccessfully, + #pragma warning restore CS1591 + [EnumMember(Value = "appliedWithUnknownFailure")] + #pragma warning disable CS1591 + AppliedWithUnknownFailure, + #pragma warning restore CS1591 + [EnumMember(Value = "appliedSuccessfullyButObjectNotFound")] + #pragma warning disable CS1591 + AppliedSuccessfullyButObjectNotFound, + #pragma warning restore CS1591 + [EnumMember(Value = "applyNotSupported")] + #pragma warning disable CS1591 + ApplyNotSupported, + #pragma warning restore CS1591 + [EnumMember(Value = "unknownFutureValue")] + #pragma warning disable CS1591 + UnknownFutureValue, + #pragma warning restore CS1591 + } +} diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItemPermission.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItemPermission.cs new file mode 100644 index 00000000000..f16e9d9a916 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItemPermission.cs @@ -0,0 +1,105 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class AccessReviewInstanceDecisionItemPermission : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The description property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Description { get; set; } +#nullable restore +#else + public string Description { get; set; } +#endif + /// The displayName property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? DisplayName { get; set; } +#nullable restore +#else + public string DisplayName { get; set; } +#endif + /// The id property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Id { get; set; } +#nullable restore +#else + public string Id { get; set; } +#endif + /// The OdataType property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? OdataType { get; set; } +#nullable restore +#else + public string OdataType { get; set; } +#endif + /// The type property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Type { get; set; } +#nullable restore +#else + public string Type { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public AccessReviewInstanceDecisionItemPermission() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "description", n => { Description = n.GetStringValue(); } }, + { "displayName", n => { DisplayName = n.GetStringValue(); } }, + { "id", n => { Id = n.GetStringValue(); } }, + { "@odata.type", n => { OdataType = n.GetStringValue(); } }, + { "type", n => { Type = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteStringValue("description", Description); + writer.WriteStringValue("displayName", DisplayName); + writer.WriteStringValue("id", Id); + writer.WriteStringValue("@odata.type", OdataType); + writer.WriteStringValue("type", Type); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItemResource.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItemResource.cs index db76d8f87ef..19117f7f1eb 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItemResource.cs +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/AccessReviewInstanceDecisionItemResource.cs @@ -14,6 +14,14 @@ public partial class AccessReviewInstanceDecisionItemResource : IAdditionalDataH { /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. public IDictionary AdditionalData { get; set; } + /// The description property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Description { get; set; } +#nullable restore +#else + public string Description { get; set; } +#endif /// Display name of the resource #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable @@ -71,6 +79,7 @@ public virtual IDictionary> GetFieldDeserializers() { return new Dictionary> { + { "description", n => { Description = n.GetStringValue(); } }, { "displayName", n => { DisplayName = n.GetStringValue(); } }, { "id", n => { Id = n.GetStringValue(); } }, { "@odata.type", n => { OdataType = n.GetStringValue(); } }, @@ -84,6 +93,7 @@ public virtual IDictionary> GetFieldDeserializers() public virtual void Serialize(ISerializationWriter writer) { if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + writer.WriteStringValue("description", Description); writer.WriteStringValue("displayName", DisplayName); writer.WriteStringValue("id", Id); writer.WriteStringValue("@odata.type", OdataType); diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/DirectoryObject.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/DirectoryObject.cs index 1e33b6821bd..7892706ea81 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/Models/DirectoryObject.cs +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/DirectoryObject.cs @@ -28,6 +28,7 @@ public partial class DirectoryObject : global::Microsoft.Graph.PowerShell.Identi "#microsoft.graph.appRoleAssignment" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AppRoleAssignment(), "#microsoft.graph.device" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Device(), "#microsoft.graph.group" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Group(), + "#microsoft.graph.groupResource" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource(), "#microsoft.graph.resourceSpecificPermissionGrant" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ResourceSpecificPermissionGrant(), "#microsoft.graph.user" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.User(), _ => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.DirectoryObject(), diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/Entity.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/Entity.cs index dceb69b8b2e..41bceffd797 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/Entity.cs @@ -158,6 +158,7 @@ public Entity() "#microsoft.graph.governanceInsight" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GovernanceInsight(), "#microsoft.graph.group" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Group(), "#microsoft.graph.groupLifecyclePolicy" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupLifecyclePolicy(), + "#microsoft.graph.groupResource" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource(), "#microsoft.graph.groupSetting" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupSetting(), "#microsoft.graph.identityGovernance.customTaskExtension" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.IdentityGovernance.CustomTaskExtension(), "#microsoft.graph.identityGovernance.insights" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.IdentityGovernance.Insights(), @@ -195,6 +196,7 @@ public Entity() "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.OfferShiftRequest(), diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/Group.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/Group.cs index 28e27fe7a0a..1520680d9a7 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Identity.Governa #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/GroupResource.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/GroupResource.cs new file mode 100644 index 00000000000..63295e2a3ce --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/GroupResource.cs @@ -0,0 +1,53 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class GroupResource : global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.DirectoryObject, IParsable + #pragma warning restore CS1591 + { + /// + /// Instantiates a new and sets the default values. + /// + public GroupResource() : base() + { + OdataType = "#microsoft.graph.groupResource"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/GroupResourceCollectionResponse.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/GroupResourceCollectionResponse.cs new file mode 100644 index 00000000000..42fe9c10217 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/GroupResourceCollectionResponse.cs @@ -0,0 +1,56 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class GroupResourceCollectionResponse : global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.BaseCollectionPaginationCountResponse, IParsable + #pragma warning restore CS1591 + { + /// The value property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Value { get; set; } +#nullable restore +#else + public List Value { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResourceCollectionResponse CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResourceCollectionResponse(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "value", n => { Value = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource.CreateFromDiscriminatorValue)?.AsList(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("value", Value); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/Note.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..1c69ad82c8d --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.Governance.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/OutlookItem.cs index 68be639e6c2..be4b182e9ef 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Identity.G "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.OutlookItem(), }; diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/PrivilegedAccessGroup.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/PrivilegedAccessGroup.cs index b96150ce7ad..83f61c28a47 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/Models/PrivilegedAccessGroup.cs +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/PrivilegedAccessGroup.cs @@ -67,6 +67,14 @@ public partial class PrivilegedAccessGroup : global::Microsoft.Graph.PowerShell. #nullable restore #else public List EligibilitySchedules { get; set; } +#endif + /// The resources property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Resources { get; set; } +#nullable restore +#else + public List Resources { get; set; } #endif /// /// Creates a new instance of the appropriate class based on discriminator value @@ -93,6 +101,7 @@ public override IDictionary> GetFieldDeserializers() { "eligibilityScheduleInstances", n => { EligibilityScheduleInstances = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.PrivilegedAccessGroupEligibilityScheduleInstance.CreateFromDiscriminatorValue)?.AsList(); } }, { "eligibilityScheduleRequests", n => { EligibilityScheduleRequests = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.PrivilegedAccessGroupEligibilityScheduleRequest.CreateFromDiscriminatorValue)?.AsList(); } }, { "eligibilitySchedules", n => { EligibilitySchedules = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.PrivilegedAccessGroupEligibilitySchedule.CreateFromDiscriminatorValue)?.AsList(); } }, + { "resources", n => { Resources = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource.CreateFromDiscriminatorValue)?.AsList(); } }, }; } /// @@ -110,6 +119,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("eligibilityScheduleInstances", EligibilityScheduleInstances); writer.WriteCollectionOfObjectValues("eligibilityScheduleRequests", EligibilityScheduleRequests); writer.WriteCollectionOfObjectValues("eligibilitySchedules", EligibilitySchedules); + writer.WriteCollectionOfObjectValues("resources", Resources); } } } diff --git a/src/Identity.Governance/wrapper/v1.0/Client/Models/User.cs b/src/Identity.Governance/wrapper/v1.0/Client/Models/User.cs index 9388d0f26eb..c1841bdbd9f 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/Models/User.cs +++ b/src/Identity.Governance/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Identity.Governan #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Identity.Governance/wrapper/v1.0/Client/kiota-lock.json b/src/Identity.Governance/wrapper/v1.0/Client/kiota-lock.json index 600d2fea5ba..1bd23afd628 100644 --- a/src/Identity.Governance/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Identity.Governance/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "E583B2A1684E48611DE922492AB2C8370C899F77795263F669E31C854381C14E5B8DD0908C6E4AF6AA30CC812D69BC58AD35647A22B11E157984143B35A972FF", + "descriptionHash": "E70820FE62D1CE4342131685B32F943183A3F8C9E534ADE28EB3E8BC5C928E6B2866FC5AAD7C7567EB2FD8E6698A80BE343C483EC0CA69B73567E19F245B5175", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Identity.Governance.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Identity.Governance.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResource.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResource.g.cs new file mode 100644 index 00000000000..1c240b5afd4 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResource.g.cs @@ -0,0 +1,91 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Management.Automation.Runspaces; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; + +namespace Microsoft.Graph.PowerShell.Identity.Governance +{ + [GraphRoute("GET", "/identityGovernance/privilegedAccess/group/resources")] + [Cmdlet(VerbsCommon.Get, "MgIdentityGovernancePrivilegedAccessGroupResource", DefaultParameterSetName = "List")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResourceCollectionResponse), ParameterSetName = new[] { "List" })] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource), ParameterSetName = new[] { "Get" })] + public class GetMgIdentityGovernancePrivilegedAccessGroupResourceCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, ParameterSetName = "Get", Position = 0)] + public string GroupResourceId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public string? Filter { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + [Alias("OrderBy")] + public string[]? Sort { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public string? Search { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public int Top { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public int Skip { get; set; } + + [Parameter(Mandatory = false, ParameterSetName = "List")] + public SwitchParameter Count { get; set; } + + // Declared here because the binder rejects a parameter the dispatcher does not accept + // before ProcessRecord ever runs; once declared, the wholesale BoundParameters splat + // forwards it to the list worker with no further plumbing. + [Parameter(Mandatory = false, ParameterSetName = "List")] + public SwitchParameter All { get; set; } + + + + + + // Delegates to Get-MgIdentityGovernancePrivilegedAccessGroupResource_Get or Get-MgIdentityGovernancePrivilegedAccessGroupResource_List, the two cmdlets + // that actually call Graph. + protected override void ProcessRecord() + { + var internalCmdletName = ParameterSetName == "Get" ? "Get-MgIdentityGovernancePrivilegedAccessGroupResource_Get" : "Get-MgIdentityGovernancePrivilegedAccessGroupResource_List"; + try + { + InvokeCommand.InvokeScript( + "param($BoundParameters, $CmdletName) & $CmdletName @BoundParameters", + false, + PipelineResultTypes.Output | PipelineResultTypes.Error, + null, + MyInvocation.BoundParameters, internalCmdletName); + } + // The workers signal failure via ThrowTerminatingError, which InvokeScript surfaces + // as a RuntimeException carrying the worker's ErrorRecord. Rethrow that record + // unchanged so the caller sees the worker's error identity (NoGraphSession, + // GraphRequestFailed, ...) instead of every failure collapsing into a generic + // dispatcher error. A pipeline stop is a RuntimeException too and must NOT be + // rethrown as a terminating error - both filters here let it pass to the engine. + catch (RuntimeException rex) when (rex is not PipelineStoppedException && rex.ErrorRecord is not null) + { + ThrowTerminatingError(rex.ErrorRecord); + return; + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, ParameterSetName == "Get" ? GroupResourceId : null); + return; + } + } + } +} diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResourceCount.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResourceCount.g.cs new file mode 100644 index 00000000000..e403925326c --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResourceCount.g.cs @@ -0,0 +1,61 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.Governance.Client; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.Governance +{ + [GraphRoute("GET", "/identityGovernance/privilegedAccess/group/resources/$count")] + [Cmdlet(VerbsCommon.Get, "MgIdentityGovernancePrivilegedAccessGroupResourceCount")] + [OutputType(typeof(int))] + public class GetMgIdentityGovernancePrivilegedAccessGroupResourceCountCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + public string? Filter { get; set; } + + [Parameter(Mandatory = false)] + public string? Search { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + int? result; + try + { + result = client.IdentityGovernance.PrivilegedAccess.Group.Resources.Count.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Filter))) + requestConfiguration.QueryParameters.Filter = Filter; + + if (this.IsParameterBound(nameof(Search))) + requestConfiguration.QueryParameters.Search = Search; + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResource_Get.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResource_Get.g.cs new file mode 100644 index 00000000000..03fdcc6d473 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResource_Get.g.cs @@ -0,0 +1,65 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.Governance.Client; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.Governance +{ + [GraphRoute("GET", "/identityGovernance/privilegedAccess/group/resources/{groupResource-id}")] + [Cmdlet(VerbsCommon.Get, "MgIdentityGovernancePrivilegedAccessGroupResource_Get")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource))] + public class GetMgIdentityGovernancePrivilegedAccessGroupResource_GetCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string GroupResourceId { get; set; } = string.Empty; + + + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource? result; + try + { + result = client.IdentityGovernance.PrivilegedAccess.Group.Resources[GroupResourceId].GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GroupResourceId); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResource_List.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResource_List.g.cs new file mode 100644 index 00000000000..9670fd234ce --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/GetMgIdentityGovernancePrivilegedAccessGroupResource_List.g.cs @@ -0,0 +1,141 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.Governance.Client; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.Governance +{ + [GraphRoute("GET", "/identityGovernance/privilegedAccess/group/resources")] + [Cmdlet(VerbsCommon.Get, "MgIdentityGovernancePrivilegedAccessGroupResource_List")] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource))] + public class GetMgIdentityGovernancePrivilegedAccessGroupResource_ListCommand : GraphClientCmdlet + { + + + + + [Parameter(Mandatory = false)] + public string? Filter { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Select")] + public string[]? Property { get; set; } + + [Parameter(Mandatory = false)] + [Alias("Expand")] + public string[]? ExpandProperty { get; set; } + + [Parameter(Mandatory = false)] + [Alias("OrderBy")] + public string[]? Sort { get; set; } + + [Parameter(Mandatory = false)] + public string? Search { get; set; } + + [Parameter(Mandatory = false)] + public int Top { get; set; } + + [Parameter(Mandatory = false)] + public int Skip { get; set; } + + [Parameter(Mandatory = false)] + public SwitchParameter Count { get; set; } + + // Follows every @odata.nextLink until the collection is exhausted (a bound -Top caps + // the total). Without it only the first page returns, plus a truncation warning when + // more pages existed. + [Parameter(Mandatory = false)] + public SwitchParameter All { get; set; } + + + + protected override void ProcessRecord() + { + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResourceCollectionResponse? result; + try + { + result = client.IdentityGovernance.PrivilegedAccess.Group.Resources.GetAsync(requestConfiguration => + { + if (this.IsParameterBound(nameof(Filter))) + requestConfiguration.QueryParameters.Filter = Filter; + + if (this.IsParameterBound(nameof(Property))) + requestConfiguration.QueryParameters.Select = Property; + + if (this.IsParameterBound(nameof(ExpandProperty))) + requestConfiguration.QueryParameters.Expand = ExpandProperty; + + if (this.IsParameterBound(nameof(Sort))) + requestConfiguration.QueryParameters.Orderby = Sort; + + if (this.IsParameterBound(nameof(Search))) + requestConfiguration.QueryParameters.Search = Search; + + if (this.IsParameterBound(nameof(Top))) + requestConfiguration.QueryParameters.Top = Top; + + if (this.IsParameterBound(nameof(Skip))) + requestConfiguration.QueryParameters.Skip = Skip; + + if (Count.IsPresent) + requestConfiguration.QueryParameters.Count = true; + + + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + + // A collection response and its Value are both nullable on the kiota client; an + // empty page writes nothing rather than dereferencing null. Each page streams to + // the pipeline before the next request is issued, matching the published SDK. + if (result?.Value is { } items) + WriteObject(items, enumerateCollection: true); + + if (All.IsPresent) + { + var fetched = result?.Value?.Count ?? 0; + var nextLink = result?.OdataNextLink; + while (!string.IsNullOrEmpty(nextLink) && !Stopping && (!this.IsParameterBound(nameof(Top)) || fetched < Top)) + { + // The nextLink already carries the original query state, and a raw-URL + // builder ignores templated query parameters anyway - so the continuation + // re-applies headers only; query bindings here would be dead code. + result = client.IdentityGovernance.PrivilegedAccess.Group.Resources.WithUrl(nextLink).GetAsync(requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }, StoppingToken).GetAwaiter().GetResult(); + if (result?.Value is { } page) + { + WriteObject(page, enumerateCollection: true); + fetched += page.Count; + } + nextLink = result?.OdataNextLink; + } + } + else if (!string.IsNullOrEmpty(result?.OdataNextLink)) + { + // Deliberately stronger than the published SDK, which truncates silently; + // approved in the design spec. One line, no extra request. + WriteWarning("More results are available. Use -All to return all pages."); + } + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, null); + return; + } + } + } +} diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/InvokeMgIdentityGovernanceAccessReviewDefinitionInstanceBatchApplyCustomDataProvidedResourceDecisions.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/InvokeMgIdentityGovernanceAccessReviewDefinitionInstanceBatchApplyCustomDataProvidedResourceDecisions.g.cs new file mode 100644 index 00000000000..17aa708fe33 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/InvokeMgIdentityGovernanceAccessReviewDefinitionInstanceBatchApplyCustomDataProvidedResourceDecisions.g.cs @@ -0,0 +1,77 @@ +#nullable enable + +using System; +using System.Collections.Generic; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.Governance.Client; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.Governance +{ + [GraphRoute("POST", "/identityGovernance/accessReviews/definitions/{accessReviewScheduleDefinition-id}/instances/{accessReviewInstance-id}/batchApplyCustomDataProvidedResourceDecisions")] + [Cmdlet(VerbsLifecycle.Invoke, "MgIdentityGovernanceAccessReviewDefinitionInstanceBatchApplyCustomDataProvidedResourceDecisions", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + + public class InvokeMgIdentityGovernanceAccessReviewDefinitionInstanceBatchApplyCustomDataProvidedResourceDecisionsCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string AccessReviewScheduleDefinitionId { get; set; } = string.Empty; + [Parameter(Mandatory = true, Position = 1)] + public string AccessReviewInstanceId { get; set; } = string.Empty; + + [Parameter(Mandatory = false)] + public string? ApplyDescription { get; set; } + + [Parameter(Mandatory = false)] + public string? CustomDataProvidedResourceId { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemApplyResult? ApplyResult { get; set; } + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(AccessReviewInstanceId, "Invoke")) + return; + + var body = new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody(); + + if (this.IsParameterBound(nameof(ApplyDescription))) + body.ApplyDescription = ApplyDescription; + + if (this.IsParameterBound(nameof(CustomDataProvidedResourceId))) + body.CustomDataProvidedResourceId = CustomDataProvidedResourceId; + if (this.IsParameterBound(nameof(ApplyResult))) + body.ApplyResult = ApplyResult; + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + + try + { + client.IdentityGovernance.AccessReviews.Definitions[AccessReviewScheduleDefinitionId].Instances[AccessReviewInstanceId].BatchApplyCustomDataProvidedResourceDecisions.PostAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }) + .GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, AccessReviewInstanceId); + return; + } + + } + } +} diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/InvokeMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceBatchApplyCustomDataProvidedResourceDecisions.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/InvokeMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceBatchApplyCustomDataProvidedResourceDecisions.g.cs new file mode 100644 index 00000000000..529b8a83d52 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/InvokeMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceBatchApplyCustomDataProvidedResourceDecisions.g.cs @@ -0,0 +1,77 @@ +#nullable enable + +using System; +using System.Collections.Generic; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.Governance.Client; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.Governance +{ + [GraphRoute("POST", "/identityGovernance/accessReviews/unified/definitions/{accessReviewScheduleDefinition-id}/instances/{accessReviewInstance-id}/batchApplyCustomDataProvidedResourceDecisions")] + [Cmdlet(VerbsLifecycle.Invoke, "MgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceBatchApplyCustomDataProvidedResourceDecisions", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + + public class InvokeMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceBatchApplyCustomDataProvidedResourceDecisionsCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string AccessReviewScheduleDefinitionId { get; set; } = string.Empty; + [Parameter(Mandatory = true, Position = 1)] + public string AccessReviewInstanceId { get; set; } = string.Empty; + + [Parameter(Mandatory = false)] + public string? ApplyDescription { get; set; } + + [Parameter(Mandatory = false)] + public string? CustomDataProvidedResourceId { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemApplyResult? ApplyResult { get; set; } + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(AccessReviewInstanceId, "Invoke")) + return; + + var body = new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Definitions.Item.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody(); + + if (this.IsParameterBound(nameof(ApplyDescription))) + body.ApplyDescription = ApplyDescription; + + if (this.IsParameterBound(nameof(CustomDataProvidedResourceId))) + body.CustomDataProvidedResourceId = CustomDataProvidedResourceId; + if (this.IsParameterBound(nameof(ApplyResult))) + body.ApplyResult = ApplyResult; + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + + try + { + client.IdentityGovernance.AccessReviews.Unified.Definitions[AccessReviewScheduleDefinitionId].Instances[AccessReviewInstanceId].BatchApplyCustomDataProvidedResourceDecisions.PostAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }) + .GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, AccessReviewInstanceId); + return; + } + + } + } +} diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/InvokeMgIdentityGovernanceAccessReviewUnifiedInstanceBatchApplyCustomDataProvidedResourceDecisions.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/InvokeMgIdentityGovernanceAccessReviewUnifiedInstanceBatchApplyCustomDataProvidedResourceDecisions.g.cs new file mode 100644 index 00000000000..29558796b53 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/InvokeMgIdentityGovernanceAccessReviewUnifiedInstanceBatchApplyCustomDataProvidedResourceDecisions.g.cs @@ -0,0 +1,75 @@ +#nullable enable + +using System; +using System.Collections.Generic; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.Governance.Client; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; +using Microsoft.Kiota.Abstractions; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.Governance +{ + [GraphRoute("POST", "/identityGovernance/accessReviews/unified/instances/{accessReviewInstance-id}/batchApplyCustomDataProvidedResourceDecisions")] + [Cmdlet(VerbsLifecycle.Invoke, "MgIdentityGovernanceAccessReviewUnifiedInstanceBatchApplyCustomDataProvidedResourceDecisions", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + + public class InvokeMgIdentityGovernanceAccessReviewUnifiedInstanceBatchApplyCustomDataProvidedResourceDecisionsCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string AccessReviewInstanceId { get; set; } = string.Empty; + + [Parameter(Mandatory = false)] + public string? ApplyDescription { get; set; } + + [Parameter(Mandatory = false)] + public string? CustomDataProvidedResourceId { get; set; } + + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemApplyResult? ApplyResult { get; set; } + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(AccessReviewInstanceId, "Invoke")) + return; + + var body = new global::Microsoft.Graph.PowerShell.Identity.Governance.Client.IdentityGovernance.AccessReviews.Unified.Instances.Item.BatchApplyCustomDataProvidedResourceDecisions.BatchApplyCustomDataProvidedResourceDecisionsPostRequestBody(); + + if (this.IsParameterBound(nameof(ApplyDescription))) + body.ApplyDescription = ApplyDescription; + + if (this.IsParameterBound(nameof(CustomDataProvidedResourceId))) + body.CustomDataProvidedResourceId = CustomDataProvidedResourceId; + if (this.IsParameterBound(nameof(ApplyResult))) + body.ApplyResult = ApplyResult; + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + + try + { + client.IdentityGovernance.AccessReviews.Unified.Instances[AccessReviewInstanceId].BatchApplyCustomDataProvidedResourceDecisions.PostAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }) + .GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, AccessReviewInstanceId); + return; + } + + } + } +} diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgEntitlementManagementAssignmentRequest.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgEntitlementManagementAssignmentRequest.g.cs index 051b4d8364b..bcebdc25878 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgEntitlementManagementAssignmentRequest.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgEntitlementManagementAssignmentRequest.g.cs @@ -37,6 +37,9 @@ public class NewMgEntitlementManagementAssignmentRequestCommand : GraphClientCmd [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.CustomExtensionCalloutInstance[]? CustomExtensionCalloutInstances { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessPackageAssignmentRequestParameters? Parameters { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessPackageRequestType? RequestType { get; set; } @@ -76,6 +79,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(CustomExtensionCalloutInstances))) body.CustomExtensionCalloutInstances = CustomExtensionCalloutInstances!.ToList(); + if (this.IsParameterBound(nameof(Parameters))) + body.Parameters = Parameters; + if (this.IsParameterBound(nameof(RequestType))) body.RequestType = RequestType; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewDefinitionInstanceDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewDefinitionInstanceDecision.g.cs index 44f669f983e..82ba6c9f35c 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewDefinitionInstanceDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewDefinitionInstanceDecision.g.cs @@ -55,6 +55,9 @@ public class NewMgIdentityGovernanceAccessReviewDefinitionInstanceDecisionComman [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -109,6 +112,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewDefinitionInstanceStageDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewDefinitionInstanceStageDecision.g.cs index 1ad757529c1..9f28b5fdc81 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewDefinitionInstanceStageDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewDefinitionInstanceStageDecision.g.cs @@ -57,6 +57,9 @@ public class NewMgIdentityGovernanceAccessReviewDefinitionInstanceStageDecisionC [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -111,6 +114,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedDecision.g.cs index 0183dad48ed..d805758e808 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedDecision.g.cs @@ -52,6 +52,9 @@ public class NewMgIdentityGovernanceAccessReviewUnifiedDecisionCommand : GraphCl [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -106,6 +109,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceDecision.g.cs index ae2ae185f44..5277f8ac378 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceDecision.g.cs @@ -55,6 +55,9 @@ public class NewMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceDecisio [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -109,6 +112,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceStageDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceStageDecision.g.cs index ae7555751ea..6306342850c 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceStageDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceStageDecision.g.cs @@ -57,6 +57,9 @@ public class NewMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceStageDe [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -111,6 +114,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedInstanceDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedInstanceDecision.g.cs index 75c79df9460..cc526d4fcd6 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedInstanceDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedInstanceDecision.g.cs @@ -53,6 +53,9 @@ public class NewMgIdentityGovernanceAccessReviewUnifiedInstanceDecisionCommand : [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -107,6 +110,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedInstanceStageDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedInstanceStageDecision.g.cs index 626a3b0df4a..5e0f6022546 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedInstanceStageDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernanceAccessReviewUnifiedInstanceStageDecision.g.cs @@ -55,6 +55,9 @@ public class NewMgIdentityGovernanceAccessReviewUnifiedInstanceStageDecisionComm [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -109,6 +112,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernancePrivilegedAccessGroupResource.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernancePrivilegedAccessGroupResource.g.cs new file mode 100644 index 00000000000..d5aab8c6d76 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/NewMgIdentityGovernancePrivilegedAccessGroupResource.g.cs @@ -0,0 +1,64 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.Governance.Client; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.Governance +{ + [GraphRoute("POST", "/identityGovernance/privilegedAccess/group/resources")] + [Cmdlet(VerbsCommon.New, "MgIdentityGovernancePrivilegedAccessGroupResource", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource))] + public class NewMgIdentityGovernancePrivilegedAccessGroupResourceCommand : GraphClientCmdlet + { + + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? DeletedDateTime { get; set; } + + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(null, "New")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource(); + + if (this.IsParameterBound(nameof(DeletedDateTime))) + body.DeletedDateTime = DeletedDateTime; + + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource? result; + try + { + result = client.IdentityGovernance.PrivilegedAccess.Group.Resources.PostAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, body); + return; + } + + WriteObject(result); + } + } +} diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/RemoveMgIdentityGovernancePrivilegedAccessGroupResource.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/RemoveMgIdentityGovernancePrivilegedAccessGroupResource.g.cs new file mode 100644 index 00000000000..56addf274ab --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/RemoveMgIdentityGovernancePrivilegedAccessGroupResource.g.cs @@ -0,0 +1,56 @@ +#nullable enable + +using System; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.Governance.Client; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.Governance +{ + [GraphRoute("DELETE", "/identityGovernance/privilegedAccess/group/resources/{groupResource-id}")] + [Cmdlet(VerbsCommon.Remove, "MgIdentityGovernancePrivilegedAccessGroupResource", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.High)] + public class RemoveMgIdentityGovernancePrivilegedAccessGroupResourceCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string GroupResourceId { get; set; } = string.Empty; + + + [Parameter(Mandatory = false, + HelpMessage = "Sets the 'If-Match' request header (for example an ETag for optimistic concurrency; some Graph APIs require it even where the spec marks it optional).")] + public string? IfMatch { get; set; } + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(GroupResourceId, "Remove")) + return; + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + // DeleteAsync returns a plain Task: a standard delete response has no body. + try + { + client.IdentityGovernance.PrivilegedAccess.Group.Resources[GroupResourceId].DeleteAsync(requestConfiguration => + { + + if (this.IsParameterBound(nameof(IfMatch))) + requestConfiguration.Headers.Add("If-Match", IfMatch!); + + AddRequestHeaders(requestConfiguration.Headers); + }) + .GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GroupResourceId); + return; + } + } + } +} diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewDefinitionInstanceDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewDefinitionInstanceDecision.g.cs index ed6b171133d..262109bf4ce 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewDefinitionInstanceDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewDefinitionInstanceDecision.g.cs @@ -57,6 +57,9 @@ public class UpdateMgIdentityGovernanceAccessReviewDefinitionInstanceDecisionCom [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -111,6 +114,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewDefinitionInstanceStageDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewDefinitionInstanceStageDecision.g.cs index 58012910365..ec083d8f2dd 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewDefinitionInstanceStageDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewDefinitionInstanceStageDecision.g.cs @@ -59,6 +59,9 @@ public class UpdateMgIdentityGovernanceAccessReviewDefinitionInstanceStageDecisi [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -113,6 +116,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedDecision.g.cs index 892992d917b..c30efafe898 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedDecision.g.cs @@ -53,6 +53,9 @@ public class UpdateMgIdentityGovernanceAccessReviewUnifiedDecisionCommand : Grap [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -107,6 +110,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceDecision.g.cs index 31354738793..d4cc64b793c 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceDecision.g.cs @@ -57,6 +57,9 @@ public class UpdateMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceDeci [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -111,6 +114,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceStageDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceStageDecision.g.cs index 47471ddc90a..081d536ccea 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceStageDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceStageDecision.g.cs @@ -59,6 +59,9 @@ public class UpdateMgIdentityGovernanceAccessReviewUnifiedDefinitionInstanceStag [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -113,6 +116,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedInstanceDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedInstanceDecision.g.cs index 842198f5e39..d5f54d7b9ac 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedInstanceDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedInstanceDecision.g.cs @@ -55,6 +55,9 @@ public class UpdateMgIdentityGovernanceAccessReviewUnifiedInstanceDecisionComman [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -109,6 +112,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedInstanceStageDecision.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedInstanceStageDecision.g.cs index 5551db1c24d..558e951c342 100644 --- a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedInstanceStageDecision.g.cs +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernanceAccessReviewUnifiedInstanceStageDecision.g.cs @@ -57,6 +57,9 @@ public class UpdateMgIdentityGovernanceAccessReviewUnifiedInstanceStageDecisionC [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.UserIdentity? AppliedBy { get; set; } + [Parameter(Mandatory = false)] + public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.AccessReviewInstanceDecisionItemPermission? Permission { get; set; } + [Parameter(Mandatory = false)] public Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.Identity? Principal { get; set; } @@ -111,6 +114,9 @@ protected override void ProcessRecord() if (this.IsParameterBound(nameof(AppliedBy))) body.AppliedBy = AppliedBy; + if (this.IsParameterBound(nameof(Permission))) + body.Permission = Permission; + if (this.IsParameterBound(nameof(Principal))) body.Principal = Principal; diff --git a/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernancePrivilegedAccessGroupResource.g.cs b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernancePrivilegedAccessGroupResource.g.cs new file mode 100644 index 00000000000..a22998a7b27 --- /dev/null +++ b/src/Identity.Governance/wrapper/v1.0/Cmdlets/UpdateMgIdentityGovernancePrivilegedAccessGroupResource.g.cs @@ -0,0 +1,80 @@ +#nullable enable + +using System; +using System.Linq; +using System.Management.Automation; +using System.Net.Http; +using Microsoft.Graph.Wrapper.Runtime; +using Microsoft.Graph.PowerShell.Identity.Governance.Client; +using Microsoft.Graph.PowerShell.Identity.Governance.Client.Models; +using Microsoft.Kiota.Abstractions.Authentication; +using Microsoft.Kiota.Http.HttpClientLibrary; + +namespace Microsoft.Graph.PowerShell.Identity.Governance +{ + [GraphRoute("PATCH", "/identityGovernance/privilegedAccess/group/resources/{groupResource-id}")] + [Cmdlet(VerbsData.Update, "MgIdentityGovernancePrivilegedAccessGroupResource", SupportsShouldProcess = true, ConfirmImpact = ConfirmImpact.Medium)] + [OutputType(typeof(Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource))] + public class UpdateMgIdentityGovernancePrivilegedAccessGroupResourceCommand : GraphClientCmdlet + { + [Parameter(Mandatory = true, Position = 0)] + public string GroupResourceId { get; set; } = string.Empty; + + [Parameter(Mandatory = false)] + public global::System.DateTimeOffset? DeletedDateTime { get; set; } + + + + + + + + protected override void ProcessRecord() + { + if (!ShouldProcess(GroupResourceId, "Update")) + return; + + var body = new Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource(); + + if (this.IsParameterBound(nameof(DeletedDateTime))) + body.DeletedDateTime = DeletedDateTime; + + + + var requestAdapter = GetRequestAdapter(); + var client = new ApiClient(requestAdapter); + + Microsoft.Graph.PowerShell.Identity.Governance.Client.Models.GroupResource? result; + try + { + result = client.IdentityGovernance.PrivilegedAccess.Group.Resources[GroupResourceId].PatchAsync(body, requestConfiguration => + { + + AddRequestHeaders(requestConfiguration.Headers); + }).GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GroupResourceId); + return; + } + + + if (result is null) + { + WriteVerbose("PATCH succeeded with no response body, re-fetching the updated resource."); + try + { + result = client.IdentityGovernance.PrivilegedAccess.Group.Resources[GroupResourceId].GetAsync().GetAwaiter().GetResult(); + } + catch (Exception ex) when (ex is not PipelineStoppedException && ex is not OperationCanceledException) + { + ThrowGraphRequestFailed(ex, GroupResourceId); + return; + } + } + if (result is not null) + WriteObject(result); + } + } +} diff --git a/src/Identity.Partner/wrapper/v1.0/Client/kiota-lock.json b/src/Identity.Partner/wrapper/v1.0/Client/kiota-lock.json index ad4f7eeeafb..5391b6772fe 100644 --- a/src/Identity.Partner/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Identity.Partner/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "2741CFE20908CD46E4E506711C94FC534CB8D46B93907A0F45D2572647F79287227EDB1D13DE0D42050088C11369F40D2C43BE5E930CC07A92A1EA7BD46A544A", + "descriptionHash": "08DD4C8E84242255040F71494EE7372D5786D6B6CAE4673BB038C047A8358F7614DED99030AC05BBA77D34E2E3C6B6AB32BFBA613F38E75E513DB51D061E1210", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Identity.Partner.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Identity.Partner.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Identity.SignIns/wrapper/v1.0/Client/Models/Entity.cs b/src/Identity.SignIns/wrapper/v1.0/Client/Models/Entity.cs index 241eca239a5..f3f9a57ac79 100644 --- a/src/Identity.SignIns/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Identity.SignIns/wrapper/v1.0/Client/Models/Entity.cs @@ -187,6 +187,7 @@ public Entity() "#microsoft.graph.multiTenantOrganizationMember" => new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.MultiTenantOrganizationMember(), "#microsoft.graph.multiTenantOrganizationPartnerConfigurationTemplate" => new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.MultiTenantOrganizationPartnerConfigurationTemplate(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.OfferShiftRequest(), diff --git a/src/Identity.SignIns/wrapper/v1.0/Client/Models/Group.cs b/src/Identity.SignIns/wrapper/v1.0/Client/Models/Group.cs index 0d66e271170..702e08b67e9 100644 --- a/src/Identity.SignIns/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Identity.SignIns/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Identity.SignIns #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Identity.SignIns/wrapper/v1.0/Client/Models/Note.cs b/src/Identity.SignIns/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..0dfc498d344 --- /dev/null +++ b/src/Identity.SignIns/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Identity.SignIns/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Identity.SignIns/wrapper/v1.0/Client/Models/OutlookItem.cs index 2bce449d7de..6de98e78b86 100644 --- a/src/Identity.SignIns/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Identity.SignIns/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Identity.S "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.OutlookItem(), }; diff --git a/src/Identity.SignIns/wrapper/v1.0/Client/Models/User.cs b/src/Identity.SignIns/wrapper/v1.0/Client/Models/User.cs index 9c63bfe8c0f..f9e52a4fd96 100644 --- a/src/Identity.SignIns/wrapper/v1.0/Client/Models/User.cs +++ b/src/Identity.SignIns/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Identity.SignIns. #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Identity.SignIns.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Identity.SignIns/wrapper/v1.0/Client/kiota-lock.json b/src/Identity.SignIns/wrapper/v1.0/Client/kiota-lock.json index c5699597c86..858cd0f2f7e 100644 --- a/src/Identity.SignIns/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Identity.SignIns/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "E55DF812E11B376B7BDBD700131553EB89C8AFA50149B1122EAF9F4765598A4879B2141112784F95A099162276FBA6AACB899CF63369870396D9389D1E4CFFE2", + "descriptionHash": "57AE4BD68C8D011269808EF99B3C51A24FF6492C40F987BD291DB6A9359D3B0B70BA3D176BE4D6B9ADDF846958FF50F4311FC046A33F7630A6A4F95DB3E8E122", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Identity.SignIns.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Identity.SignIns.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Mail/wrapper/v1.0/Client/kiota-lock.json b/src/Mail/wrapper/v1.0/Client/kiota-lock.json index aa6cc3c9be6..54ad888b10f 100644 --- a/src/Mail/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Mail/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "C90901737FF749F830557B96048D12918F50DCCA41E31DBDC9C5344EAF3621E14CA1001772E49BCA76F8245EA897CADA026C8CD7683DAEFCD6F3B61C3042BDF8", + "descriptionHash": "D4B08426AF43673A48EA6D5428FBC45463742F5D6417086394091D7FF8DB79CD61941F322787F6CA926994D944BEEB3416A35866C10ED2DC58AAB99C049E57D1", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Mail.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Mail.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Notes/wrapper/v1.0/Client/kiota-lock.json b/src/Notes/wrapper/v1.0/Client/kiota-lock.json index c712fa79c1f..fc99bf8f320 100644 --- a/src/Notes/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Notes/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "AC290AFB0DC87490424F09FD3C13761E8DB20BA19FD534E706587DD93045814D78648F31B1BDE8D606BAD6179FB3EDEDB74ECD2E4EB83A9B0F8564E743347B72", + "descriptionHash": "F37AFC9F4EF90B69A415949AB7145E7CA1FA4294A25719AB5B1079C72DD2709F286EC2EB84D51C9D91FC9556D96C66EF54F4BB38AEBAA64117D7DD06EEC1EF89", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Notes.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Notes.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/People/wrapper/v1.0/Client/kiota-lock.json b/src/People/wrapper/v1.0/Client/kiota-lock.json index 058fc1896ca..3c15497320b 100644 --- a/src/People/wrapper/v1.0/Client/kiota-lock.json +++ b/src/People/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "8B5487C1102A5E3CE36527EC1113A6099498F7402A45CB6C5CB042D5E98976FD4AC5C5828A2D92B95F7A7BB78E6E404810C1C7B5E632B9F3DFA0274F2D59BF04", + "descriptionHash": "4891F581EA17CD157E83896DAA364A0B8BC10D7D1410E35DF65CA2629BAECC5FD6FE8CDE0BDF19E397571365194693EFC913C78AC4716D74175F60BA365531CE", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/People.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.People.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/PersonalContacts/wrapper/v1.0/Client/kiota-lock.json b/src/PersonalContacts/wrapper/v1.0/Client/kiota-lock.json index b4d4028e014..6dd1ad40e06 100644 --- a/src/PersonalContacts/wrapper/v1.0/Client/kiota-lock.json +++ b/src/PersonalContacts/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "C970823594F0918AEA4919215ACB23F94C78B6DAE8A9974D9C325668699CD374A44B189895301B540A3320884A947DA6E41DCED499B8C839AE73305B67EFF475", + "descriptionHash": "4E239777A68FF59309812B833A481D7FD09D3E3A5D092ACAE511E2BB76EA012DD308B710B7B0C771CE923E0ED4A8C9AD6D3C2514DD850ECFE4CA32D7B73FBF8C", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/PersonalContacts.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.PersonalContacts.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Planner/wrapper/v1.0/Client/kiota-lock.json b/src/Planner/wrapper/v1.0/Client/kiota-lock.json index 7973eb0d8c4..41a6ebe35ef 100644 --- a/src/Planner/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Planner/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "ADE0F5305AFDB45C1974E4D9030EA7304EF95B0931D533E84685CBD9C1E1C976DBDF71BE2CF47177FE8155C1A6A0FFC8E692271F2B8AFE44FF9B1452D061D629", + "descriptionHash": "43B2D3350DAFD4D6AEB2CAAE3ECFD4DD16C609B1FBB20336DEAC9225AB195BC1CF1E6B333EC8D9BAC34089BC778EBD260749C08BF85471660385FCCA21587DEC", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Planner.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Planner.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Reports/wrapper/v1.0/Client/kiota-lock.json b/src/Reports/wrapper/v1.0/Client/kiota-lock.json index 42bbf6cf41f..63364f4d401 100644 --- a/src/Reports/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Reports/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "1D3D7EB442868A72602CDDD99700926C5C343D5C113EF02A4DA0615810CA1A80C103ABB8AB7460263F76BC4D8439717B31A8CAB0E337666A9CAA825297F2A1FE", + "descriptionHash": "8DCF74D4A8B585268FDC2A62513B7C50D7381F51365F1C81C6FD8065EB3991AEA78AF3507D71D49BB66E466712066C1F143E9D77CC6EE8E6ADDB4FABA3F2E8A8", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Reports.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Reports.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/SchemaExtensions/wrapper/v1.0/Client/kiota-lock.json b/src/SchemaExtensions/wrapper/v1.0/Client/kiota-lock.json index 42e2d148e39..66df49156c5 100644 --- a/src/SchemaExtensions/wrapper/v1.0/Client/kiota-lock.json +++ b/src/SchemaExtensions/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "3C319ABC0937CF7FE5E4D70D495EDCF26BD6155AC30751907C262640D985E1C4F481039C2958A2280150A1979FE73D132848D87F0361EA878D79086D0EC9D7BB", + "descriptionHash": "E887BB529A35737571FA513D17B77DD9A580771A674B78281AE24633BBD8EFA2E7EFADD76ABEF51DCF9C0FF8F631DA6CBAC766BB0D6CA439433BE37D876730FD", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/SchemaExtensions.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.SchemaExtensions.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Search/wrapper/v1.0/Client/kiota-lock.json b/src/Search/wrapper/v1.0/Client/kiota-lock.json index f642a4a6093..764ec2ca2b9 100644 --- a/src/Search/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Search/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "6DA77DFCEE7A7863F9EA6E6D246E56D5EA4F4CF56C815916734B115F0A6384A2247ADDE695299F2E2AA2B5949922F500A71EA61142432054E3951EC8D8BBA05A", + "descriptionHash": "571517862B3C3CEB35A865218B1D6CAEC55E01481631619538E5F9ED00B8E51B7F51312CE23ECC158EDDC3342AE8F7C2620071D7D3A93A74C69385414297831C", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Search.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Search.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Security/wrapper/v1.0/Client/Models/DlpAction.cs b/src/Security/wrapper/v1.0/Client/Models/DlpAction.cs index 5ad0f77484c..359ac75fec0 100644 --- a/src/Security/wrapper/v1.0/Client/Models/DlpAction.cs +++ b/src/Security/wrapper/v1.0/Client/Models/DlpAction.cs @@ -60,5 +60,9 @@ public enum DlpAction #pragma warning disable CS1591 RestrictWebGrounding, #pragma warning restore CS1591 + [EnumMember(Value = "policyTip")] + #pragma warning disable CS1591 + PolicyTip, + #pragma warning restore CS1591 } } diff --git a/src/Security/wrapper/v1.0/Client/Models/Entity.cs b/src/Security/wrapper/v1.0/Client/Models/Entity.cs index fcccf12d9aa..bacb36c1638 100644 --- a/src/Security/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Security/wrapper/v1.0/Client/Models/Entity.cs @@ -149,6 +149,7 @@ public Entity() "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Security.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Security.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Security.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Security.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Security.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Security.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Security.Client.Models.OfferShiftRequest(), diff --git a/src/Security/wrapper/v1.0/Client/Models/Group.cs b/src/Security/wrapper/v1.0/Client/Models/Group.cs index ac11c09c1f0..9a8bda7e54f 100644 --- a/src/Security/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Security/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Security.Client. #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Security.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Security/wrapper/v1.0/Client/Models/Note.cs b/src/Security/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..49708f9130b --- /dev/null +++ b/src/Security/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Security.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Security.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Security.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Security.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Security.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Security.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Security.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Security.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Security.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Security.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Security.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Security/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Security/wrapper/v1.0/Client/Models/OutlookItem.cs index 81079b0bf8b..541ca58dcbe 100644 --- a/src/Security/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Security/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Security.C "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Security.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Security.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Security.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Security.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Security.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Security.Client.Models.OutlookItem(), }; diff --git a/src/Security/wrapper/v1.0/Client/Models/Security/Alert.cs b/src/Security/wrapper/v1.0/Client/Models/Security/Alert.cs index 8b9f0c029cf..b41f7436d70 100644 --- a/src/Security/wrapper/v1.0/Client/Models/Security/Alert.cs +++ b/src/Security/wrapper/v1.0/Client/Models/Security/Alert.cs @@ -106,7 +106,7 @@ public partial class Alert : global::Microsoft.Graph.PowerShell.Security.Client. #else public string DetectorId { get; set; } #endif - /// Specifies the result of the investigation, whether the alert represents a true attack and if so, the nature of the attack. The possible values are: unknown, apt, malware, securityPersonnel, securityTesting, unwantedSoftware, other, multiStagedAttack, compromisedAccount, phishing, maliciousUserActivity, notMalicious, notEnoughDataToValidate, confirmedUserActivity, lineOfBusinessApplication, unknownFutureValue. + /// Specifies the result of the investigation, whether the alert represents a true attack and if so, the nature of the attack. The possible values are: unknown, apt, malware, securityPersonnel, securityTesting, unwantedSoftware, other, multiStagedAttack, compromisedAccount, phishing, maliciousUserActivity, notMalicious, notEnoughDataToValidate, confirmedActivity, lineOfBusinessApplication, unknownFutureValue. public global::Microsoft.Graph.PowerShell.Security.Client.Models.Security.AlertDetermination? Determination { get; set; } /// Collection of evidence related to the alert. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER diff --git a/src/Security/wrapper/v1.0/Client/Models/Security/Incident.cs b/src/Security/wrapper/v1.0/Client/Models/Security/Incident.cs index fe1aaa3102d..9ab51d95f46 100644 --- a/src/Security/wrapper/v1.0/Client/Models/Security/Incident.cs +++ b/src/Security/wrapper/v1.0/Client/Models/Security/Incident.cs @@ -56,7 +56,7 @@ public partial class Incident : global::Microsoft.Graph.PowerShell.Security.Clie #else public string Description { get; set; } #endif - /// Specifies the determination of the incident. The possible values are: unknown, apt, malware, securityPersonnel, securityTesting, unwantedSoftware, other, multiStagedAttack, compromisedUser, phishing, maliciousUserActivity, clean, insufficientData, confirmedUserActivity, lineOfBusinessApplication, unknownFutureValue. + /// Specifies the determination of the incident. The possible values are: unknown, apt, malware, securityPersonnel, securityTesting, unwantedSoftware, other, multiStagedAttack, compromisedUser, phishing, maliciousUserActivity, clean, insufficientData, confirmedActivity, lineOfBusinessApplication, unknownFutureValue. public global::Microsoft.Graph.PowerShell.Security.Client.Models.Security.AlertDetermination? Determination { get; set; } /// The incident name. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER diff --git a/src/Security/wrapper/v1.0/Client/Models/Security/Security.cs b/src/Security/wrapper/v1.0/Client/Models/Security/Security.cs index b3eb5758b60..956aafde6bf 100644 --- a/src/Security/wrapper/v1.0/Client/Models/Security/Security.cs +++ b/src/Security/wrapper/v1.0/Client/Models/Security/Security.cs @@ -7,11 +7,10 @@ using System; namespace Microsoft.Graph.PowerShell.Security.Client.Models.Security { - /// - /// Security singleton providing access to audit log resources. - /// [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 public partial class Security : global::Microsoft.Graph.PowerShell.Security.Client.Models.Entity, IParsable + #pragma warning restore CS1591 { /// The alerts property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER diff --git a/src/Security/wrapper/v1.0/Client/Models/User.cs b/src/Security/wrapper/v1.0/Client/Models/User.cs index 9668995db69..43c3c540dd5 100644 --- a/src/Security/wrapper/v1.0/Client/Models/User.cs +++ b/src/Security/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Security.Client.M #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Security.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Security.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Security.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Security/wrapper/v1.0/Client/kiota-lock.json b/src/Security/wrapper/v1.0/Client/kiota-lock.json index 552bf31b914..f3383494104 100644 --- a/src/Security/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Security/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "E55F6CAACE438E5C8B6CA0131A47FC9C7FE0B28485FCB187A3605DC8D0A7550D5DFEA5B4C8251F84754B7846E109B05904F5A8513AC79041D290C7C3298E592B", + "descriptionHash": "084D9669A38D801D9E624AB2BEAB9DF53B8D85304DE492710DAE52FACB1AC11D424121C99715345365CB9A22A92B4B2EB07FCDDBEF076E23B98C65C244272346", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Security.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Security.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Sites/wrapper/v1.0/Client/Models/Entity.cs b/src/Sites/wrapper/v1.0/Client/Models/Entity.cs index 16ee31890f7..ea7c0cff299 100644 --- a/src/Sites/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Sites/wrapper/v1.0/Client/Models/Entity.cs @@ -141,6 +141,7 @@ public Entity() "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Sites.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Sites.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Sites.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Sites.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Sites.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Sites.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Sites.Client.Models.OfferShiftRequest(), diff --git a/src/Sites/wrapper/v1.0/Client/Models/Group.cs b/src/Sites/wrapper/v1.0/Client/Models/Group.cs index c96d5895fef..519bdef3a01 100644 --- a/src/Sites/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Sites/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Sites.Client.Mod #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Sites.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Sites/wrapper/v1.0/Client/Models/Note.cs b/src/Sites/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..6e3f498c036 --- /dev/null +++ b/src/Sites/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Sites.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Sites.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Sites.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Sites.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Sites.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Sites.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Sites.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Sites.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Sites.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Sites.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Sites.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Sites/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Sites/wrapper/v1.0/Client/Models/OutlookItem.cs index 353a2ebea3b..5e665e4f687 100644 --- a/src/Sites/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Sites/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Sites.Clie "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Sites.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Sites.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Sites.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Sites.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Sites.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Sites.Client.Models.OutlookItem(), }; diff --git a/src/Sites/wrapper/v1.0/Client/Models/User.cs b/src/Sites/wrapper/v1.0/Client/Models/User.cs index ff525a7dc51..d1a4ff8de6a 100644 --- a/src/Sites/wrapper/v1.0/Client/Models/User.cs +++ b/src/Sites/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Sites.Client.Mode #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Sites.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Sites.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Sites.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Sites/wrapper/v1.0/Client/kiota-lock.json b/src/Sites/wrapper/v1.0/Client/kiota-lock.json index de255bb3655..434ca5ae4f4 100644 --- a/src/Sites/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Sites/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "C79BEBD67F092157D785508C60558136A53D4ACE105F8E5A164136D7CDB6204D81D49876E9A07FA77A68D634B7784E93AC6522F1B09A9168A51AD852080F5E75", + "descriptionHash": "1223F4530082062CD705D9A6430ACFF8894B023D3053C4F9B73EE69C585A4E90F08CFD347C7F8169201ABA4A163854D4FE1031ABFE6293E96AEE459998B3CD4A", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Sites.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Sites.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Teams/wrapper/v1.0/Client/Models/Entity.cs b/src/Teams/wrapper/v1.0/Client/Models/Entity.cs index 0ec611bbb8f..55cbe5d7671 100644 --- a/src/Teams/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Teams/wrapper/v1.0/Client/Models/Entity.cs @@ -140,6 +140,7 @@ public Entity() "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Teams.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Teams.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Teams.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Teams.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Teams.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Teams.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Teams.Client.Models.OfferShiftRequest(), diff --git a/src/Teams/wrapper/v1.0/Client/Models/Group.cs b/src/Teams/wrapper/v1.0/Client/Models/Group.cs index 9babe98483b..9d4a2674847 100644 --- a/src/Teams/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Teams/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Teams.Client.Mod #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Teams.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Teams/wrapper/v1.0/Client/Models/Note.cs b/src/Teams/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..28c4c9402b4 --- /dev/null +++ b/src/Teams/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Teams.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Teams.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Teams.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Teams.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Teams.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Teams.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Teams.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Teams.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Teams.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Teams.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Teams.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Teams/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Teams/wrapper/v1.0/Client/Models/OutlookItem.cs index 9ff010a13de..41e9bed74a3 100644 --- a/src/Teams/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Teams/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Teams.Clie "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Teams.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Teams.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Teams.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Teams.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Teams.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Teams.Client.Models.OutlookItem(), }; diff --git a/src/Teams/wrapper/v1.0/Client/Models/User.cs b/src/Teams/wrapper/v1.0/Client/Models/User.cs index a899c52a6c2..407a156346d 100644 --- a/src/Teams/wrapper/v1.0/Client/Models/User.cs +++ b/src/Teams/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Teams.Client.Mode #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Teams.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Teams.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Teams.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Teams/wrapper/v1.0/Client/kiota-lock.json b/src/Teams/wrapper/v1.0/Client/kiota-lock.json index 745f1231aad..160eba70731 100644 --- a/src/Teams/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Teams/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "8E8D3413DE9012EC6804656968E6AA12FF16C4D7EE88AC2918A4E74C6F2A716289A51834E33733B272C2685C166E5ED17747580AD573A733E53F87D7E7B62FDF", + "descriptionHash": "2281B3C42ED115EF380EF9336C4DBCD81E2A3E9AC21A56F7BCAA626A0CFCAA327386172BC34DF750F272C825D089193C2055826A8C106064CD02CC3D8D1C6573", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Teams.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Teams.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Users.Actions/wrapper/v1.0/Client/Models/Entity.cs b/src/Users.Actions/wrapper/v1.0/Client/Models/Entity.cs index 460768f4b77..39b406ce2c3 100644 --- a/src/Users.Actions/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Users.Actions/wrapper/v1.0/Client/Models/Entity.cs @@ -139,6 +139,7 @@ public Entity() "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.OfferShiftRequest(), diff --git a/src/Users.Actions/wrapper/v1.0/Client/Models/Group.cs b/src/Users.Actions/wrapper/v1.0/Client/Models/Group.cs index 09281af41b4..21f4272533e 100644 --- a/src/Users.Actions/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Users.Actions/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Users.Actions.Cl #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Users.Actions/wrapper/v1.0/Client/Models/Note.cs b/src/Users.Actions/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..52814c420af --- /dev/null +++ b/src/Users.Actions/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Users.Actions.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Users.Actions/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Users.Actions/wrapper/v1.0/Client/Models/OutlookItem.cs index 390b36d41ce..fa0854f6be4 100644 --- a/src/Users.Actions/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Users.Actions/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Users.Acti "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.OutlookItem(), }; diff --git a/src/Users.Actions/wrapper/v1.0/Client/Models/User.cs b/src/Users.Actions/wrapper/v1.0/Client/Models/User.cs index ad6d9d1870e..d958d1cb59a 100644 --- a/src/Users.Actions/wrapper/v1.0/Client/Models/User.cs +++ b/src/Users.Actions/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Users.Actions.Cli #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Actions.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Users.Actions/wrapper/v1.0/Client/kiota-lock.json b/src/Users.Actions/wrapper/v1.0/Client/kiota-lock.json index 1e8d0fb28de..e338eb06326 100644 --- a/src/Users.Actions/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Users.Actions/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "11A5738D0165FB04F7AA734D45CD237033BD6AC40F76EA9D38ACBE1A185E759F4968B256C9727F8D1CCC9E7C61014A62F7AF863084E0D3B067D16E56D1A21804", + "descriptionHash": "4513C170B5C2DF2F61628CA8D7BA524D9B7CD1A931D10D742F1EE2C29F462568D21C92DFAA106EC7D46192825ED3092F3BFA3C8384A75B6D69B0EA1F00825DA9", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Users.Actions.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Users.Actions.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Users.Functions/wrapper/v1.0/Client/Models/Entity.cs b/src/Users.Functions/wrapper/v1.0/Client/Models/Entity.cs index cda440bee6e..45168bbbff5 100644 --- a/src/Users.Functions/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Users.Functions/wrapper/v1.0/Client/Models/Entity.cs @@ -138,6 +138,7 @@ public Entity() "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.OfferShiftRequest(), diff --git a/src/Users.Functions/wrapper/v1.0/Client/Models/Group.cs b/src/Users.Functions/wrapper/v1.0/Client/Models/Group.cs index 9da1f6dd447..be1da64ccdc 100644 --- a/src/Users.Functions/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Users.Functions/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Users.Functions. #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Users.Functions/wrapper/v1.0/Client/Models/Note.cs b/src/Users.Functions/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..21eea82f349 --- /dev/null +++ b/src/Users.Functions/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Users.Functions.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Users.Functions/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Users.Functions/wrapper/v1.0/Client/Models/OutlookItem.cs index 30a0ae9e2bd..3c28d88cc63 100644 --- a/src/Users.Functions/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Users.Functions/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Users.Func "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.OutlookItem(), }; diff --git a/src/Users.Functions/wrapper/v1.0/Client/Models/User.cs b/src/Users.Functions/wrapper/v1.0/Client/Models/User.cs index 6dbd04171a0..73269984eec 100644 --- a/src/Users.Functions/wrapper/v1.0/Client/Models/User.cs +++ b/src/Users.Functions/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Users.Functions.C #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Functions.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Users.Functions/wrapper/v1.0/Client/kiota-lock.json b/src/Users.Functions/wrapper/v1.0/Client/kiota-lock.json index fec95fb4874..2159b89e8a1 100644 --- a/src/Users.Functions/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Users.Functions/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "D5B1E2CA61B8FA574C013C4EF5660D5B0AF0968A5F2B194B90049CA391768E635FC26904CDB4C88713CB4F3FB3F939A4B602F8979FC8C0010848851CECE35AA4", + "descriptionHash": "E600035C70BF2D470147414D40CCCFAD76D1F64D62E80A0B7C5AC4940ADA0151B6EACC8D8B98889C9DDD9745283F051E4D53D320DE249901BE9C5418550E46CB", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Users.Functions.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Users.Functions.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file diff --git a/src/Users/wrapper/v1.0/Client/Models/Application.cs b/src/Users/wrapper/v1.0/Client/Models/Application.cs index a04ed674a59..e4a78e89c82 100644 --- a/src/Users/wrapper/v1.0/Client/Models/Application.cs +++ b/src/Users/wrapper/v1.0/Client/Models/Application.cs @@ -60,7 +60,7 @@ public partial class Application : global::Microsoft.Graph.PowerShell.Users.Clie #else public List AppRoles { get; set; } #endif - /// The authenticationBehaviors property + /// The set of breaking change behaviors related to token issuance that are configured for the application. Authentication behaviors are unset by default (null) and must be explicitly enabled or disabled. Nullable. Returned only on $select. Requires $select to retrieve. For more information about authentication behaviors, see Manage application authenticationBehaviors. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Users.Client.Models.AuthenticationBehaviors? AuthenticationBehaviors { get; set; } diff --git a/src/Users/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs b/src/Users/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs index 3718d364d79..60723df97dc 100644 --- a/src/Users/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs +++ b/src/Users/wrapper/v1.0/Client/Models/AuthenticationBehaviors.cs @@ -14,8 +14,10 @@ public partial class AuthenticationBehaviors : IAdditionalDataHolder, IParsable { /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. public IDictionary AdditionalData { get; set; } - /// The blockAzureADGraphAccess property + /// If false, allows the app to have extended access to Azure AD Graph until August 31, 2025 when Azure AD Graph is fully retired. For more information on Azure AD retirement updates, see June 2024 update on Azure AD Graph API retirement. public bool? BlockAzureADGraphAccess { get; set; } + /// Indicates whether Cross-Origin-Opener-Policy (COOP) headers are enforced on browser-based authentication responses for the application. Set to true to enable enforcement, false to temporarily suppress enforcement, or null to use the service default. For how-to guidance, see Control Cross-Origin-Opener-Policy enforcement. + public bool? CoopEnforcement { get; set; } /// The OdataType property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable @@ -24,9 +26,9 @@ public partial class AuthenticationBehaviors : IAdditionalDataHolder, IParsable #else public string OdataType { get; set; } #endif - /// The removeUnverifiedEmailClaim property + /// If true, removes the email claim from tokens sent to an application when the email address's domain can't be verified. public bool? RemoveUnverifiedEmailClaim { get; set; } - /// The requireClientServicePrincipal property + /// If true, requires multitenant applications to have a service principal in the resource tenant as part of authorization checks before they're granted access tokens. This property is only modifiable for multitenant resource applications that rely on access from clients without a service principal and had this behavior as set to false by Microsoft. Tenant administrators should respond to security advisories sent through Azure Health Service events and the Microsoft 365 message center. public bool? RequireClientServicePrincipal { get; set; } /// /// Instantiates a new and sets the default values. @@ -54,6 +56,7 @@ public virtual IDictionary> GetFieldDeserializers() return new Dictionary> { { "blockAzureADGraphAccess", n => { BlockAzureADGraphAccess = n.GetBoolValue(); } }, + { "coopEnforcement", n => { CoopEnforcement = n.GetBoolValue(); } }, { "@odata.type", n => { OdataType = n.GetStringValue(); } }, { "removeUnverifiedEmailClaim", n => { RemoveUnverifiedEmailClaim = n.GetBoolValue(); } }, { "requireClientServicePrincipal", n => { RequireClientServicePrincipal = n.GetBoolValue(); } }, @@ -67,6 +70,7 @@ public virtual void Serialize(ISerializationWriter writer) { if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); writer.WriteBoolValue("blockAzureADGraphAccess", BlockAzureADGraphAccess); + writer.WriteBoolValue("coopEnforcement", CoopEnforcement); writer.WriteStringValue("@odata.type", OdataType); writer.WriteBoolValue("removeUnverifiedEmailClaim", RemoveUnverifiedEmailClaim); writer.WriteBoolValue("requireClientServicePrincipal", RequireClientServicePrincipal); diff --git a/src/Users/wrapper/v1.0/Client/Models/Entity.cs b/src/Users/wrapper/v1.0/Client/Models/Entity.cs index bf0f56b1a9d..5506cb6bdba 100644 --- a/src/Users/wrapper/v1.0/Client/Models/Entity.cs +++ b/src/Users/wrapper/v1.0/Client/Models/Entity.cs @@ -151,6 +151,7 @@ public Entity() "#microsoft.graph.messageRule" => new global::Microsoft.Graph.PowerShell.Users.Client.Models.MessageRule(), "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod" => new global::Microsoft.Graph.PowerShell.Users.Client.Models.MicrosoftAuthenticatorAuthenticationMethod(), "#microsoft.graph.multiValueLegacyExtendedProperty" => new global::Microsoft.Graph.PowerShell.Users.Client.Models.MultiValueLegacyExtendedProperty(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Users.Client.Models.Note(), "#microsoft.graph.notebook" => new global::Microsoft.Graph.PowerShell.Users.Client.Models.Notebook(), "#microsoft.graph.oAuth2PermissionGrant" => new global::Microsoft.Graph.PowerShell.Users.Client.Models.OAuth2PermissionGrant(), "#microsoft.graph.offerShiftRequest" => new global::Microsoft.Graph.PowerShell.Users.Client.Models.OfferShiftRequest(), diff --git a/src/Users/wrapper/v1.0/Client/Models/Group.cs b/src/Users/wrapper/v1.0/Client/Models/Group.cs index da3fc1744ef..6ac5378f6e0 100644 --- a/src/Users/wrapper/v1.0/Client/Models/Group.cs +++ b/src/Users/wrapper/v1.0/Client/Models/Group.cs @@ -264,7 +264,7 @@ public partial class Group : global::Microsoft.Graph.PowerShell.Users.Client.Mod #else public string OnPremisesDomainName { get; set; } #endif - /// The onPremisesExtensionAttributes property + /// Complex type containing extension attributes 1-15 for the group, synchronized from on-premises Active Directory. Returned only on $select. Supports $filter (eq, ne, not, in). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public global::Microsoft.Graph.PowerShell.Users.Client.Models.OnPremisesExtensionAttributes? OnPremisesExtensionAttributes { get; set; } diff --git a/src/Users/wrapper/v1.0/Client/Models/Note.cs b/src/Users/wrapper/v1.0/Client/Models/Note.cs new file mode 100644 index 00000000000..83098bae141 --- /dev/null +++ b/src/Users/wrapper/v1.0/Client/Models/Note.cs @@ -0,0 +1,128 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace Microsoft.Graph.PowerShell.Users.Client.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")] + #pragma warning disable CS1591 + public partial class Note : global::Microsoft.Graph.PowerShell.Users.Client.Models.OutlookItem, IParsable + #pragma warning restore CS1591 + { + /// The file attachments for the note. Only inline image attachments (image/png, image/jpeg, image/gif, or image/bmp) are supported, with a maximum size of 3 MB per attachment. Use $expand to retrieve attachments. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Attachments { get; set; } +#nullable restore +#else + public List Attachments { get; set; } +#endif + /// The content of the note. Supports text or html content types. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::Microsoft.Graph.PowerShell.Users.Client.Models.ItemBody? Body { get; set; } +#nullable restore +#else + public global::Microsoft.Graph.PowerShell.Users.Client.Models.ItemBody Body { get; set; } +#endif + /// Auto-generated preview of the note body content (first ~255 characters, plain text). Read-only. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? BodyPreview { get; private set; } +#nullable restore +#else + public string BodyPreview { get; private set; } +#endif + /// The collection of open extensions defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Extensions { get; set; } +#nullable restore +#else + public List Extensions { get; set; } +#endif + /// Indicates whether the note has file attachments. Supports $filter (eq). Read-only. + public bool? HasAttachments { get; private set; } + /// Indicates whether the note is soft-deleted. Read-only. + public bool? IsDeleted { get; private set; } + /// The collection of multi-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? MultiValueExtendedProperties { get; set; } +#nullable restore +#else + public List MultiValueExtendedProperties { get; set; } +#endif + /// The collection of single-value extended properties defined for the note. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? SingleValueExtendedProperties { get; set; } +#nullable restore +#else + public List SingleValueExtendedProperties { get; set; } +#endif + /// The title of the note. Supports $filter (eq, ne, startsWith) and $orderby. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Subject { get; set; } +#nullable restore +#else + public string Subject { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Note() : base() + { + OdataType = "#microsoft.graph.note"; + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static new global::Microsoft.Graph.PowerShell.Users.Client.Models.Note CreateFromDiscriminatorValue(IParseNode parseNode) + { + if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode)); + return new global::Microsoft.Graph.PowerShell.Users.Client.Models.Note(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public override IDictionary> GetFieldDeserializers() + { + return new Dictionary>(base.GetFieldDeserializers()) + { + { "attachments", n => { Attachments = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Client.Models.Attachment.CreateFromDiscriminatorValue)?.AsList(); } }, + { "body", n => { Body = n.GetObjectValue(global::Microsoft.Graph.PowerShell.Users.Client.Models.ItemBody.CreateFromDiscriminatorValue); } }, + { "bodyPreview", n => { BodyPreview = n.GetStringValue(); } }, + { "extensions", n => { Extensions = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Client.Models.Extension.CreateFromDiscriminatorValue)?.AsList(); } }, + { "hasAttachments", n => { HasAttachments = n.GetBoolValue(); } }, + { "isDeleted", n => { IsDeleted = n.GetBoolValue(); } }, + { "multiValueExtendedProperties", n => { MultiValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Client.Models.MultiValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "singleValueExtendedProperties", n => { SingleValueExtendedProperties = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Client.Models.SingleValueLegacyExtendedProperty.CreateFromDiscriminatorValue)?.AsList(); } }, + { "subject", n => { Subject = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public override void Serialize(ISerializationWriter writer) + { + if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer)); + base.Serialize(writer); + writer.WriteCollectionOfObjectValues("attachments", Attachments); + writer.WriteObjectValue("body", Body); + writer.WriteCollectionOfObjectValues("extensions", Extensions); + writer.WriteCollectionOfObjectValues("multiValueExtendedProperties", MultiValueExtendedProperties); + writer.WriteCollectionOfObjectValues("singleValueExtendedProperties", SingleValueExtendedProperties); + writer.WriteStringValue("subject", Subject); + } + } +} +#pragma warning restore CS0618 diff --git a/src/Users/wrapper/v1.0/Client/Models/OutlookItem.cs b/src/Users/wrapper/v1.0/Client/Models/OutlookItem.cs index 40f8f0fd6b3..f2dab616deb 100644 --- a/src/Users/wrapper/v1.0/Client/Models/OutlookItem.cs +++ b/src/Users/wrapper/v1.0/Client/Models/OutlookItem.cs @@ -46,6 +46,7 @@ public partial class OutlookItem : global::Microsoft.Graph.PowerShell.Users.Clie "#microsoft.graph.contact" => new global::Microsoft.Graph.PowerShell.Users.Client.Models.Contact(), "#microsoft.graph.event" => new global::Microsoft.Graph.PowerShell.Users.Client.Models.Event(), "#microsoft.graph.message" => new global::Microsoft.Graph.PowerShell.Users.Client.Models.Message(), + "#microsoft.graph.note" => new global::Microsoft.Graph.PowerShell.Users.Client.Models.Note(), "#microsoft.graph.post" => new global::Microsoft.Graph.PowerShell.Users.Client.Models.Post(), _ => new global::Microsoft.Graph.PowerShell.Users.Client.Models.OutlookItem(), }; diff --git a/src/Users/wrapper/v1.0/Client/Models/User.cs b/src/Users/wrapper/v1.0/Client/Models/User.cs index ed04e0b66aa..0eb3552b610 100644 --- a/src/Users/wrapper/v1.0/Client/Models/User.cs +++ b/src/Users/wrapper/v1.0/Client/Models/User.cs @@ -561,6 +561,14 @@ public partial class User : global::Microsoft.Graph.PowerShell.Users.Client.Mode #nullable restore #else public string MySite { get; set; } +#endif + /// The notes in the user's Notes folder. Read-only. Nullable. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Notes { get; set; } +#nullable restore +#else + public List Notes { get; set; } #endif /// The oauth2PermissionGrants property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -1104,6 +1112,7 @@ public override IDictionary> GetFieldDeserializers() { "messages", n => { Messages = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Client.Models.Message.CreateFromDiscriminatorValue)?.AsList(); } }, { "mobilePhone", n => { MobilePhone = n.GetStringValue(); } }, { "mySite", n => { MySite = n.GetStringValue(); } }, + { "notes", n => { Notes = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Client.Models.Note.CreateFromDiscriminatorValue)?.AsList(); } }, { "oauth2PermissionGrants", n => { Oauth2PermissionGrants = n.GetCollectionOfObjectValues(global::Microsoft.Graph.PowerShell.Users.Client.Models.OAuth2PermissionGrant.CreateFromDiscriminatorValue)?.AsList(); } }, { "officeLocation", n => { OfficeLocation = n.GetStringValue(); } }, { "onPremisesDistinguishedName", n => { OnPremisesDistinguishedName = n.GetStringValue(); } }, @@ -1249,6 +1258,7 @@ public override void Serialize(ISerializationWriter writer) writer.WriteCollectionOfObjectValues("messages", Messages); writer.WriteStringValue("mobilePhone", MobilePhone); writer.WriteStringValue("mySite", MySite); + writer.WriteCollectionOfObjectValues("notes", Notes); writer.WriteCollectionOfObjectValues("oauth2PermissionGrants", Oauth2PermissionGrants); writer.WriteStringValue("officeLocation", OfficeLocation); writer.WriteObjectValue("onenote", Onenote); diff --git a/src/Users/wrapper/v1.0/Client/kiota-lock.json b/src/Users/wrapper/v1.0/Client/kiota-lock.json index 1417174642b..97138f51624 100644 --- a/src/Users/wrapper/v1.0/Client/kiota-lock.json +++ b/src/Users/wrapper/v1.0/Client/kiota-lock.json @@ -1,8 +1,8 @@ { - "descriptionHash": "DEA65375D6342E7DEB17A370618687E96FCB48444FCE94A80F12AAF911A6EE4DAC98FCE8F372AC5C9A03FB7C3A808EB24AE82149D53109C4198696A4EA63F89B", + "descriptionHash": "B41C010E2A2506F8D129715678378A40219360124BC7BA4F918946D7650F4FD5633262C252EF5747189B0094D91D32ABC36ED5FE8E29DC3BD5A97B9DDF543EEB", "descriptionLocation": "../../../../../openApiDocs_KiotaCompat/v1.0/Users.yml", "lockFileVersion": "1.0.0", - "kiotaVersion": "1.32.2", + "kiotaVersion": "1.34.1", "clientClassName": "ApiClient", "typeAccessModifier": "Public", "clientNamespaceName": "Microsoft.Graph.PowerShell.Users.Client", @@ -30,5 +30,6 @@ ], "includePatterns": [], "excludePatterns": [], - "disabledValidationRules": [] + "disabledValidationRules": [], + "allowedExternalOrigins": [] } \ No newline at end of file