Create a profile integrated with Microsoft OneDrive

Visio diagrams can be rendered from remote locations and external applications such as GitLab, GitHub, and so on. Since 5.3.0 release, the Visio for Confluence app can access and render Visio diagrams located in Microsoft OneDrive. This article contains instructions to integrate OneDrive with Confluence with the aim of preserving data security and privacy.

Before you begin

  • Know how to create and use profiles. Refer to the following resources:

  • Understand why an application must be created using Microsoft Azure. An application created in Microsoft Azure acts like an interface that allows Confluence to access the Microsoft OneDrive content, and at the same time, provides an additional layer of security. A Confluence administrator must grant access to this application using his/her Microsoft credentials to establish the integration. This enables Confluence to be linked to Microsoft OneDrive and render Visio content in OneDrive on Confluence pages.

Steps

The following sections explain how to create a link between Confluence and Microsoft OneDrive, and how to use a OneDrive profile to render your Visio content on your Confluence pages:

  1. Register an application using the Microsoft Azure portal

  2. Create the interface between OneDrive and Confluence

  3. Use the OneDrive profile with the Visio Viewer macro

Register an application using the Microsoft Azure portal

  1. Register an application through App registrations in the Microsoft Azure portal. Refer to this link for Microsoft related instructions.

    1. Open the Microsoft Azure portal and log in to the relevant business or personal Microsoft account.

      Image shows the App registrations page in Microsoft Azure.
      Microsoft Azure - App registrations
    2. Click New registration or Register an application to create a new application.

    3. Enter a meaningful name for the application to be used when creating a profile in Visio for Confluence.

    4. Select the required access level for this application in Supported account types.

    5. Select Web and enter https://<confluence_base_url>/admin/plugins/org.swift.confluence.visio/visioonedrive.action in the text box provided in Redirect URI (optional). Replace <confluence_base_url> with the base URL of your Confluence instance.

      Image shows how to proceed with app registration with Microsoft Azure.
      Register an application page
    6. Click Register. The app gets registered and the Application (client) ID, used for all account types, and Directory (tenant) ID, used with work accounts, is displayed.

    7. Select Certificates & secrets to create a client secret. The application uses the client ID and the secret for authentication to generate an access token for a profile in Confluence.

    8. Click New client secret and a pop-up window appears. Enter a description for the client secret, select the required validity of the client secret, and click Add.

  2. Copy the following values  in a secure place:

    1. Client secret: This value is not shown again if another operation is performed or if you leave the page.

    2. Client ID: This Application (client) ID value is shown on the Overview page of the newly created application. 

    3. Tenant ID: If integrating with a work account, this value is also shown on the Overview page of the newly created application.

Authenticating an application with Microsoft user credentials from Confluence provides the optimal method to protect your data and privacy. Profiles allow multiple users to access a OneDrive account across pages and instances of the Visio Viewer macro.

Create the interface between Microsoft OneDrive and Confluence

  1. In your Confluence instance, navigate to  > Manage apps > Bobswift Configuration > Visio > Profiles, and click Add profile.

  2. Specify Profile type as OneDrive, paste the copied client ID in OneDrive client ID, and paste the copied client secret value in OneDrive client secret. To access a work account, also paste the tenant ID in OneDrive tenant ID.

  3. Authorize to create an interface from the Visio for Confluence app with the OneDrive account. 

  4. A Microsoft login window appears to grant permissions to the app created in the previous section. If you did not log in Microsoft yet, a login window opens which prompts you to log in and you must provide the credentials of the user who created the app. Click Yes to grant access to the app to read the OneDrive files. 

  5. An access token is generated and is automatically filled in the Access token field if the app is granted access.

  6. Save the profile.

The integration between OneDrive and the registered app is now complete and the profile can be used to render Visio diagrams onto Confluence pages. The following screenshot displays the order to be followed when creating the profile linked to OneDrive:

About access tokens:

  • The access token used stays valid until the validity of the client secret value given in the Microsoft portal expires.

  • If the client secret expires or is lost before copying the value, create a new client secret as mentioned in step 'g' of the Register an application using Microsoft Azure section. Paste the new client secret value in the Add profile window.

Use the OneDrive profile in the Visio Viewer macro

  1. Go to the required Confluence page, and add a Visio Viewer macro or edit an existing macro to open the macro editor.

  2. Select the newly created profile in Profile.

  3. Enter the relative path of the Visio file to be rendered in URL to Visio file.

  4. See a Preview, or Save and Publish your page.


Find answers from the community.

Ask a question to the community.

Log a request with our support team.

Confluence®, Jira®, Atlassian Bamboo®, Bitbucket®, Fisheye®, and Atlassian Crucible® are registered trademarks of Atlassian®
Copyright © 2005 - 2024 Appfire | All rights reserved. Appfire™, the 'Apps for makers™' slogan and Bob Swift Atlassian Apps™ are all trademarks of Appfire Technologies, LLC.