CmdID

CmdID / PowerShell / Cmdlets / New

New-MgUser

Create a new user.\rThe request body contains the user to create. Microsoft Graph PowerShell reference

From the Microsoft Graph PowerShell reference 150 parameters Its page in the reference

Opens CmdID with your command, read as PowerShell. It is read in your browser and sent nowhere.

Parameters

150 in the Microsoft Graph PowerShell reference
Show its 150 parameters
-AboutMeA freeform text entry field for the user to describe themselves.
-AccountEnabledtrue if the account is enabled; otherwise, false.
-ActivitiesThe user's activities across devices.
-AdditionalPropertiesAdditional Parameters
-AdhocCallsAd hoc calls associated with the user.
-AgeGroupSets the age group of the user.
-AgreementAcceptancesThe user's terms of use acceptance statuses.
-AppRoleAssignmentsRepresents the app roles a user is granted for an application.
-AssignedLicensesThe licenses that are assigned to the user, including inherited (group-based) licenses.
-AssignedPlansThe plans that are assigned to the user.
-Authenticationauthentication To construct, see NOTES section for AUTHENTICATION properties and create a hash table.
-AuthorizationInfoauthorizationInfo To construct, see NOTES section for AUTHORIZATIONINFO properties and create a hash table.
-BirthdayThe birthday of the user.
-BodyParameteruser To construct, see NOTES section for BODYPARAMETER properties and create a hash table.
-BreakWait for .NET debugger to attach
-BusinessPhonesThe telephone numbers for the user.
-Calendarcalendar To construct, see NOTES section for CALENDAR properties and create a hash table.
-CalendarGroupsThe user's calendar groups.
-CalendarsThe user's calendars.
-CalendarViewThe calendar view for the calendar.
-ChatsTo construct, see NOTES section for CHATS properties and create a hash table.
-CityThe city where the user is located.
-CloudClipboardcloudClipboardRoot To construct, see NOTES section for CLOUDCLIPBOARD properties and create a hash table.
-CloudPCsThe user's Cloud PCs.
-CompanyNameThe name of the company that the user is associated with.
-Confirm, -cfPrompts you for confirmation before running the cmdlet.
-ConsentProvidedForMinorSets whether consent was obtained for minors.
-ContactFoldersThe user's contacts folders.
-ContactsThe user's contacts.
-CountryThe country or region where the user is located; for example, US or UK.
-CreatedDateTimeThe date and time the user was created, in ISO 8601 format and UTC.
-CreatedObjectsDirectory objects that the user created.
-CreationTypeIndicates whether the user account was created through one of the following methods: As a regular school or work account (null).
-CustomSecurityAttributescustomSecurityAttributeValue
-DataSecurityAndGovernanceuserDataSecurityAndGovernance To construct, see NOTES section for DATASECURITYANDGOVERNANCE properties and create a hash table.
-DeletedDateTimeDate and time when this object was deleted.
-DepartmentThe name of the department in which the user works.
-DeviceEnrollmentLimitThe limit on the maximum number of devices that the user is permitted to enroll.
-DeviceManagementTroubleshootingEventsThe list of troubleshooting events for this user.
-DirectReportsThe users and contacts that report to the user.
-DisplayNameThe name displayed in the address book for the user.
-Drivedrive To construct, see NOTES section for DRIVE properties and create a hash table.
-DrivesA collection of drives available for this user.
-EmployeeExperienceemployeeExperienceUser To construct, see NOTES section for EMPLOYEEEXPERIENCE properties and create a hash table.
-EmployeeHireDateThe date and time when the user was hired or will start work in a future hire.
-EmployeeIdThe employee identifier assigned to the user by the organization.
-EmployeeLeaveDateTimeThe date and time when the user left or will leave the organization.
-EmployeeOrgDataemployeeOrgData To construct, see NOTES section for EMPLOYEEORGDATA properties and create a hash table.
-EmployeeTypeCaptures enterprise worker type.
-EventsThe user's events.
-ExtensionsThe collection of open extensions defined for the user.
-ExternalUserStateFor a guest invited to the tenant using the invitation API, this property represents the invited user's invitation status.
-ExternalUserStateChangeDateTimeShows the timestamp for the latest change to the externalUserState property.
-FaxNumberThe fax number of the user.
-FollowedSitesTo construct, see NOTES section for FOLLOWEDSITES properties and create a hash table.
-GivenNameThe given name (first name) of the user.
-HeadersOptional headers that will be added to the request.
-HireDateThe hire date of the user.
-HttpPipelineAppendSendAsync Pipeline Steps to be appended to the front of the pipeline
-HttpPipelinePrependSendAsync Pipeline Steps to be prepended to the front of the pipeline
-IdThe unique identifier for an entity.
-IdentitiesRepresents the identities that can be used to sign in to this user account.
-IdentityParentId
-ImAddressesThe instant message voice-over IP (VOIP) session initiation protocol (SIP) addresses for the user.
-InferenceClassificationinferenceClassification To construct, see NOTES section for INFERENCECLASSIFICATION properties and create a hash table.
-InsightsitemInsights
-InterestsA list for the user to describe their interests.
-IsManagementRestrictedtrue if the user is a member of a restricted management administrative unit.
-IsResourceAccountDon't use – reserved for future use.
-JobTitleThe user's job title.
-JoinedTeamsTo construct, see NOTES section for JOINEDTEAMS properties and create a hash table.
-LastPasswordChangeDateTimeThe time when this Microsoft Entra user last changed their password or when their password was created, whichever date the latest action was performed.
-LegalAgeGroupClassificationUsed by enterprise applications to determine the legal age group of the user.
-LicenseAssignmentStatesState of license assignments for this user.
-LicenseDetailsA collection of this user's license details.
-MailThe SMTP address for the user, for example, jeff@contoso.com.
-MailboxSettingsmailboxSettings To construct, see NOTES section for MAILBOXSETTINGS properties and create a hash table.
-MailFoldersThe user's mail folders.
-MailNicknameThe mail alias for the user.
-ManagedAppRegistrationsZero or more managed app registrations that belong to the user.
-ManagedDevicesThe managed devices associated with the user.
-ManagerdirectoryObject To construct, see NOTES section for MANAGER properties and create a hash table.
-MemberOfThe groups and directory roles that the user is a member of.
-MessagesThe messages in a mailbox or folder.
-MobilePhoneThe primary cellular telephone number for the user.
-MySiteThe URL for the user's site.
-NotesThe notes in the user's Notes folder.
-Oauth2PermissionGrantsTo construct, see NOTES section for OAUTH2PERMISSIONGRANTS properties and create a hash table.
-OfficeLocationThe office location in the user's place of business.
-Onenoteonenote To construct, see NOTES section for ONENOTE properties and create a hash table.
-OnlineMeetingsInformation about a meeting, including the URL used to join a meeting, the attendees list, and the description.
-OnPremisesDistinguishedNameContains the on-premises Active Directory distinguished name or DN.
-OnPremisesDomainNameContains the on-premises domainFQDN, also called dnsDomainName synchronized from the on-premises directory.
-OnPremisesExtensionAttributesonPremisesExtensionAttributes To construct, see NOTES section for ONPREMISESEXTENSIONATTRIBUTES properties and create a hash table.
-OnPremisesImmutableIdThis property is used to associate an on-premises Active Directory user account to their Microsoft Entra user object.
-OnPremisesLastSyncDateTimeIndicates the last time at which the object was synced with the on-premises directory; for example: 2013-02-16T03:04:54Z.
-OnPremisesProvisioningErrorsErrors when using Microsoft synchronization product during provisioning.
-OnPremisesSamAccountNameContains the on-premises samAccountName synchronized from the on-premises directory.
-OnPremisesSecurityIdentifierContains the on-premises security identifier (SID) for the user that was synchronized from on-premises to the cloud.
-OnPremisesSyncBehavioronPremisesSyncBehavior To construct, see NOTES section for ONPREMISESSYNCBEHAVIOR properties and create a hash table.
-OnPremisesSyncEnabledtrue if this user object is currently being synced from an on-premises Active Directory (AD); otherwise the user isn't being synced and can be managed in Microsoft Entra ID.
-OnPremisesUserPrincipalNameContains the on-premises userPrincipalName synchronized from the on-premises directory.
-OtherMailsA list of other email addresses for the user; for example: ['bob@contoso.com', 'Robert@fabrikam.com'].
-OutlookoutlookUser To construct, see NOTES section for OUTLOOK properties and create a hash table.
-OwnedDevicesDevices the user owns.
-OwnedObjectsDirectory objects the user owns.
-PasswordPoliciesSpecifies password policies for the user.
-PasswordProfilepasswordProfile To construct, see NOTES section for PASSWORDPROFILE properties and create a hash table.
-PastProjectsA list for the user to enumerate their past projects.
-PeoplePeople that are relevant to the user.
-PermissionGrantsList all resource-specific permission grants of a user.
-PhotoprofilePhoto To construct, see NOTES section for PHOTO properties and create a hash table.
-PhotosThe collection of the user's profile photos in different sizes.
-PlannerplannerUser To construct, see NOTES section for PLANNER properties and create a hash table.
-PostalCodeThe postal code for the user's postal address.
-PreferredDataLocationThe preferred data location for the user.
-PreferredLanguageThe preferred language for the user.
-PreferredNameThe preferred name for the user.
-Presencepresence To construct, see NOTES section for PRESENCE properties and create a hash table.
-PrintuserPrint To construct, see NOTES section for PRINT properties and create a hash table.
-ProvisionedPlansThe plans that are provisioned for the user.
-ProxyThe URI for the proxy server to use
-ProxyAddressesFor example: ['SMTP: bob@contoso.com', 'smtp: bob@sales.contoso.com'].
-ProxyCredentialCredentials for a proxy server to use for the remote call
-ProxyUseDefaultCredentialsUse the default credentials for the proxy
-RegisteredDevicesDevices that are registered for the user.
-ResponseHeadersVariable, -RHVOptional Response Headers Variable.
-ResponsibilitiesA list for the user to enumerate their responsibilities.
-SchoolsA list for the user to enumerate the schools they attended.
-ScopedRoleMemberOfTo construct, see NOTES section for SCOPEDROLEMEMBEROF properties and create a hash table.
-SecurityIdentifierSecurity identifier (SID) of the user, used in Windows scenarios.
-ServiceProvisioningErrorsErrors published by a federated service describing a nontransient, service-specific error regarding the properties or link from a user object.
-SettingsuserSettings To construct, see NOTES section for SETTINGS properties and create a hash table.
-ShowInAddressListDo not use in Microsoft Graph.
-SignInActivitysignInActivity To construct, see NOTES section for SIGNINACTIVITY properties and create a hash table.
-SignInSessionsValidFromDateTimeAny refresh tokens or session tokens (session cookies) issued before this time are invalid.
-SkillsA list for the user to enumerate their skills.
-SolutionsuserSolutionRoot To construct, see NOTES section for SOLUTIONS properties and create a hash table.
-SponsorOfDirectory objects that this user sponsors, such as guest users, agent users, agent blueprints, agent blueprint principals, and agent identities.
-SponsorsThe users and groups responsible for this guest's privileges in the tenant and keeping the guest's information and access updated.
-StateThe state or province in the user's address.
-StreetAddressThe street address of the user's place of business.
-SurnameThe user's surname (family name or last name).
-TeamworkuserTeamwork To construct, see NOTES section for TEAMWORK properties and create a hash table.
-Todotodo To construct, see NOTES section for TODO properties and create a hash table.
-TransitiveMemberOfThe groups, including nested groups, and directory roles that a user is a member of.
-UsageLocationA two-letter country code (ISO standard 3166).
-UserPrincipalNameThe user principal name (UPN) of the user.
-UserTypeA string value that can be used to classify user types in your directory.
-WhatIf, -wiRuns the command in a mode that only reports what would happen without performing the actions.