{"id":837,"date":"2019-01-22T12:59:51","date_gmt":"2019-01-22T12:59:51","guid":{"rendered":"http:\/\/blog.softreeconsulting.com\/?p=837"},"modified":"2019-01-22T12:59:51","modified_gmt":"2019-01-22T12:59:51","slug":"sharepoint-app-operations-using-pnp-powershell","status":"publish","type":"post","link":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/","title":{"rendered":"SharePoint App Operations Using PnP PowerShell"},"content":{"rendered":"<p>PnP PowerShell\u00a0can be used to automate the deployment, publishing, installing, upgrading and retracting apps in <a href=\"http:\/\/www.softreeconsulting.com\/sharepoint-2019\/\">SharePoint online<\/a> as well as SharePoint on-premises.<\/p>\n<p>In this blog, we will look at steps to get, add, install, deploy, update, remove and uninstall SharePoint app to Modern Site using PnP PowerShell.<\/p>\n<p><strong>Adding and publishing app to the app catalog:<\/strong><\/p>\n<p>Adding app (.sppkg file, .app file) to the tenant scoped app catalog.<\/p>\n<p>&#8211;&gt; <span style=\"color: #0000ff;\">Add-PnPApp -Path &lt;App Path&gt; -Scope Tenant<\/span><\/p>\n<p>Once added, need to continue with publishing app using below command.<\/p>\n<p>&#8211;&gt; <span style=\"color: #0000ff;\">Publish-PnPApp -Identity &lt;App Id&gt;<\/span><\/p>\n<p><a href=\"http:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/1.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-838\" src=\"https:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/1.jpg\" alt=\"PnP powershell\" width=\"601\" height=\"116\" \/><\/a><\/p>\n<p><strong>Removing the app from the app catalog:<\/strong><\/p>\n<p>To remove the specified app from the tenant scoped app catalog.<\/p>\n<p>&#8211;&gt; <span style=\"color: #0000ff;\">Remove-PnPApp -Identity &lt;App Id&gt; -Scope Tenant<\/span><\/p>\n<p><a href=\"http:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/2.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-839\" src=\"https:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/2.jpg\" alt=\"Remove-PnPApp\" width=\"601\" height=\"59\" \/><\/a><\/p>\n<p><strong>Gett<\/strong><strong>ing the app from the app catalog:<\/strong><\/p>\n<p>Get a list of apps in the tenant scoped app catalog.<\/p>\n<p>&#8211;&gt; \u00a0<span style=\"color: #0000ff;\">Get-PnPApp -Scope Tenant<\/span><\/p>\n<p><a href=\"http:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/3.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-840\" src=\"https:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/3.jpg\" alt=\"Get-PnPApp\" width=\"601\" height=\"109\" \/><\/a><\/p>\n<p><strong>Installing the app to site collection:<\/strong><\/p>\n<p>After the app is added to the app catalog and published, you can install the app to a specific site.<\/p>\n<p>&#8211;&gt;\u00a0 <span style=\"color: #0000ff;\">Install-PnPApp -Identity &lt;App Id&gt; -Scope Tenant<\/span><\/p>\n<p><a href=\"http:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/4-1.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-842\" src=\"https:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/4-1.jpg\" alt=\"Install-PnPApp\" width=\"979\" height=\"100\" \/><\/a><\/p>\n<p><strong>Upgrading the app:<\/strong><\/p>\n<p>The command used to update an already installed app if a new version is available in the tenant app catalog.<\/p>\n<p>&#8211;&gt; <span style=\"color: #0000ff;\">Update-PnPApp -Identity &lt;App Id&gt; -Scope Tenant<\/span><\/p>\n<p><a href=\"http:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/5.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-843\" src=\"https:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/5.jpg\" alt=\"Update-PnPApp \" width=\"979\" height=\"98\" \/><\/a><\/p>\n<p><strong>Uninstalling the app from site collection:<\/strong><\/p>\n<p>To uninstall the app from your site.<\/p>\n<p>&#8211;&gt; <span style=\"color: #0000ff;\">Uninstall-PnPApp -Identity &lt;app id&gt; -Scope Tenant<\/span><\/p>\n<p><a href=\"http:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/6.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-844\" src=\"https:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/6.jpg\" alt=\"Uninstall-PnPApp\" width=\"979\" height=\"98\" \/><\/a><\/p>\n<p>In above I have explained all operations getting, adding, installing, upgrading, removing and uninstalling <a href=\"http:\/\/www.softreeconsulting.com\/\">SharePoint app<\/a> on SharePoint modern site programmatically, using PnP PowerShell commands.<\/p>\n<p><strong>This solution is brought to you by our SharePoint professionals&#8230;..<\/strong><\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>PnP PowerShell\u00a0can be used to automate the deployment, publishing, installing, upgrading and retracting apps in SharePoint online as well as SharePoint on-premises. In this blog, we will look at steps to get, add, install, deploy, update, remove and uninstall SharePoint app to Modern Site using PnP PowerShell. Adding and publishing app to the app catalog: Adding app (.sppkg file, .app [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[43],"tags":[208,159],"class_list":["post-837","post","type-post","status-publish","format-standard","hentry","category-sharepoint","tag-pnp-powershell","tag-sharepoint-online"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.6 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>SharePoint App Operations Using PnP PowerShell - Softree Technology<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"SharePoint App Operations Using PnP PowerShell - Softree Technology\" \/>\n<meta property=\"og:description\" content=\"PnP PowerShell\u00a0can be used to automate the deployment, publishing, installing, upgrading and retracting apps in SharePoint online as well as SharePoint on-premises. In this blog, we will look at steps to get, add, install, deploy, update, remove and uninstall SharePoint app to Modern Site using PnP PowerShell. Adding and publishing app to the app catalog: Adding app (.sppkg file, .app [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/\" \/>\n<meta property=\"og:site_name\" content=\"Softree Technology\" \/>\n<meta property=\"article:published_time\" content=\"2019-01-22T12:59:51+00:00\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"SharePoint App Operations Using PnP PowerShell - Softree Technology","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/","og_locale":"en_US","og_type":"article","og_title":"SharePoint App Operations Using PnP PowerShell - Softree Technology","og_description":"PnP PowerShell\u00a0can be used to automate the deployment, publishing, installing, upgrading and retracting apps in SharePoint online as well as SharePoint on-premises. In this blog, we will look at steps to get, add, install, deploy, update, remove and uninstall SharePoint app to Modern Site using PnP PowerShell. Adding and publishing app to the app catalog: Adding app (.sppkg file, .app [&hellip;]","og_url":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/","og_site_name":"Softree Technology","article_published_time":"2019-01-22T12:59:51+00:00","author":"admin","twitter_card":"summary_large_image","twitter_misc":{"Written by":"admin","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/#article","isPartOf":{"@id":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/"},"author":{"name":"admin","@id":"https:\/\/softreetechnology.com\/blog\/#\/schema\/person\/98740297642f06debccdcee2de84086b"},"headline":"SharePoint App Operations Using PnP PowerShell","datePublished":"2019-01-22T12:59:51+00:00","mainEntityOfPage":{"@id":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/"},"wordCount":283,"commentCount":0,"publisher":{"@id":"https:\/\/softreetechnology.com\/blog\/#organization"},"image":{"@id":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/#primaryimage"},"thumbnailUrl":"https:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/1.jpg","keywords":["PnP PowerShell","SharePoint Online"],"articleSection":["SharePoint"],"inLanguage":"en","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/","url":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/","name":"SharePoint App Operations Using PnP PowerShell - Softree Technology","isPartOf":{"@id":"https:\/\/softreetechnology.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/#primaryimage"},"image":{"@id":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/#primaryimage"},"thumbnailUrl":"https:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/1.jpg","datePublished":"2019-01-22T12:59:51+00:00","breadcrumb":{"@id":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/#breadcrumb"},"inLanguage":"en","potentialAction":[{"@type":"ReadAction","target":["https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/"]}]},{"@type":"ImageObject","inLanguage":"en","@id":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/#primaryimage","url":"https:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/1.jpg","contentUrl":"https:\/\/blog.softreeconsulting.com\/wp-content\/uploads\/2019\/01\/1.jpg"},{"@type":"BreadcrumbList","@id":"https:\/\/softreetechnology.com\/blog\/sharepoint\/sharepoint-app-operations-using-pnp-powershell\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/softreetechnology.com\/blog\/"},{"@type":"ListItem","position":2,"name":"SharePoint App Operations Using PnP PowerShell"}]},{"@type":"WebSite","@id":"https:\/\/softreetechnology.com\/blog\/#website","url":"https:\/\/softreetechnology.com\/blog\/","name":"Softree Technology","description":"Celebrating 10+ Years in SharePoint Consulting !","publisher":{"@id":"https:\/\/softreetechnology.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/softreetechnology.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en"},{"@type":"Organization","@id":"https:\/\/softreetechnology.com\/blog\/#organization","name":"Softree Technology","url":"https:\/\/softreetechnology.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en","@id":"https:\/\/softreetechnology.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/softreetechnology.com\/blog\/wp-content\/uploads\/2023\/03\/cropped-white-logo-soft.png","contentUrl":"https:\/\/softreetechnology.com\/blog\/wp-content\/uploads\/2023\/03\/cropped-white-logo-soft.png","width":844,"height":230,"caption":"Softree Technology"},"image":{"@id":"https:\/\/softreetechnology.com\/blog\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/softreetechnology.com\/blog\/#\/schema\/person\/98740297642f06debccdcee2de84086b","name":"admin","image":{"@type":"ImageObject","inLanguage":"en","@id":"https:\/\/softreetechnology.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/6fc78c8a7aa3fb0bf43c3b9a2e3962d7?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/6fc78c8a7aa3fb0bf43c3b9a2e3962d7?s=96&d=mm&r=g","caption":"admin"},"sameAs":["https:\/\/softreeconsulting.com"],"url":"https:\/\/softreetechnology.com\/blog\/author\/admin\/"}]}},"_links":{"self":[{"href":"https:\/\/softreetechnology.com\/blog\/wp-json\/wp\/v2\/posts\/837","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/softreetechnology.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/softreetechnology.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/softreetechnology.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/softreetechnology.com\/blog\/wp-json\/wp\/v2\/comments?post=837"}],"version-history":[{"count":0,"href":"https:\/\/softreetechnology.com\/blog\/wp-json\/wp\/v2\/posts\/837\/revisions"}],"wp:attachment":[{"href":"https:\/\/softreetechnology.com\/blog\/wp-json\/wp\/v2\/media?parent=837"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/softreetechnology.com\/blog\/wp-json\/wp\/v2\/categories?post=837"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/softreetechnology.com\/blog\/wp-json\/wp\/v2\/tags?post=837"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}