Skip to content

karamem0/sp-client-core

Repository files navigation

SPClientCore

日本語で見る

SharePoint Service Module for PowerShell

.github/workflows/trigger-on-main.yml codecov License

Installation

SPClientCore is published to PowerShell Gallery.

Features

Works with PowerShell 7

Yes, SPClientCore works with the latest version of PowerShell 7. It means that you can use this module on Mac and Linux as well as Windows (of course if PowerShell 7 is installed on the machine). There was only a way to run the SharePoint REST API to manage SharePoint Online in non-Windows environments. But SharePoint REST API has a few problems compared to the SharePoint Client Library (CSOM). SPClientCore provides full functionality by making compatible API calls with CSOM.

(UPDATE) CSOM and PnP PowerShell now supports PowerShell 7.

One module, manage all

SPClientCore includes both elements that site admin features and tenant admin features. You can run cmdlets for site admin by connecting to a site (https://tenant.sharepoint.com and its sub URLs), and you can run tenant admin cmdlets for connecting to the SharePoint admin center (https://tenant-admin.sharepoint.com). You can also determine whether you are currently connected to the SharePoint admin center.

Friendly Naming

CSOM naming is difficult for non-programmers. For example, A site is not "Site" (that is "Web"), A column is not "Column" (that is "Field"). SPClientCore adjusts the naming so that it matches the name used by the user.

Uses Modern Authentication

SPClientCore supports Microsoft Entra ID 2.0 authentication.

  • Device Code Grant
  • Client Credential Grant
  • Password Grant (DEPRECATED)

If you enable MFA, you can log in with a web browser of another device. If you do not enable MFA, you can log in using your user name and password (admin consent is required). You don't need to log in each time because the credentials are cached.

Dependencies

Cmdlets

  • Login
    • Connect-KshSite
    • Disconnect-KshSite
    • Get-KshCurrentConnection
    • Get-KshCurrentSite
    • Get-KshCurrentSiteCollection
    • Get-KshCurrentUser
    • Get-KshCurrentUserProfile
    • Get-KshCurrentUserProperty
    • Select-KshSite
    • Test-KshTenantSiteCollection
  • Site Administration
    • Alerts
      • Add-KshAlert
      • Get-KshAlert
      • Remove-KshAlert
      • Set-KshAlert
    • App Catalogs
      • Add-KshSiteCollectionAppCatalog
      • Get-KshSiteCollectionAppCatalog
      • Get-KshTenantAppCatalog
      • Remove-KshSiteCollectionAppCatalog
    • App Instances
      • Get-KshAppInstance
    • Apps
      • Add-KshApp
      • Get-KshApp
      • Remove-KshApp
      • Set-KshAppInstalled
      • Set-KshAppPublished
      • Update-KshApp
    • Attachment Files
      • Get-KshAttachmentFile
      • Open-KshAttachmentFile
      • Remove-KshAttachmentFile
      • Save-KshAttachmentFile
    • Changes
      • Get-KshChange
    • Client Components Properties
      • Add-KshStorageEntity
      • Get-KshStorageEntity
      • Remove-KshStorageEntity
    • Columns
      • Add-KshColumnBoolean
      • Add-KshColumnCalculated
      • Add-KshColumnChoice
      • Add-KshColumnCurrency
      • Add-KshColumnDateTime
      • Add-KshColumnGeolocation
      • Add-KshColumnGuid
      • Add-KshColumnImage
      • Add-KshColumnLocation
      • Add-KshColumnLookup
      • Add-KshColumnMultiChoice
      • Add-KshColumnMultiLineText
      • Add-KshColumnNumber
      • Add-KshColumnTaxonomy
      • Add-KshColumnText
      • Add-KshColumnUrl
      • Add-KshColumnUser
      • Get-KshColumn
      • Remove-KshColumn
      • Set-KshColumnBoolean
      • Set-KshColumnCalculated
      • Set-KshColumnChoice
      • Set-KshColumnCurrency
      • Set-KshColumnDateTime
      • Set-KshColumnGeolocation
      • Set-KshColumnGuid
      • Set-KshColumnImage
      • Set-KshColumnLocation
      • Set-KshColumnLookup
      • Set-KshColumnMultiChoice
      • Set-KshColumnMultiLineText
      • Set-KshColumnNumber
      • Set-KshColumnTaxonomy
      • Set-KshColumnText
      • Set-KshColumnUrl
      • Set-KshColumnUser
    • Comments
      • Add-KshComment
      • Get-KshComment
      • Remove-KshComment
      • Set-KshCommentEnabled
    • Content Approvals
      • Set-KshApprovalStatus
    • Content Types
      • Add-KshContentType
      • Add-KshContentTypeColumn
      • Get-KshContentType
      • Get-KshContentTypeColumn
      • New-KshContentTypeId
      • Remove-KshContentType
      • Remove-KshContentTypeColumn
      • Set-KshContentType
      • Set-KshContentTypeColumn
      • Set-KshContentTypeColumnOrder
    • Document Libraries
      • Get-KshDocumentLibrary
    • Document Set Templates
      • Add-KshDocumentSetAllowedContentType
      • Add-KshDocumentSetDefaultDocument
      • Add-KshDocumentSetSharedColumn
      • Add-KshDocumentSetWelcomePageColumn
      • Get-KshDocumentSetAllowedContentType
      • Get-KshDocumentSetDefaultDocument
      • Get-KshDocumentSetSharedColumn
      • Get-KshDocumentSetWelcomePageColumn
      • Remove-KshDocumentSetAllowedContentType
      • Remove-KshDocumentSetDefaultDocument
      • Remove-KshDocumentSetSharedColumn
      • Remove-KshDocumentSetWelcomePageColumn
    • Document Sets
      • Add-KshDocumentSet
    • Documents
      • Add-KshDocument
    • Drive Items
      • Get-KshDriveItem
      • Get-KshSubDriveItem
    • Drives
      • Get-KshDrive
    • External Sharing
      • Get-KshSharingInfo
      • Get-KshSharingSettings
      • Test-KshExternalUserSharing
    • Files
      • Add-KshFile
      • Copy-KshFile
      • Get-KshFile
      • Move-KshFile
      • Open-KshFile
      • Remove-KshFile
      • Save-KshFile
      • Set-KshFileCheckOutStatus
      • Set-KshFilePublished
    • File Versions
      • Get-KshFileVersion
      • Remove-KshFileVersion
      • Restore-KshFileVersion
    • Folders
      • Add-KshFolder
      • Add-KshFolderColoring
      • Copy-KshFolder
      • Get-KshFolder
      • Get-KshSubFolder
      • Move-KshFolder
      • Remove-KshFolder
      • Set-KshFolder
      • Set-KshFolderColoring
    • Groups
      • Add-KshGroup
      • Add-KshGroupMember
      • Get-KshGroup
      • Get-KshGroupMember
      • Get-KshGroupOwner
      • Remove-KshGroup
      • Remove-KshGroupMember
      • Set-KshGroup
      • Set-KshGroupOwner
    • Highlights
      • Add-KshHighlight
      • Remove-KshHighlight
    • Images
      • Save-KshImage
    • Likes
      • Get-KshLike
      • Set-KshLike
    • Lists
      • Add-KshList
      • Get-KshList
      • Remove-KshList
      • Set-KshList
    • List Items
      • Add-KshListItem
      • Get-KshListItem
      • New-KshColumnGeolocationValue
      • New-KshColumnImageValue
      • New-KshColumnLookupValue
      • New-KshColumnTaxonomyValue
      • New-KshColumnUrlValue
      • New-KshColumnUserValue
      • Remove-KshListItem
      • Set-KshColumnTaxonomyValue
      • Set-KshListItem
    • List Templates
      • Get-KshListTemplate
    • Navigation
      • Add-KshNavigationNode
      • Get-KshNavigation
      • Get-KshNavigationNode
      • Remove-KshNavigationNode
      • Set-KshNavigation
      • Set-KshNavigationNode
    • Properties
      • Get-KshProperty
    • Recycle Bin Items
      • Get-KshRecycleBinItem
      • Move-KshRecycleBinItem
      • Remove-KshRecycleBinItem
      • Restore-KshRecycleBinItem
    • Regional Settings
      • ConvertTo-KshLocalTime
      • ConvertTo-KshUniversalTime
      • Get-KshRegionalSettings
      • Set-KshRegionalSettings
      • Set-KshMultilingualEnabled
      • Add-KshSupportedUILanguage
      • Remove-KshSupportedUILanguage
    • Role Assignments
      • Add-KshRoleAssignment
      • Get-KshRoleAssignment
      • Remove-KshRoleAssignment
      • Set-KshUniqueRoleAssignmentEnabled
    • Role Definitions
      • Add-KshRoleDefinition
      • Get-KshRoleDefinition
      • New-KshBasePermission
      • Remove-KshRoleDefinition
      • Set-KshRoleDefinition
    • Sharing Links
      • Add-KshAnonymousLink
      • Add-KshOrganizationSharingLink
      • Remove-KshAnonymousLink
      • Remove-KshOrganizationSharingLink
      • Test-KshSharingLink
    • Sites
      • Add-KshSite
      • Get-KshSite
      • Remove-KshSite
      • Set-KshSite
    • Site Collection Features
      • Add-KshSiteCollectionFeature
      • Get-KshSiteCollectionFeature
      • Remove-KshSiteCollectionFeature
    • Site Features
      • Add-KshSiteFeature
      • Get-KshSiteFeature
      • Remove-KshSiteFeature
    • Site Pages
      • Add-KshSitePage
      • Remove-KshSitePage
      • Set-KshSitePage
    • Site Templates
      • Get-KshSiteTemplate
    • Users
      • Add-KshExternalUser
      • Add-KshUser
      • Get-KshUser
      • Remove-KshUser
      • Resolve-KshUser
      • Set-KshUser
    • User Permissions
      • Get-KshUserPermission
    • User Properties
      • Get-KshUserProperty
    • Views
      • Add-KshView
      • Add-KshViewColumn
      • Get-KshView
      • Get-KshViewColumn
      • Move-KshViewColumn
      • Remove-KshView
      • Remove-KshViewColumn
      • Set-KshView
      • Copy-KshView
    • Webhooks
      • Add-KshSubscription
      • Get-KshSubscription
      • Remove-KshSubscription
      • Set-KshSubscription
  • Tenant Administration
    • Deleted Site Collections
      • Get-KshTenantDeletedPersonalSiteCollection
      • Get-KshTenantDeletedSiteCollection
      • Remove-KshTenantDeletedSiteCollection
      • Restore-KshTenantDeletedSiteCollection
    • File Version Policy
      • Get-KshTenantFileVersionPolicyForDocumentLibrary
      • Set-KshTenantFileVersionPolicy
      • Set-KshTenantFileVersionPolicyForDocumentLibrary
    • Home Site
      • Get-KshTenantHomeSite
      • Remove-KshTenantHomeSite
      • Set-KshTenantHomeSite
    • Hub Sites
      • Add-KshTenantHubSite
      • Get-KshTenantHubSite
      • Remove-KshTenantHubSite
      • Set-KshTenantHubSite
    • List Designs
      • Add-KshTenantListDesign
      • Get-KshTenantListDesign
      • Remove-KshTenantListDesign
    • Office 365 CDN
      • Add-KshTenantCdnOrigin
      • Get-KshTenantCdnEnabled
      • Get-KshTenantCdnOrigin
      • Get-KshTenantCdnPolicy
      • Remove-KshTenantCdnOrigin
      • Set-KshTenantCdnEnabled
      • Set-KshTenantCdnPolicy
    • Organization News Sites
      • Add-KshTenantOrganizationNewsSite
      • Get-KshTenantOrganizationNewsSite
      • Remove-KshTenantOrganizationNewsSite
    • Personal Sites
      • Get-KshTenantPersonalSite
    • Root site
      • Get-KshTenantRootSite
    • Site Collections
      • Add-KshTenantSiteCollection
      • Get-KshSiteCollection
      • Get-KshTenantSiteCollection
      • Lock-KshTenantSiteCollection
      • Remove-KshTenantSiteCollection
      • Set-KshTenantSiteCollection
      • Set-KshTenantSiteCollectionLockStatus
      • Unlock-KshTenantSiteCollection
    • Site Designs
      • Add-KshTenantSiteDesign
      • Get-KshTenantSiteDesign
      • Remove-KshTenantSiteDesign
      • Set-KshTenantSiteDesign
    • Site Scripts
      • Add-KshTenantSiteScript
      • Get-KshTenantSiteScript
      • Get-KshTenantSiteScriptFromList
      • Get-KshTenantSiteScriptFromSite
      • Remove-KshTenantSiteScript
    • Site Templates
      • Get-KshTenantSiteTemplate
    • Tenant
      • Get-KshTenant
      • Set-KshTenant
    • Themes
      • Add-KshTenantTheme
      • Get-KshTenantTheme
      • Remove-KshTenantTheme
      • Set-KshTenantTheme
    • Users
      • Add-KshTenantUser
      • Get-KshTenantExternalUser
      • Get-KshTenantUser
      • Remove-KshTenantExternalUser
      • Remove-KshTenantUser
      • Set-KshTenantUser
  • Managed Metadata
    • Custom Properties
      • Add-KshTermCustomProperty
      • Add-KshTermLocalCustomProperty
      • Remove-KshTermCustomProperty
      • Remove-KshTermLocalCustomProperty
    • Term Groups
      • Add-KshTermGroup
      • Get-KshTermGroup
      • Remove-KshTermGroup
      • Set-KshTermGroup
    • Term Labels
      • Add-KshTermLabel
      • Get-KshTermLabel
      • Remove-KshTermLabel
      • Set-KshTermLabel
    • Term Sets
      • Add-KshTermSet
      • Get-KshTermSet
      • Remove-KshTermSet
      • Set-KshTermSet
    • Term Store
      • Add-KshTermStoreLanguage
      • Get-KshTermStore
      • Remove-KshTermStoreLanguage
      • Set-KshTermStore
    • Terms
      • Add-KshTerm
      • Copy-KshTerm
      • Get-KshTerm
      • Get-KshTermDescription
      • Merge-KshTerm
      • Move-KshTerm
      • Remove-KshTerm
      • Set-KshTerm
      • Set-KshTermDescription
      • Set-KshTermDeprecated

Packages