Office365-REST-Python-Client 2.4.2__py3-none-any.whl → 2.4.4__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {Office365_REST_Python_Client-2.4.2.dist-info → Office365_REST_Python_Client-2.4.4.dist-info}/METADATA +65 -31
- {Office365_REST_Python_Client-2.4.2.dist-info → Office365_REST_Python_Client-2.4.4.dist-info}/RECORD +401 -259
- office365/base_item.py +27 -5
- office365/booking/business.py +7 -0
- office365/booking/currency.py +5 -0
- office365/booking/solutions_root.py +32 -0
- office365/communications/calls/invitation_participant_info.py +17 -1
- office365/communications/calls/options.py +9 -0
- office365/communications/onlinemeetings/provider_type.py +3 -0
- office365/communications/presences/presence.py +14 -0
- office365/communications/presences/status_message.py +12 -0
- office365/directory/administrative_unit.py +22 -0
- office365/directory/applications/collection.py +2 -1
- office365/directory/applications/roles/assignment.py +45 -5
- office365/directory/applications/roles/assignment_collection.py +8 -0
- office365/directory/applications/roles/role.py +6 -1
- office365/directory/audit/signins/activity.py +31 -0
- office365/directory/audit/signins/location.py +17 -0
- office365/directory/audit/signins/signin.py +33 -0
- office365/directory/authentication/authentication.py +9 -0
- office365/directory/authentication/methods/details.py +25 -0
- office365/directory/authentication/methods/email.py +16 -0
- office365/directory/authentication/methods/root.py +27 -0
- office365/directory/certificates/authority.py +6 -1
- office365/directory/extensions/extended_property.py +8 -1
- office365/directory/extensions/extension.py +1 -1
- office365/directory/extensions/extension_property.py +0 -3
- office365/directory/extensions/open_type.py +8 -0
- office365/directory/groups/collection.py +2 -4
- office365/directory/groups/group.py +18 -4
- office365/directory/identities/governance.py +2 -0
- office365/directory/identities/object_identity.py +3 -3
- office365/directory/insights/resource_reference.py +15 -0
- office365/directory/insights/shared.py +36 -0
- office365/directory/insights/sharing_detail.py +11 -0
- office365/directory/insights/trending.py +8 -0
- office365/directory/insights/usage_details.py +16 -0
- office365/directory/insights/used.py +30 -0
- office365/directory/invitations/invitation.py +33 -1
- office365/directory/licenses/assigned_plan.py +19 -1
- office365/directory/licenses/assignment_state.py +5 -0
- office365/directory/licenses/service_plan_info.py +4 -0
- office365/directory/licenses/subscribed_sku.py +41 -0
- office365/directory/licenses/units_detail.py +11 -0
- office365/directory/object.py +3 -1
- office365/directory/object_collection.py +3 -4
- office365/directory/password_credential.py +5 -1
- office365/directory/permissions/email_identity.py +5 -0
- office365/directory/permissions/grants/condition_set.py +26 -0
- office365/directory/permissions/grants/resource_specific.py +21 -0
- office365/directory/policies/authentication_flows.py +9 -0
- office365/directory/policies/authentication_strength.py +10 -0
- office365/directory/policies/authorization.py +8 -0
- office365/directory/policies/cross_tenant_access.py +5 -0
- office365/directory/policies/root.py +35 -2
- office365/directory/protection/information.py +5 -0
- office365/directory/protection/risk_detection.py +11 -0
- office365/directory/protection/riskyusers/activity.py +5 -0
- office365/directory/protection/riskyusers/collection.py +32 -0
- office365/directory/protection/riskyusers/history_item.py +20 -0
- office365/directory/protection/riskyusers/risky_user.py +26 -0
- office365/directory/protection/root.py +31 -0
- office365/directory/rolemanagement/application.py +35 -0
- office365/directory/{roles → rolemanagement}/management.py +8 -1
- office365/directory/{roles → rolemanagement}/role.py +14 -0
- office365/directory/{roles → rolemanagement}/template.py +8 -0
- office365/directory/rolemanagement/unified_role_assignment.py +45 -0
- office365/directory/rolemanagement/unified_role_definition.py +6 -0
- office365/directory/security/alerts/alert.py +21 -0
- office365/directory/security/alerts/history_state.py +5 -0
- office365/directory/security/attacksimulations/automation.py +21 -0
- office365/directory/security/attacksimulations/automation_run.py +5 -0
- office365/directory/security/attacksimulations/repeat_offender.py +6 -0
- office365/directory/security/attacksimulations/root.py +26 -0
- office365/directory/security/attacksimulations/simulation.py +17 -0
- office365/directory/security/cases/__init__.py +0 -0
- office365/directory/security/cases/ediscovery.py +6 -0
- office365/directory/security/cases/root.py +22 -0
- office365/directory/security/incidents/incident.py +67 -0
- office365/directory/security/security.py +10 -1
- office365/directory/serviceprincipals/service_principal.py +89 -4
- office365/directory/synchronization/__init__.py +0 -0
- office365/directory/synchronization/job.py +16 -0
- office365/directory/synchronization/progress.py +5 -0
- office365/directory/synchronization/status.py +13 -0
- office365/directory/synchronization/synchronization.py +24 -0
- office365/directory/tenant_information.py +17 -0
- office365/directory/tenant_relationship.py +21 -0
- office365/directory/users/activities/activity.py +45 -1
- office365/directory/users/collection.py +8 -0
- office365/directory/users/password_profile.py +18 -2
- office365/directory/users/user.py +254 -29
- office365/entity.py +3 -3
- office365/graph_client.py +64 -12
- office365/intune/audit/actor.py +5 -0
- office365/intune/audit/event.py +21 -24
- office365/intune/audit/event_collection.py +26 -0
- office365/intune/audit/property.py +5 -0
- office365/intune/audit/resource.py +11 -0
- office365/intune/brand.py +6 -0
- office365/intune/devices/compliance/__init__.py +0 -0
- office365/intune/devices/compliance/policy.py +6 -0
- office365/intune/devices/compliance/policy_state.py +5 -0
- office365/intune/devices/data.py +5 -0
- office365/intune/devices/detail.py +10 -0
- office365/intune/devices/enrollment/__init__.py +0 -0
- office365/intune/devices/enrollment/configuration.py +25 -0
- office365/intune/devices/enrollment/configuration_assignment.py +5 -0
- office365/intune/devices/enrollment/limit_configuration.py +5 -0
- office365/intune/devices/managed.py +44 -3
- office365/intune/devices/management/__init__.py +0 -0
- office365/intune/devices/management/management.py +69 -0
- office365/intune/devices/management/reports/__init__.py +0 -0
- office365/intune/devices/management/reports/reports.py +5 -0
- office365/intune/devices/management/settings.py +18 -0
- office365/intune/organizations/branding.py +15 -0
- office365/intune/organizations/organization.py +14 -0
- office365/intune/printing/__init__.py +0 -0
- office365/intune/printing/base.py +11 -0
- office365/intune/printing/capabilities.py +5 -0
- office365/intune/printing/connectors/__init__.py +0 -0
- office365/intune/printing/connectors/connector.py +6 -0
- office365/intune/printing/operations/__init__.py +0 -0
- office365/intune/printing/print.py +24 -0
- office365/intune/printing/printer.py +6 -0
- office365/intune/printing/services/__init__.py +0 -0
- office365/intune/printing/services/endpoint.py +5 -0
- office365/intune/printing/services/service.py +17 -0
- office365/intune/printing/share.py +5 -0
- office365/intune/printing/shares/__init__.py +0 -0
- office365/intune/printing/taskdefinitions/__init__.py +0 -0
- office365/intune/provisioned_plan.py +5 -1
- office365/intune/servicecommunications/__init__.py +0 -0
- office365/intune/servicecommunications/announcement.py +39 -0
- office365/intune/servicecommunications/announcement_base.py +5 -0
- office365/intune/servicecommunications/health/__init__.py +0 -0
- office365/intune/servicecommunications/health/health.py +7 -0
- office365/intune/servicecommunications/issues/__init__.py +0 -0
- office365/intune/servicecommunications/issues/issue.py +29 -0
- office365/intune/servicecommunications/messages/__init__.py +0 -0
- office365/intune/servicecommunications/messages/update.py +10 -0
- office365/intune/termsandconditions/__init__.py +0 -0
- office365/intune/vpp_token.py +10 -0
- office365/onedrive/admin.py +16 -0
- office365/onedrive/columns/content_approval_status.py +5 -0
- office365/onedrive/columns/datetime.py +15 -0
- office365/onedrive/columns/default_value.py +4 -0
- office365/onedrive/columns/definition.py +49 -3
- office365/onedrive/columns/definition_collection.py +17 -6
- office365/onedrive/columns/lookup.py +5 -1
- office365/onedrive/columns/types.py +13 -0
- office365/onedrive/contenttypes/content_type.py +8 -0
- office365/onedrive/driveitems/audio.py +12 -1
- office365/onedrive/driveitems/driveItem.py +147 -69
- office365/onedrive/driveitems/image.py +8 -1
- office365/onedrive/driveitems/item_preview_info.py +20 -2
- office365/onedrive/driveitems/remote_item.py +19 -4
- office365/onedrive/drives/drive.py +7 -1
- office365/onedrive/drives/quota.py +18 -0
- office365/onedrive/drives/recipient.py +4 -0
- office365/onedrive/files/system_info.py +8 -6
- office365/onedrive/folders/folder.py +3 -3
- office365/onedrive/internal/paths/children.py +1 -4
- office365/onedrive/internal/paths/shared.py +7 -2
- office365/onedrive/lists/collection.py +12 -6
- office365/onedrive/lists/list.py +13 -5
- office365/onedrive/operations/long_running.py +7 -0
- office365/onedrive/operations/pending.py +13 -0
- office365/onedrive/operations/pending_content_update.py +5 -0
- office365/onedrive/permissions/collection.py +5 -6
- office365/onedrive/permissions/sharing_link.py +16 -1
- office365/onedrive/sensitivitylabels/__init__.py +0 -0
- office365/onedrive/sensitivitylabels/assignment.py +17 -0
- office365/onedrive/sensitivitylabels/assignment_method.py +4 -0
- office365/onedrive/sensitivitylabels/extract_result.py +13 -0
- office365/onedrive/sharepoint_settings.py +25 -0
- office365/onedrive/sites/sites_with_root.py +11 -1
- office365/onedrive/termstore/groups/collection.py +1 -1
- office365/onedrive/termstore/groups/group.py +1 -0
- office365/onedrive/termstore/sets/collection.py +1 -1
- office365/onenote/operations/operation.py +10 -1
- office365/onenote/resources/resource.py +1 -0
- office365/outlook/calendar/calendar.py +116 -6
- office365/outlook/calendar/dateTimeTimeZone.py +4 -0
- office365/outlook/calendar/email_address.py +7 -0
- office365/outlook/calendar/events/event.py +0 -4
- office365/outlook/calendar/events/reminder.py +22 -3
- office365/outlook/calendar/group.py +0 -2
- office365/outlook/calendar/location_constraint.py +16 -1
- office365/outlook/calendar/meetingtimes/activity_domain.py +10 -0
- office365/outlook/calendar/meetingtimes/suggestion.py +1 -1
- office365/outlook/calendar/meetingtimes/time_constraint.py +18 -0
- office365/outlook/calendar/permissions/__init__.py +0 -0
- office365/outlook/calendar/permissions/collection.py +24 -0
- office365/outlook/calendar/{permission.py → permissions/permission.py} +35 -2
- office365/outlook/calendar/place.py +7 -0
- office365/outlook/calendar/role_type.py +17 -0
- office365/outlook/calendar/schedule/information.py +5 -4
- office365/outlook/calendar/schedule/item.py +20 -1
- office365/outlook/calendar/sharing_message.py +2 -2
- office365/outlook/calendar/time_zone_base.py +3 -0
- office365/outlook/calendar/working_hours.py +17 -1
- office365/outlook/contacts/collection.py +39 -0
- office365/outlook/contacts/contact.py +21 -11
- office365/outlook/geo_coordinates.py +20 -0
- office365/outlook/item.py +5 -4
- office365/outlook/locale_info.py +3 -0
- office365/outlook/mail/automatic_replies_setting.py +14 -0
- office365/outlook/mail/folders/folder.py +52 -3
- office365/outlook/mail/folders/search.py +11 -0
- office365/outlook/mail/importance.py +1 -0
- office365/outlook/mail/item_body.py +3 -0
- office365/outlook/mail/location.py +27 -2
- office365/outlook/mail/location_constraint_item.py +5 -0
- office365/outlook/mail/mailbox_settings.py +13 -1
- office365/outlook/mail/messages/collection.py +7 -0
- office365/outlook/mail/messages/followup_flag.py +21 -0
- office365/outlook/mail/messages/internet_header.py +16 -0
- office365/outlook/mail/messages/message.py +184 -6
- office365/outlook/mail/messages/rules/__init__.py +0 -0
- office365/outlook/mail/messages/rules/actions.py +38 -0
- office365/outlook/mail/messages/rules/predicates.py +5 -0
- office365/outlook/mail/messages/rules/rule.py +32 -0
- office365/outlook/mail/patterned_recurrence.py +14 -1
- office365/outlook/mail/physical_address.py +5 -1
- office365/outlook/mail/recipient.py +3 -0
- office365/outlook/mail/recurrence_pattern.py +18 -1
- office365/outlook/mail/recurrence_range.py +16 -2
- office365/outlook/timezone_information.py +3 -0
- office365/reports/root.py +28 -1
- office365/reports/security/__init__.py +0 -0
- office365/reports/security/root.py +21 -0
- office365/reports/userregistration/__init__.py +0 -0
- office365/reports/userregistration/method_count.py +17 -0
- office365/reports/userregistration/method_summary.py +21 -0
- office365/runtime/auth/authentication_context.py +123 -25
- office365/runtime/auth/client_credential.py +2 -2
- office365/runtime/auth/providers/acs_token_provider.py +6 -3
- office365/runtime/auth/providers/saml_token_provider.py +10 -7
- office365/runtime/auth/token_response.py +3 -3
- office365/runtime/client_object_collection.py +12 -7
- office365/runtime/client_result.py +9 -0
- office365/runtime/client_runtime_context.py +10 -8
- office365/runtime/http/request_options.py +2 -1
- office365/runtime/odata/request.py +4 -4
- office365/runtime/paths/appid.py +2 -1
- office365/runtime/paths/entity.py +2 -2
- office365/{sharepoint/internal/paths/entity.py → runtime/paths/key.py} +5 -3
- office365/runtime/paths/resource_path.py +3 -0
- office365/runtime/types/event_handler.py +6 -0
- office365/search/external/__init__.py +0 -0
- office365/search/external/configuration.py +8 -0
- office365/search/external/connection.py +27 -0
- office365/{external → search/external}/external.py +1 -1
- office365/search/external/search_settings.py +5 -0
- office365/search/query.py +3 -1
- office365/search/request.py +3 -1
- office365/search/sharepoint_onedrive_options.py +3 -0
- office365/search/sort_property.py +9 -0
- office365/sharepoint/activities/client_request.py +4 -1
- office365/sharepoint/activities/logger.py +25 -0
- office365/sharepoint/activities/revision_info.py +9 -0
- office365/sharepoint/addtoonedrive/mount_point.py +25 -0
- office365/sharepoint/addtoonedrive/mounted_folder_info.py +5 -0
- office365/sharepoint/alerts/alert.py +31 -0
- office365/sharepoint/apps/license_collection.py +1 -2
- office365/sharepoint/changes/item.py +14 -0
- office365/sharepoint/client_context.py +91 -30
- office365/sharepoint/clientsidecomponent/component_context_info.py +7 -0
- office365/sharepoint/clientsidecomponent/identifier.py +3 -0
- office365/sharepoint/compliance/tag_info.py +17 -0
- office365/sharepoint/contenttypes/collection.py +6 -7
- office365/sharepoint/contenttypes/content_type.py +49 -1
- office365/sharepoint/contenttypes/fieldlinks/collection.py +5 -6
- office365/sharepoint/features/known_list.py +2 -0
- office365/sharepoint/fields/collection.py +70 -39
- office365/sharepoint/fields/computed.py +5 -2
- office365/sharepoint/fields/creation_information.py +5 -4
- office365/sharepoint/fields/field.py +73 -15
- office365/sharepoint/fields/user.py +3 -3
- office365/sharepoint/files/checked_out_file.py +3 -2
- office365/sharepoint/files/file.py +9 -4
- office365/sharepoint/files/versions/version.py +7 -9
- office365/sharepoint/folders/collection.py +2 -2
- office365/sharepoint/folders/coloring.py +39 -0
- office365/sharepoint/folders/coloring_information.py +15 -0
- office365/sharepoint/folders/folder.py +21 -10
- office365/sharepoint/forms/customization.py +8 -0
- office365/sharepoint/listitems/listitem.py +29 -10
- office365/sharepoint/lists/bloom_filter.py +0 -1
- office365/sharepoint/lists/creation_information.py +18 -4
- office365/sharepoint/lists/list.py +203 -27
- office365/sharepoint/lists/render_data_parameters.py +21 -1
- office365/sharepoint/lists/template_type.py +10 -0
- office365/sharepoint/navigation/configured_metadata_items.py +25 -1
- office365/sharepoint/navigation/metadata_settings.py +6 -4
- office365/sharepoint/permissions/irm/file_settings.py +43 -0
- office365/sharepoint/permissions/securable_object.py +5 -6
- office365/sharepoint/portal/sites/manager.py +5 -6
- office365/sharepoint/portal/userprofiles/documents_shared_with_group.py +3 -0
- office365/sharepoint/publishing/base_custom_property.py +8 -0
- office365/sharepoint/publishing/navigation/structural_navigation_cache_wrapper.py +8 -0
- office365/sharepoint/publishing/pagecopywithassets/__init__.py +0 -0
- office365/sharepoint/publishing/pagecopywithassets/response.py +8 -0
- office365/sharepoint/publishing/pages/campaign_publication.py +7 -0
- office365/sharepoint/publishing/pages/collection.py +1 -1
- office365/sharepoint/publishing/pages/page.py +4 -1
- office365/sharepoint/publishing/pages/reposts/metadata.py +8 -0
- office365/sharepoint/publishing/personmagazine/person_magazine.py +4 -1
- office365/sharepoint/search/administration/tenant_crawl_versions_info_provider.py +8 -1
- office365/sharepoint/search/query/auto_completion_match.py +3 -0
- office365/sharepoint/search/query/property_value.py +18 -0
- office365/sharepoint/search/request.py +16 -2
- office365/sharepoint/sharing/abilities.py +22 -0
- office365/sharepoint/sharing/direct_abilities.py +27 -0
- office365/sharepoint/sharing/link_abilities.py +9 -1
- office365/sharepoint/sharing/links/data.py +26 -1
- office365/sharepoint/sharing/links/info.py +1 -1
- office365/sharepoint/sharing/links/partial_success_response.py +5 -0
- office365/sharepoint/sharing/links/share_settings.py +24 -1
- office365/sharepoint/sharing/object_sharing_information.py +65 -2
- office365/sharepoint/sharing/object_sharing_information_user.py +9 -0
- office365/sharepoint/sharing/object_sharing_settings.py +17 -4
- office365/sharepoint/sharing/principal.py +10 -0
- office365/sharepoint/sharing/securable_object_extensions.py +1 -17
- office365/sharepoint/sharing/site_sharing_report_helper.py +2 -1
- office365/sharepoint/sharing/user_sharing_result.py +18 -8
- office365/sharepoint/sitehealth/result.py +10 -0
- office365/sharepoint/sites/language.py +11 -1
- office365/sharepoint/sites/language_collection.py +1 -0
- office365/sharepoint/sites/site.py +42 -7
- office365/sharepoint/taxonomy/create_xml_parameters.py +22 -15
- office365/sharepoint/taxonomy/field.py +10 -8
- office365/sharepoint/taxonomy/groups/collection.py +8 -1
- office365/sharepoint/taxonomy/groups/group.py +26 -0
- office365/sharepoint/taxonomy/sets/collection.py +15 -0
- office365/sharepoint/taxonomy/sets/name.py +23 -0
- office365/sharepoint/taxonomy/sets/set.py +16 -1
- office365/sharepoint/taxonomy/stores/store.py +0 -8
- office365/sharepoint/tenant/administration/audit/search_request_status.py +8 -0
- office365/sharepoint/tenant/administration/deny_add_and_customize_pages_status.py +3 -0
- office365/sharepoint/tenant/administration/hubsites/permission.py +10 -0
- office365/sharepoint/tenant/administration/sites/properties.py +12 -10
- office365/sharepoint/tenant/administration/tenant.py +2 -1
- office365/sharepoint/tenant/apps/information.py +3 -1
- office365/sharepoint/tenant/management/office365_tenant.py +14 -11
- office365/sharepoint/types/resource_path.py +3 -1
- office365/sharepoint/userprofiles/people_manager.py +0 -2
- office365/sharepoint/userprofiles/sharedwithme/document.py +16 -0
- office365/sharepoint/userprofiles/sharedwithme/document_user.py +12 -0
- office365/sharepoint/userprofiles/sharedwithme/item_collection.py +41 -0
- office365/sharepoint/userprofiles/sharedwithme/items.py +18 -1
- office365/sharepoint/viva/site_manager.py +14 -0
- office365/sharepoint/webhooks/subscription_collection.py +5 -6
- office365/sharepoint/webparts/definition.py +1 -1
- office365/sharepoint/webparts/webpart.py +18 -4
- office365/sharepoint/webs/context_web_information.py +2 -4
- office365/sharepoint/webs/web.py +31 -12
- office365/sharepoint/workflowservices/manager.py +0 -2
- office365/subscriptions/collection.py +42 -0
- office365/subscriptions/subscription.py +120 -2
- office365/teams/apps/catalog.py +23 -0
- office365/teams/associated_info.py +12 -0
- office365/teams/channels/channel.py +2 -3
- office365/teams/channels/collection.py +1 -1
- office365/teams/channels/iIdentity.py +5 -0
- office365/teams/chats/chat.py +12 -2
- office365/teams/chats/collection.py +1 -2
- office365/teams/chats/messages/__init__.py +0 -0
- office365/teams/chats/messages/info.py +14 -0
- office365/teams/chats/{message.py → messages/message.py} +18 -3
- office365/teams/info.py +20 -0
- office365/teams/members/aad_user_conversation.py +2 -2
- office365/teams/members/conversation_collection.py +3 -3
- office365/teams/schedule/change_request.py +4 -2
- office365/teams/schedule/change_tracked_entity.py +11 -2
- office365/teams/summary.py +15 -0
- office365/teams/tabs/configuration.py +12 -1
- office365/teams/tabs/tab.py +0 -1
- office365/teams/team.py +34 -1
- office365/teams/teamwork/__init__.py +0 -0
- office365/teams/teamwork/activity_topic.py +5 -0
- office365/teams/teamwork/tags/__init__.py +0 -0
- office365/teams/teamwork/tags/identity.py +6 -0
- office365/teams/teamwork/tags/member.py +5 -0
- office365/teams/teamwork/tags/tag.py +15 -0
- office365/{directory/security/cases_root.py → teams/viva/employee_experience_user.py} +1 -1
- office365/todo/attachments/session.py +34 -0
- office365/todo/linked_resource.py +10 -1
- office365/todo/tasks/task.py +4 -0
- office365/directory/identities/protection_root.py +0 -5
- office365/directory/rbac/application.py +0 -18
- office365/directory/rbac/unified_role_assignment.py +0 -8
- office365/external/connection.py +0 -5
- office365/intune/devices/management.py +0 -35
- office365/onedrive/internal/queries/download_content.py +0 -26
- office365/onedrive/internal/queries/upload_content.py +0 -23
- office365/outlook/mail/messages/message_rule.py +0 -15
- office365/runtime/auth/providers/oauth_token_provider.py +0 -25
- office365/teams/team_info.py +0 -6
- {Office365_REST_Python_Client-2.4.2.dist-info → Office365_REST_Python_Client-2.4.4.dist-info}/LICENSE +0 -0
- {Office365_REST_Python_Client-2.4.2.dist-info → Office365_REST_Python_Client-2.4.4.dist-info}/WHEEL +0 -0
- {Office365_REST_Python_Client-2.4.2.dist-info → Office365_REST_Python_Client-2.4.4.dist-info}/top_level.txt +0 -0
- /office365/{directory/rbac → booking}/__init__.py +0 -0
- /office365/directory/{roles → protection}/__init__.py +0 -0
- /office365/{external → directory/protection/riskyusers}/__init__.py +0 -0
- /office365/{teams/messages → directory/rolemanagement}/__init__.py +0 -0
- /office365/outlook/calendar/{time_slot.py → meetingtimes/time_slot.py} +0 -0
- /office365/teams/chats/{message_attachment.py → messages/attachment.py} +0 -0
- /office365/teams/{member_settings.py → members/settings.py} +0 -0
- /office365/teams/{user_teamwork.py → teamwork/user.py} +0 -0
|
@@ -1,37 +1,42 @@
|
|
|
1
|
+
import json
|
|
2
|
+
|
|
1
3
|
from office365.communications.onlinemeetings.collection import OnlineMeetingCollection
|
|
2
4
|
from office365.communications.presences.presence import Presence
|
|
3
5
|
from office365.delta_collection import DeltaCollection
|
|
6
|
+
from office365.directory.applications.roles.assignment_collection import AppRoleAssignmentCollection
|
|
7
|
+
from office365.directory.audit.signins.activity import SignInActivity
|
|
4
8
|
from office365.directory.authentication.authentication import Authentication
|
|
5
9
|
from office365.directory.extensions.extension import Extension
|
|
10
|
+
from office365.directory.identities.object_identity import ObjectIdentity
|
|
6
11
|
from office365.directory.insights.office_graph import OfficeGraphInsights
|
|
12
|
+
from office365.directory.licenses.assigned_license import AssignedLicense
|
|
7
13
|
from office365.directory.licenses.assigned_plan import AssignedPlan
|
|
8
14
|
from office365.directory.licenses.assignment_state import LicenseAssignmentState
|
|
15
|
+
from office365.directory.licenses.details import LicenseDetails
|
|
16
|
+
from office365.directory.object import DirectoryObject
|
|
17
|
+
from office365.directory.object_collection import DirectoryObjectCollection
|
|
9
18
|
from office365.directory.permissions.grants.oauth2 import OAuth2PermissionGrant
|
|
19
|
+
from office365.directory.profile_photo import ProfilePhoto
|
|
10
20
|
from office365.directory.users.activities.collection import UserActivityCollection
|
|
21
|
+
from office365.directory.users.password_profile import PasswordProfile
|
|
11
22
|
from office365.directory.users.settings import UserSettings
|
|
23
|
+
from office365.entity_collection import EntityCollection
|
|
24
|
+
from office365.intune.devices.data import DeviceAndAppManagementData
|
|
12
25
|
from office365.intune.devices.managed import ManagedDevice
|
|
13
26
|
from office365.intune.devices.managed_app_diagnostic_status import ManagedAppDiagnosticStatus
|
|
27
|
+
from office365.onedrive.drives.drive import Drive
|
|
14
28
|
from office365.onedrive.sites.site import Site
|
|
15
29
|
from office365.onenote.onenote import Onenote
|
|
16
30
|
from office365.outlook.calendar.attendees.base import AttendeeBase
|
|
17
31
|
from office365.outlook.calendar.calendar import Calendar
|
|
18
|
-
from office365.outlook.calendar.group import CalendarGroup
|
|
19
32
|
from office365.outlook.calendar.events.event import Event
|
|
20
|
-
from office365.outlook.calendar.meetingtimes.suggestions_result import MeetingTimeSuggestionsResult
|
|
21
33
|
from office365.outlook.calendar.events.reminder import Reminder
|
|
22
|
-
from office365.
|
|
23
|
-
from office365.
|
|
24
|
-
from office365.
|
|
25
|
-
from office365.directory.licenses.details import LicenseDetails
|
|
26
|
-
from office365.directory.identities.object_identity import ObjectIdentity
|
|
27
|
-
from office365.directory.profile_photo import ProfilePhoto
|
|
28
|
-
from office365.entity_collection import EntityCollection
|
|
29
|
-
from office365.outlook.contacts.contact import Contact
|
|
34
|
+
from office365.outlook.calendar.group import CalendarGroup
|
|
35
|
+
from office365.outlook.calendar.meetingtimes.suggestions_result import MeetingTimeSuggestionsResult
|
|
36
|
+
from office365.outlook.contacts.collection import ContactCollection
|
|
30
37
|
from office365.outlook.contacts.folder import ContactFolder
|
|
31
38
|
from office365.outlook.convert_id_result import ConvertIdResult
|
|
32
39
|
from office365.outlook.mail.folders.collection import MailFolderCollection
|
|
33
|
-
from office365.outlook.mail.folders.folder import MailFolder
|
|
34
|
-
from office365.onedrive.drives.drive import Drive
|
|
35
40
|
from office365.outlook.mail.mailbox_settings import MailboxSettings
|
|
36
41
|
from office365.outlook.mail.messages.collection import MessageCollection
|
|
37
42
|
from office365.outlook.mail.messages.message import Message
|
|
@@ -42,19 +47,35 @@ from office365.runtime.client_result import ClientResult
|
|
|
42
47
|
from office365.runtime.client_value_collection import ClientValueCollection
|
|
43
48
|
from office365.runtime.http.http_method import HttpMethod
|
|
44
49
|
from office365.runtime.paths.entity import EntityPath
|
|
50
|
+
from office365.runtime.paths.resource_path import ResourcePath
|
|
51
|
+
from office365.runtime.queries.create_entity import CreateEntityQuery
|
|
45
52
|
from office365.runtime.queries.function import FunctionQuery
|
|
46
53
|
from office365.runtime.queries.service_operation import ServiceOperationQuery
|
|
47
|
-
from office365.runtime.paths.resource_path import ResourcePath
|
|
48
54
|
from office365.runtime.types.collections import StringCollection
|
|
49
55
|
from office365.teams.chats.collection import ChatCollection
|
|
50
56
|
from office365.teams.collection import TeamCollection
|
|
51
|
-
from office365.teams.
|
|
57
|
+
from office365.teams.teamwork.user import UserTeamwork
|
|
52
58
|
from office365.todo.todo import Todo
|
|
59
|
+
from office365.teams.viva.employee_experience_user import EmployeeExperienceUser
|
|
53
60
|
|
|
54
61
|
|
|
55
62
|
class User(DirectoryObject):
|
|
56
63
|
"""Represents an Azure AD user account. Inherits from directoryObject."""
|
|
57
64
|
|
|
65
|
+
def add_extension(self, name):
|
|
66
|
+
"""
|
|
67
|
+
Creates an open extension (openTypeExtension object) and add custom properties in a new or existing instance
|
|
68
|
+
of a User resource.
|
|
69
|
+
:param str name:
|
|
70
|
+
"""
|
|
71
|
+
from office365.directory.extensions.open_type import OpenTypeExtension
|
|
72
|
+
return_type = OpenTypeExtension(self.context)
|
|
73
|
+
return_type.set_property("extensionName", name)
|
|
74
|
+
self.extensions.add_child(return_type)
|
|
75
|
+
qry = CreateEntityQuery(self.extensions, return_type, return_type)
|
|
76
|
+
self.context.add_query(qry)
|
|
77
|
+
return return_type
|
|
78
|
+
|
|
58
79
|
def assign_license(self, add_licenses, remove_licenses):
|
|
59
80
|
"""
|
|
60
81
|
Add or remove licenses on the user.
|
|
@@ -71,6 +92,55 @@ class User(DirectoryObject):
|
|
|
71
92
|
self.context.add_query(qry)
|
|
72
93
|
return self
|
|
73
94
|
|
|
95
|
+
def assign_manager(self, user):
|
|
96
|
+
"""
|
|
97
|
+
Assign a user's manager.
|
|
98
|
+
|
|
99
|
+
:param str or User or OrgContact user: User or office365.intune.organizations.contact.OrgContact
|
|
100
|
+
or identifier
|
|
101
|
+
"""
|
|
102
|
+
|
|
103
|
+
def _construct_request(request):
|
|
104
|
+
"""
|
|
105
|
+
:type request: office365.runtime.http.request_options.RequestOptions
|
|
106
|
+
"""
|
|
107
|
+
request.method = HttpMethod.Put
|
|
108
|
+
request.set_header('Content-Type', "application/json")
|
|
109
|
+
request.set_header('Accept', "application/json")
|
|
110
|
+
request.data = json.dumps(request.data)
|
|
111
|
+
|
|
112
|
+
def _assign_manager(user_id):
|
|
113
|
+
"""
|
|
114
|
+
:type user_id: str
|
|
115
|
+
"""
|
|
116
|
+
payload = {
|
|
117
|
+
"@odata.id": "https://graph.microsoft.com/v1.0/users/{0}".format(user_id)
|
|
118
|
+
}
|
|
119
|
+
qry = ServiceOperationQuery(self.manager, "$ref", None, payload)
|
|
120
|
+
self.context.add_query(qry).before_query_execute(_construct_request)
|
|
121
|
+
|
|
122
|
+
if isinstance(user, User):
|
|
123
|
+
def _user_loaded():
|
|
124
|
+
_assign_manager(user.id)
|
|
125
|
+
|
|
126
|
+
user.ensure_property("id", _user_loaded)
|
|
127
|
+
else:
|
|
128
|
+
_assign_manager(user)
|
|
129
|
+
return self.manager
|
|
130
|
+
|
|
131
|
+
def remove_manager(self):
|
|
132
|
+
"""Remove a user's manager."""
|
|
133
|
+
qry = ServiceOperationQuery(self.manager, "$ref")
|
|
134
|
+
|
|
135
|
+
def _construct_request(request):
|
|
136
|
+
"""
|
|
137
|
+
:type request: office365.runtime.http.request_options.RequestOptions
|
|
138
|
+
"""
|
|
139
|
+
request.method = HttpMethod.Delete
|
|
140
|
+
|
|
141
|
+
self.context.add_query(qry).before_query_execute(_construct_request)
|
|
142
|
+
return self
|
|
143
|
+
|
|
74
144
|
def change_password(self, current_password, new_password):
|
|
75
145
|
"""
|
|
76
146
|
Enable the user to update their password. Any user can update their password without belonging
|
|
@@ -84,7 +154,7 @@ class User(DirectoryObject):
|
|
|
84
154
|
self.context.add_query(qry)
|
|
85
155
|
return self
|
|
86
156
|
|
|
87
|
-
def send_mail(self, subject, body, to_recipients, cc_recipients=
|
|
157
|
+
def send_mail(self, subject, body, to_recipients, cc_recipients=None, bcc_recipients=None, save_to_sent_items=False):
|
|
88
158
|
"""Send a new message on the fly
|
|
89
159
|
|
|
90
160
|
:param str subject: The subject of the message.
|
|
@@ -99,8 +169,10 @@ class User(DirectoryObject):
|
|
|
99
169
|
return_type.subject = subject
|
|
100
170
|
return_type.body = body
|
|
101
171
|
[return_type.to_recipients.add(Recipient.from_email(email)) for email in to_recipients]
|
|
102
|
-
|
|
103
|
-
|
|
172
|
+
if bcc_recipients is not None:
|
|
173
|
+
[return_type.bcc_recipients.add(Recipient.from_email(email)) for email in bcc_recipients]
|
|
174
|
+
if cc_recipients is not None:
|
|
175
|
+
[return_type.cc_recipients.add(Recipient.from_email(email)) for email in cc_recipients]
|
|
104
176
|
|
|
105
177
|
payload = {
|
|
106
178
|
"message": return_type,
|
|
@@ -125,7 +197,16 @@ class User(DirectoryObject):
|
|
|
125
197
|
self.context.add_query(qry)
|
|
126
198
|
return self
|
|
127
199
|
|
|
128
|
-
def
|
|
200
|
+
def export_device_and_app_management_data(self):
|
|
201
|
+
""""""
|
|
202
|
+
return_type = ClientResult(self.context, ClientValueCollection(DeviceAndAppManagementData))
|
|
203
|
+
qry = FunctionQuery(self, "exportDeviceAndAppManagementData", None, return_type)
|
|
204
|
+
self.context.add_query(qry)
|
|
205
|
+
return return_type
|
|
206
|
+
|
|
207
|
+
def find_meeting_times(self, attendees=None, location_constraint=None, time_constraint=None,
|
|
208
|
+
meeting_duration=None, max_candidates=None, is_organizer_optional=None,
|
|
209
|
+
return_suggestion_reasons=None, minimum_attendee_percentage=None):
|
|
129
210
|
"""
|
|
130
211
|
Suggest meeting times and locations based on organizer and attendees availability, and time or location
|
|
131
212
|
constraints specified as parameters.
|
|
@@ -145,10 +226,31 @@ class User(DirectoryObject):
|
|
|
145
226
|
:param office365.outlook.calendar.location_constraint.LocationConstraint or None location_constraint:
|
|
146
227
|
The organizer's requirements about the meeting location, such as whether a suggestion for a meeting
|
|
147
228
|
location is required, or there are specific locations only where the meeting can take place. Optional.
|
|
229
|
+
:param TimeConstraint time_constraint: Any time restrictions for a meeting, which can include the nature
|
|
230
|
+
of the meeting (activityDomain property) and possible meeting time periods (timeSlots property).
|
|
231
|
+
findMeetingTimes assumes activityDomain as work if you don't specify this parameter. Optional.
|
|
232
|
+
:param str meeting_duration: The length of the meeting, denoted in ISO8601 format.
|
|
233
|
+
For example, 1 hour is denoted as 'PT1H', where 'P' is the duration designator,
|
|
234
|
+
'T' is the time designator, and 'H' is the hour designator.
|
|
235
|
+
Use M to indicate minutes for the duration; for example, 2 hours and 30 minutes would be 'PT2H30M'.
|
|
236
|
+
If no meeting duration is specified, findMeetingTimes uses the default of 30 minutes. Optional.
|
|
237
|
+
:param int max_candidates: The maximum number of meeting time suggestions to be returned. Optional.
|
|
238
|
+
:param bool is_organizer_optional: Specify True if the organizer doesn't necessarily have to attend.
|
|
239
|
+
The default is false. Optiona
|
|
240
|
+
:param bool return_suggestion_reasons: Specify True to return a reason for each meeting suggestion in
|
|
241
|
+
the suggestionReason property. The default is false to not return that property. Optional.
|
|
242
|
+
:param float minimum_attendee_percentage: The minimum required confidence for a time slot to be returned
|
|
243
|
+
in the response. It is a % value ranging from 0 to 100. Optional.
|
|
148
244
|
"""
|
|
149
245
|
payload = {
|
|
150
246
|
"attendees": ClientValueCollection(AttendeeBase, attendees),
|
|
151
|
-
"locationConstraint": location_constraint
|
|
247
|
+
"locationConstraint": location_constraint,
|
|
248
|
+
"timeConstraint": time_constraint,
|
|
249
|
+
"meeting_duration": meeting_duration,
|
|
250
|
+
"maxCandidates": max_candidates,
|
|
251
|
+
"isOrganizerOptional": is_organizer_optional,
|
|
252
|
+
"returnSuggestionReasons": return_suggestion_reasons,
|
|
253
|
+
"minimumAttendeePercentage": minimum_attendee_percentage
|
|
152
254
|
}
|
|
153
255
|
return_type = ClientResult(self.context, MeetingTimeSuggestionsResult())
|
|
154
256
|
qry = ServiceOperationQuery(self, "findMeetingTimes", None, payload, None, return_type)
|
|
@@ -167,7 +269,6 @@ class User(DirectoryObject):
|
|
|
167
269
|
"""
|
|
168
270
|
return_type = EntityCollection(self.context, Event, ResourcePath("calendarView", self.resource_path))
|
|
169
271
|
qry = ServiceOperationQuery(self, "calendarView", None, None, None, return_type)
|
|
170
|
-
self.context.add_query(qry)
|
|
171
272
|
|
|
172
273
|
def _construct_request(request):
|
|
173
274
|
"""
|
|
@@ -176,7 +277,7 @@ class User(DirectoryObject):
|
|
|
176
277
|
request.method = HttpMethod.Get
|
|
177
278
|
request.url += "?startDateTime={0}&endDateTime={1}".format(start_dt.isoformat(), end_dt.isoformat())
|
|
178
279
|
|
|
179
|
-
self.context.before_execute(_construct_request)
|
|
280
|
+
self.context.add_query(qry).before_execute(_construct_request)
|
|
180
281
|
return return_type
|
|
181
282
|
|
|
182
283
|
def get_reminder_view(self, start_dt, end_dt):
|
|
@@ -269,11 +370,38 @@ class User(DirectoryObject):
|
|
|
269
370
|
self.context.add_query(qry)
|
|
270
371
|
return return_type
|
|
271
372
|
|
|
373
|
+
@property
|
|
374
|
+
def device_enrollment_limit(self):
|
|
375
|
+
"""
|
|
376
|
+
:rtype: str
|
|
377
|
+
"""
|
|
378
|
+
return self.properties.get('deviceEnrollmentLimit', None)
|
|
379
|
+
|
|
380
|
+
@property
|
|
381
|
+
def sign_in_activity(self):
|
|
382
|
+
"""Get the last signed-in date and request ID of the sign-in for a given user. Read-only."""
|
|
383
|
+
return self.properties.get('signInActivity', SignInActivity())
|
|
384
|
+
|
|
272
385
|
@property
|
|
273
386
|
def account_enabled(self):
|
|
274
387
|
"""True if the account is enabled; otherwise, false. This property is required when a user is created."""
|
|
275
388
|
return self.properties.get('accountEnabled', None)
|
|
276
389
|
|
|
390
|
+
@property
|
|
391
|
+
def age_group(self):
|
|
392
|
+
"""
|
|
393
|
+
Gets the age group of the user.
|
|
394
|
+
:rtype: str or None
|
|
395
|
+
"""
|
|
396
|
+
return self.properties.get('ageGroup', None)
|
|
397
|
+
|
|
398
|
+
@property
|
|
399
|
+
def app_role_assignments(self):
|
|
400
|
+
"""Get the apps and app roles which this user has been assigned."""
|
|
401
|
+
return self.properties.get('appRoleAssignments',
|
|
402
|
+
AppRoleAssignmentCollection(self.context,
|
|
403
|
+
ResourcePath("appRoleAssignments", self.resource_path)))
|
|
404
|
+
|
|
277
405
|
@property
|
|
278
406
|
def chats(self):
|
|
279
407
|
"""The user's chats."""
|
|
@@ -355,6 +483,11 @@ class User(DirectoryObject):
|
|
|
355
483
|
"""
|
|
356
484
|
return self.properties.get('otherMails', StringCollection())
|
|
357
485
|
|
|
486
|
+
@property
|
|
487
|
+
def interests(self):
|
|
488
|
+
"""A list for the user to describe their interests."""
|
|
489
|
+
return self.properties.get("interests", StringCollection())
|
|
490
|
+
|
|
358
491
|
@property
|
|
359
492
|
def identities(self):
|
|
360
493
|
"""Represents the identities that can be used to sign in to this user account.
|
|
@@ -387,7 +520,7 @@ class User(DirectoryObject):
|
|
|
387
520
|
|
|
388
521
|
@property
|
|
389
522
|
def insights(self):
|
|
390
|
-
""""""
|
|
523
|
+
"""Insights are relationships calculated using advanced analytics and machine learning techniques."""
|
|
391
524
|
return self.properties.get('insights',
|
|
392
525
|
OfficeGraphInsights(self.context, ResourcePath("insights", self.resource_path)))
|
|
393
526
|
|
|
@@ -420,8 +553,6 @@ class User(DirectoryObject):
|
|
|
420
553
|
def mailbox_settings(self):
|
|
421
554
|
"""
|
|
422
555
|
Get the user's mailboxSettings.
|
|
423
|
-
|
|
424
|
-
:rtype: str or None
|
|
425
556
|
"""
|
|
426
557
|
return self.properties.get('mailboxSettings', MailboxSettings())
|
|
427
558
|
|
|
@@ -463,8 +594,7 @@ class User(DirectoryObject):
|
|
|
463
594
|
"""Get a contact collection from the default Contacts folder of the signed-in user (.../me/contacts),
|
|
464
595
|
or from the specified contact folder."""
|
|
465
596
|
return self.properties.get('contacts',
|
|
466
|
-
|
|
467
|
-
ResourcePath("contacts", self.resource_path)))
|
|
597
|
+
ContactCollection(self.context, ResourcePath("contacts", self.resource_path)))
|
|
468
598
|
|
|
469
599
|
@property
|
|
470
600
|
def contact_folders(self):
|
|
@@ -512,10 +642,29 @@ class User(DirectoryObject):
|
|
|
512
642
|
DeltaCollection(self.context, OAuth2PermissionGrant,
|
|
513
643
|
ResourcePath("oauth2PermissionGrants", self.resource_path)))
|
|
514
644
|
|
|
645
|
+
@property
|
|
646
|
+
def on_premises_distinguished_name(self):
|
|
647
|
+
"""
|
|
648
|
+
Contains the on-premises Active Directory distinguished name or DN. The property is only populated for
|
|
649
|
+
customers who are synchronizing their on-premises directory to Azure Active Directory via Azure AD Connect
|
|
650
|
+
:rtype: str
|
|
651
|
+
"""
|
|
652
|
+
return self.properties.get('onPremisesDistinguishedName', None)
|
|
653
|
+
|
|
654
|
+
@property
|
|
655
|
+
def on_premises_domain_name(self):
|
|
656
|
+
"""
|
|
657
|
+
Contains the on-premises domainFQDN, also called dnsDomainName synchronized from the on-premises directory.
|
|
658
|
+
The property is only populated for customers who are synchronizing their on-premises directory to
|
|
659
|
+
Azure Active Directory via Azure AD Connect.
|
|
660
|
+
:rtype: str
|
|
661
|
+
"""
|
|
662
|
+
return self.properties.get('onPremisesDomainName', None)
|
|
663
|
+
|
|
515
664
|
@property
|
|
516
665
|
def owned_devices(self):
|
|
517
|
-
"""Devices that are owned by the user. Read-only. Nullable.
|
|
518
|
-
(/$count eq 0, /$count ne 0, /$count eq 1, /$count ne 1). """
|
|
666
|
+
"""Devices that are owned by the user. Read-only. Nullable.
|
|
667
|
+
Supports $expand and $filter (/$count eq 0, /$count ne 0, /$count eq 1, /$count ne 1). """
|
|
519
668
|
return self.properties.get('ownedDevices',
|
|
520
669
|
DirectoryObjectCollection(self.context,
|
|
521
670
|
ResourcePath("ownedDevices", self.resource_path)))
|
|
@@ -527,6 +676,18 @@ class User(DirectoryObject):
|
|
|
527
676
|
DirectoryObjectCollection(self.context,
|
|
528
677
|
ResourcePath("ownedObjects", self.resource_path)))
|
|
529
678
|
|
|
679
|
+
@property
|
|
680
|
+
def proxy_addresses(self):
|
|
681
|
+
"""
|
|
682
|
+
For example: ["SMTP: bob@contoso.com", "smtp: bob@sales.contoso.com"]. Changes to the mail property will
|
|
683
|
+
also update this collection to include the value as an SMTP address. For more information, see mail and
|
|
684
|
+
proxyAddresses properties. The proxy address prefixed with SMTP (capitalized) is the primary proxy address
|
|
685
|
+
while those prefixed with smtp are the secondary proxy addresses. For Azure AD B2C accounts, this
|
|
686
|
+
property has a limit of ten unique addresses. Read-only in Microsoft Graph; you can update this property
|
|
687
|
+
only through the Microsoft 365 admin center. Not nullable.
|
|
688
|
+
"""
|
|
689
|
+
return self.properties.get('proxyAddresses', StringCollection())
|
|
690
|
+
|
|
530
691
|
@property
|
|
531
692
|
def transitive_member_of(self):
|
|
532
693
|
"""Get groups, directory roles that the user is a member of. This API request is transitive, and will also
|
|
@@ -591,12 +752,55 @@ class User(DirectoryObject):
|
|
|
591
752
|
OnlineMeetingCollection(self.context,
|
|
592
753
|
ResourcePath("onlineMeetings", self.resource_path)))
|
|
593
754
|
|
|
755
|
+
@property
|
|
756
|
+
def password_policies(self):
|
|
757
|
+
"""
|
|
758
|
+
Specifies password policies for the user. This value is an enumeration with one possible value being
|
|
759
|
+
DisableStrongPassword, which allows weaker passwords than the default policy to be specified.
|
|
760
|
+
DisablePasswordExpiration can also be specified. The two may be specified together; for example:
|
|
761
|
+
DisablePasswordExpiration, DisableStrongPassword.
|
|
762
|
+
:rtype: str
|
|
763
|
+
"""
|
|
764
|
+
return self.properties.get('passwordPolicies', None)
|
|
765
|
+
|
|
766
|
+
@property
|
|
767
|
+
def password_profile(self):
|
|
768
|
+
"""
|
|
769
|
+
Specifies the password profile for the user. The profile contains the user's password.
|
|
770
|
+
This property is required when a user is created. The password in the profile must satisfy minimum
|
|
771
|
+
requirements as specified by the passwordPolicies property. By default, a strong password is required.
|
|
772
|
+
"""
|
|
773
|
+
return self.properties.get('passwordProfile', PasswordProfile())
|
|
774
|
+
|
|
594
775
|
@property
|
|
595
776
|
def presence(self):
|
|
596
777
|
"""Get a user's presence information."""
|
|
597
778
|
return self.properties.get('presence',
|
|
598
779
|
Presence(self.context, ResourcePath("presence", self.resource_path)))
|
|
599
780
|
|
|
781
|
+
@property
|
|
782
|
+
def registered_devices(self):
|
|
783
|
+
"""Get the devices that are registered for the user from the registeredDevices navigation property."""
|
|
784
|
+
return self.properties.get('registeredDevices',
|
|
785
|
+
DirectoryObjectCollection(self.context,
|
|
786
|
+
ResourcePath("registeredDevices", self.resource_path)))
|
|
787
|
+
|
|
788
|
+
@property
|
|
789
|
+
def street_address(self):
|
|
790
|
+
"""
|
|
791
|
+
The street address of the user's place of business. Maximum length is 1024 characters.
|
|
792
|
+
:rtype: str
|
|
793
|
+
"""
|
|
794
|
+
return self.properties.get('streetAddress', None)
|
|
795
|
+
|
|
796
|
+
@property
|
|
797
|
+
def security_identifier(self):
|
|
798
|
+
"""
|
|
799
|
+
Security identifier (SID) of the user, used in Windows scenarios.
|
|
800
|
+
:rtype: str
|
|
801
|
+
"""
|
|
802
|
+
return self.properties.get('securityIdentifier', None)
|
|
803
|
+
|
|
600
804
|
@property
|
|
601
805
|
def teamwork(self):
|
|
602
806
|
"""A container for the range of Microsoft Teams functionalities that are available per user in the tenant."""
|
|
@@ -609,12 +813,30 @@ class User(DirectoryObject):
|
|
|
609
813
|
return self.properties.get('todo',
|
|
610
814
|
Todo(self.context, ResourcePath("todo", self.resource_path)))
|
|
611
815
|
|
|
816
|
+
@property
|
|
817
|
+
def employee_experience(self):
|
|
818
|
+
"""Represents the To Do services available to a user."""
|
|
819
|
+
return self.properties.get('employeeExperience',
|
|
820
|
+
EmployeeExperienceUser(self.context,
|
|
821
|
+
ResourcePath("employeeExperience", self.resource_path)))
|
|
822
|
+
|
|
823
|
+
@property
|
|
824
|
+
def usage_location(self):
|
|
825
|
+
"""
|
|
826
|
+
A two letter country code (ISO standard 3166). Required for users that will be assigned licenses due to
|
|
827
|
+
legal requirement to check for availability of services in countries. Examples include: US, JP, and GB.
|
|
828
|
+
:rtype: str
|
|
829
|
+
"""
|
|
830
|
+
return self.properties.get('usageLocation', None)
|
|
831
|
+
|
|
612
832
|
def get_property(self, name, default_value=None):
|
|
613
833
|
if default_value is None:
|
|
614
834
|
property_mapping = {
|
|
835
|
+
"appRoleAssignments": self.app_role_assignments,
|
|
615
836
|
"businessPhones": self.business_phones,
|
|
616
837
|
"calendarGroups": self.calendar_groups,
|
|
617
838
|
"contactFolders": self.contact_folders,
|
|
839
|
+
"employeeExperience": self.employee_experience,
|
|
618
840
|
"followedSites": self.followed_sites,
|
|
619
841
|
"licenseDetails": self.license_details,
|
|
620
842
|
"managedDevices": self.managed_devices,
|
|
@@ -628,7 +850,10 @@ class User(DirectoryObject):
|
|
|
628
850
|
"onlineMeetings": self.online_meetings,
|
|
629
851
|
"oauth2PermissionGrants": self.oauth2_permission_grants,
|
|
630
852
|
"ownedDevices": self.owned_devices,
|
|
631
|
-
"ownedObjects": self.owned_objects
|
|
853
|
+
"ownedObjects": self.owned_objects,
|
|
854
|
+
"passwordProfile": self.password_profile,
|
|
855
|
+
"registeredDevices": self.registered_devices,
|
|
856
|
+
"signInActivity": self.sign_in_activity
|
|
632
857
|
}
|
|
633
858
|
default_value = property_mapping.get(name, None)
|
|
634
859
|
return super(User, self).get_property(name, default_value)
|
office365/entity.py
CHANGED
|
@@ -51,9 +51,9 @@ class Entity(ClientObject):
|
|
|
51
51
|
if name == self.property_ref_name:
|
|
52
52
|
if self._resource_path is None:
|
|
53
53
|
if isinstance(self.parent_collection.resource_path, EntityPath):
|
|
54
|
-
self._resource_path = self.parent_collection.resource_path.
|
|
54
|
+
self._resource_path = self.parent_collection.resource_path.patch(value)
|
|
55
55
|
else:
|
|
56
56
|
self._resource_path = ResourcePath(value, self.parent_collection.resource_path)
|
|
57
|
-
|
|
58
|
-
self._resource_path.
|
|
57
|
+
else:
|
|
58
|
+
self._resource_path.patch(value, inplace=True)
|
|
59
59
|
return self
|
office365/graph_client.py
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
from office365.booking.solutions_root import SolutionsRoot
|
|
1
2
|
from office365.communications.cloud_communications import CloudCommunications
|
|
2
3
|
from office365.delta_collection import DeltaCollection
|
|
3
4
|
from office365.directory.applications.collection import ApplicationCollection
|
|
@@ -10,7 +11,8 @@ from office365.directory.groups.lifecycle_policy import GroupLifecyclePolicy
|
|
|
10
11
|
from office365.directory.groups.setting_template import GroupSettingTemplate
|
|
11
12
|
from office365.directory.identities.container import IdentityContainer
|
|
12
13
|
from office365.directory.identities.governance import IdentityGovernance
|
|
13
|
-
from office365.directory.
|
|
14
|
+
from office365.directory.protection.information import InformationProtection
|
|
15
|
+
from office365.directory.protection.root import IdentityProtectionRoot
|
|
14
16
|
from office365.directory.identities.provider import IdentityProvider
|
|
15
17
|
from office365.directory.internal.paths.me import MePath
|
|
16
18
|
from office365.directory.invitations.collection import InvitationCollection
|
|
@@ -18,17 +20,18 @@ from office365.directory.licenses.subscribed_sku import SubscribedSku
|
|
|
18
20
|
from office365.directory.object_collection import DirectoryObjectCollection
|
|
19
21
|
from office365.directory.permissions.grants.resource_specific import ResourceSpecificPermissionGrant
|
|
20
22
|
from office365.directory.policies.root import PolicyRoot
|
|
21
|
-
from office365.directory.
|
|
22
|
-
from office365.directory.
|
|
23
|
+
from office365.directory.rolemanagement.management import RoleManagement
|
|
24
|
+
from office365.directory.rolemanagement.role import DirectoryRole
|
|
23
25
|
from office365.directory.security.security import Security
|
|
24
26
|
from office365.directory.serviceprincipals.collection import ServicePrincipalCollection
|
|
27
|
+
from office365.directory.tenant_relationship import TenantRelationship
|
|
25
28
|
from office365.directory.users.collection import UserCollection
|
|
26
29
|
from office365.directory.users.user import User
|
|
27
30
|
from office365.education.root import EducationRoot
|
|
28
31
|
from office365.entity_collection import EntityCollection
|
|
29
|
-
from office365.external.external import External
|
|
32
|
+
from office365.search.external.external import External
|
|
30
33
|
from office365.intune.devices.app_management import DeviceAppManagement
|
|
31
|
-
from office365.intune.devices.management import DeviceManagement
|
|
34
|
+
from office365.intune.devices.management.management import DeviceManagement
|
|
32
35
|
from office365.intune.organizations.contact import OrgContact
|
|
33
36
|
from office365.intune.organizations.organization import Organization
|
|
34
37
|
from office365.onedrive.admin import Admin
|
|
@@ -48,7 +51,8 @@ from office365.runtime.paths.resource_path import ResourcePath
|
|
|
48
51
|
from office365.runtime.queries.delete_entity import DeleteEntityQuery
|
|
49
52
|
from office365.runtime.queries.update_entity import UpdateEntityQuery
|
|
50
53
|
from office365.search.entity import SearchEntity
|
|
51
|
-
from office365.subscriptions.
|
|
54
|
+
from office365.subscriptions.collection import SubscriptionCollection
|
|
55
|
+
from office365.teams.apps.catalog import AppCatalogs
|
|
52
56
|
from office365.teams.chats.collection import ChatCollection
|
|
53
57
|
from office365.teams.collection import TeamCollection
|
|
54
58
|
from office365.teams.template import TeamsTemplate
|
|
@@ -116,6 +120,11 @@ class GraphClient(ClientRuntimeContext):
|
|
|
116
120
|
"""A container for administrator functionality for SharePoint and OneDrive."""
|
|
117
121
|
return Admin(self, ResourcePath("admin"))
|
|
118
122
|
|
|
123
|
+
@property
|
|
124
|
+
def app_catalogs(self):
|
|
125
|
+
"""A container for apps from the Microsoft Teams app catalog."""
|
|
126
|
+
return AppCatalogs(self, ResourcePath("appCatalogs"))
|
|
127
|
+
|
|
119
128
|
@property
|
|
120
129
|
def me(self):
|
|
121
130
|
"""The Me endpoint is provided as a shortcut for specifying the current user"""
|
|
@@ -156,6 +165,7 @@ class GraphClient(ClientRuntimeContext):
|
|
|
156
165
|
"""Get invitations"""
|
|
157
166
|
return InvitationCollection(self, ResourcePath("invitations"))
|
|
158
167
|
|
|
168
|
+
@property
|
|
159
169
|
def identity_protection(self):
|
|
160
170
|
return IdentityProtectionRoot(self, ResourcePath("identityProtection"))
|
|
161
171
|
|
|
@@ -204,8 +214,15 @@ class GraphClient(ClientRuntimeContext):
|
|
|
204
214
|
"""Represents a directory roles in the directory"""
|
|
205
215
|
return DeltaCollection(self, DirectoryRole, ResourcePath("directoryRoles"))
|
|
206
216
|
|
|
217
|
+
@property
|
|
218
|
+
def directory_role_templates(self):
|
|
219
|
+
"""Represents a directory role templates in the directory"""
|
|
220
|
+
from office365.directory.rolemanagement.template import DirectoryRoleTemplate
|
|
221
|
+
return EntityCollection(self, DirectoryRoleTemplate, ResourcePath("directoryRoleTemplates"))
|
|
222
|
+
|
|
207
223
|
@property
|
|
208
224
|
def identity_providers(self):
|
|
225
|
+
""""""
|
|
209
226
|
return EntityCollection(self, IdentityProvider, ResourcePath("identityProviders"))
|
|
210
227
|
|
|
211
228
|
@property
|
|
@@ -234,14 +251,20 @@ class GraphClient(ClientRuntimeContext):
|
|
|
234
251
|
|
|
235
252
|
@property
|
|
236
253
|
def subscribed_skus(self):
|
|
237
|
-
"""
|
|
254
|
+
"""Get the list of commercial subscriptions that an organization has acquired"""
|
|
238
255
|
return EntityCollection(self, SubscribedSku, ResourcePath("subscribedSkus"))
|
|
239
256
|
|
|
240
257
|
@property
|
|
241
258
|
def group_lifecycle_policies(self):
|
|
242
|
-
""""""
|
|
259
|
+
"""A collection of lifecycle policies for a Microsoft 365 groups."""
|
|
243
260
|
return EntityCollection(self, GroupLifecyclePolicy, ResourcePath("groupLifecyclePolicies"))
|
|
244
261
|
|
|
262
|
+
@property
|
|
263
|
+
def group_settings(self):
|
|
264
|
+
"""Represents a directory roles in the directory"""
|
|
265
|
+
from office365.directory.groups.setting import GroupSetting
|
|
266
|
+
return GroupSetting(self, ResourcePath("groupSettings"))
|
|
267
|
+
|
|
245
268
|
@property
|
|
246
269
|
def communications(self):
|
|
247
270
|
"""
|
|
@@ -256,13 +279,31 @@ class GraphClient(ClientRuntimeContext):
|
|
|
256
279
|
"""
|
|
257
280
|
return IdentityGovernance(self, ResourcePath("identityGovernance"))
|
|
258
281
|
|
|
282
|
+
@property
|
|
283
|
+
def information_protection(self):
|
|
284
|
+
"""
|
|
285
|
+
Exposes methods that you can use to get Microsoft Purview Information Protection labels and label policies.
|
|
286
|
+
"""
|
|
287
|
+
return InformationProtection(self, ResourcePath("informationProtection"))
|
|
288
|
+
|
|
259
289
|
@property
|
|
260
290
|
def subscriptions(self):
|
|
261
291
|
"""
|
|
262
292
|
Retrieve the properties and relationships of webhook subscriptions,
|
|
263
293
|
based on the app ID, the user, and the user's role with a tenant.
|
|
264
294
|
"""
|
|
265
|
-
return
|
|
295
|
+
return SubscriptionCollection(self, ResourcePath("subscriptions"))
|
|
296
|
+
|
|
297
|
+
@property
|
|
298
|
+
def connections(self):
|
|
299
|
+
"""Get a list of the externalConnection objects and their properties."""
|
|
300
|
+
from office365.search.external.connection import ExternalConnection
|
|
301
|
+
return EntityCollection(self, ExternalConnection, ResourcePath("connections"))
|
|
302
|
+
|
|
303
|
+
@property
|
|
304
|
+
def tenant_relationships(self):
|
|
305
|
+
"""Represent the various type of tenant relationships."""
|
|
306
|
+
return TenantRelationship(self, ResourcePath("tenantRelationships"))
|
|
266
307
|
|
|
267
308
|
@property
|
|
268
309
|
def audit_logs(self):
|
|
@@ -280,15 +321,18 @@ class GraphClient(ClientRuntimeContext):
|
|
|
280
321
|
|
|
281
322
|
@property
|
|
282
323
|
def reports(self):
|
|
283
|
-
"""
|
|
284
|
-
The resource that represents an instance of History Reports.
|
|
285
|
-
"""
|
|
324
|
+
"""Represents a container for Azure Active Directory (Azure AD) reporting resources."""
|
|
286
325
|
return ReportRoot(self, ResourcePath("reports"))
|
|
287
326
|
|
|
288
327
|
@property
|
|
289
328
|
def role_management(self):
|
|
329
|
+
"""Represents a Microsoft 365 role-based access control (RBAC) role management container"""
|
|
290
330
|
return RoleManagement(self, ResourcePath("roleManagement"))
|
|
291
331
|
|
|
332
|
+
@property
|
|
333
|
+
def solutions(self):
|
|
334
|
+
return SolutionsRoot(self, ResourcePath("solutions"))
|
|
335
|
+
|
|
292
336
|
@property
|
|
293
337
|
def teams_templates(self):
|
|
294
338
|
"""
|
|
@@ -311,6 +355,14 @@ class GraphClient(ClientRuntimeContext):
|
|
|
311
355
|
"""
|
|
312
356
|
return EntityCollection(self, ResourceSpecificPermissionGrant, ResourcePath("permissionGrants"))
|
|
313
357
|
|
|
358
|
+
@property
|
|
359
|
+
def print(self):
|
|
360
|
+
"""
|
|
361
|
+
Used to manage printers and print jobs within Universal Print.
|
|
362
|
+
"""
|
|
363
|
+
from office365.intune.printing.print import Print
|
|
364
|
+
return Print(self, ResourcePath("print"))
|
|
365
|
+
|
|
314
366
|
@property
|
|
315
367
|
def search(self):
|
|
316
368
|
"""
|