{"id":3943,"date":"2020-01-13T14:48:32","date_gmt":"2020-01-13T22:48:32","guid":{"rendered":"https:\/\/developer.microsoft.com\/en-us\/office\/blogs\/?p=3943"},"modified":"2020-01-13T14:48:32","modified_gmt":"2020-01-13T22:48:32","slug":"creating-single-sign-on-add-ins-for-office-has-never-been-easier","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/creating-single-sign-on-add-ins-for-office-has-never-been-easier\/","title":{"rendered":"Creating single sign-on add-ins for Office has never been easier"},"content":{"rendered":"<p>The Office Add-ins developer experience team has been improving the process of building single sign-on (SSO) Office Add-ins in Node.js. We\u2019re excited to announce that you can now create SSO-enabled Office Add-ins using Yo Office &#8211; our command-line add-in creation tool! <a href=\"https:\/\/github.com\/OfficeDev\/generator-office\/\">Yo Office<\/a> will jumpstart your development by generating the code that\u2019s necessary for an add-in to use SSO and automating your Azure registration steps, allowing you to dive right into building your add-in!<\/p>\n<h3>What is single sign-on (SSO) and why should I use it?<\/h3>\n<p>Users sign into Office (online, mobile, and desktop platforms) using either their personal Microsoft account or their work or school (Office 365) account. You can take advantage of this and use single sign-on (SSO) to authorize the user to your add-in without requiring the user to sign in a second time.<\/p>\n<p><strong>**Note:<\/strong> The SSO feature is still preview, and we don\u2019t recommend using preview features in production add-ins.<\/p>\n<h3>Jumpstart your SSO development<\/h3>\n<p><img decoding=\"async\" src=\"https:\/\/raw.githubusercontent.com\/OfficeDev\/generator-office\/master\/src\/docs\/assets\/ssotemplate.gif\" width=\"640\" height=\"368\" \/><\/p>\n<p>The new <a href=\"https:\/\/docs.microsoft.com\/office\/dev\/add-ins\/quickstarts\/sso-quickstart\">SSO quick start<\/a> describes how to create an SSO-enabled add-in with Yo Office. First, you\u2019ll use <a href=\"https:\/\/github.com\/OfficeDev\/generator-office\/\">Yo Office<\/a> to create an SSO add-in project. This will create a task pane add-in that includes the code required to facilitate single sign-on. Then, in the root directory of your project, you\u2019ll run \u201cnpm run configure-sso\u201d. This will register your Office Add-in in Azure and update your project files with data that\u2019s required by the SSO process.<\/p>\n<p>When complete, your add-in will be configured to automatically sign in users (based on the person signed into Office) and make a call to Microsoft Graph.<\/p>\n<p><img decoding=\"async\" class=\"alignleft wp-image-3963\" src=\"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-content\/uploads\/sites\/73\/2020\/01\/ssotemplate2.png\" alt=\"\" width=\"550\" height=\"629\" srcset=\"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-content\/uploads\/sites\/73\/2020\/01\/ssotemplate2.png 782w, https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-content\/uploads\/sites\/73\/2020\/01\/ssotemplate2-262x300.png 262w, https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-content\/uploads\/sites\/73\/2020\/01\/ssotemplate2-768x878.png 768w\" sizes=\"(max-width: 550px) 100vw, 550px\" \/><\/p>\n<p><a href=\"https:\/\/docs.microsoft.com\/office\/dev\/add-ins\/quickstarts\/sso-quickstart\">Try our quick start today<\/a>!<\/p>\n<h3>Additional \u00a0Resources<\/h3>\n<ul>\n<li><a href=\"https:\/\/docs.microsoft.com\/office\/dev\/add-ins\/quickstarts\/sso-quickstart\">Use the Yeoman generator to create an Office Add-in that uses single sign-on<\/a><\/li>\n<li><a href=\"https:\/\/docs.microsoft.com\/en-us\/office\/dev\/add-ins\/develop\/sso-in-office-add-ins\">Learn more about SSO for Office Add-ins<\/a><\/li>\n<li><a href=\"https:\/\/github.com\/OfficeDev\/generator-office\/\">Learn more about Yo Office<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>The Office Add-ins developer experience team has been improving single sign-on (SSO) for Node.js Office Add-ins. <\/p>\n","protected":false},"author":69076,"featured_media":25159,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[11],"tags":[132,61,18,12,43],"class_list":["post-3943","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-office-add-ins","tag-add-ins","tag-azure","tag-excel","tag-outlook","tag-sso"],"acf":[],"blog_post_summary":"<p>The Office Add-ins developer experience team has been improving single sign-on (SSO) for Node.js Office Add-ins. <\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/posts\/3943","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/users\/69076"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/comments?post=3943"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/posts\/3943\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/media\/25159"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/media?parent=3943"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/categories?post=3943"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/tags?post=3943"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}