Using the Lightning Conductor Client Side Web Part Graph API

From version 2.0.0.0 released in May 2019, the Lightning Conductor now offers content aggregation using the Graph API as well as the existing Client Side Object Model and the Search API. Each rollup engine is summarised below:

  • Client Side Object Model – Used for real time aggregation of SharePoint lists and library content.
  • Search – Used for faster performance, but non-real time aggregation of SharePoint list content.
  • Graph API – Used to aggregate content beyond SharePoint lists such as Microsoft Planner, Messages, Microsoft Teams, etc.

Granting Permissions to the Lightning Conductor for the Graph API

In order to use the Lightning Conductor to aggregate content from Office 365 Graph, permissions need to be assigned. You can use the Lightning Conductor to aggregate content using the Search API and Client Side Object Model for SharePoint lists without setting these permissions.

The following steps are required to assign the Microsoft Graph Permissions to the Lightning Conductor Client Side Web Part:

  1. From the Lightning Conductor downloaded Zip file, upload the “request-graph-permissions.sppkg” file to your SharePoint App Catalog.

    Upload file to App Catalog

  2. Navigate to your Admin Portal.

    Admin Portal

  3. Navigate to the SharePoint Admin Center.

  4. Using the new Modern SharePoint Admin Center, navigate to API Management under the Advanced category in the left hand side navigation panel. If you have difficulty finding the option, please use the following URL: https://[YOURTENANT]-admin.sharepoint.com/_layouts/15/online/AdminHome.aspx#/webApiPermissionManagement. Replace [YOURTENANT] with the name of your tenant e.g. https://lightningtoolsdemo-admin.sharepoint.com/_layouts/15/online/AdminHome.aspx#/webApiPermissionManagement.

    SharePoint Admin Center

  5. Select the permissions that you wish to grant to the Lightning Conductor from the following:

  • Contacts.Read
  • Files.Read.All
  • Directory.Read.All
  • Group.Read.All
  • Sites.Read.All
  • Mail.Read.All

    API Management

Using the Graph API within the Lightning Conductor

The Lightning Graph API extends the capabilities of the Lightning Conductor allowing it to aggregate content beyond SharePoint lists. You can use the Graph rollup provider to read content from Planner, User Profiles, Microsoft Teams, and more. The Graph rollup provider can be used with the Quick Configuration Mode and the Advanced Configuration Mode.

Quick Configuration Mode

The Quick Configuration Mode offers two rollups using the Graph API which includes Messages and Users.

Quick Configuration Mode

Messages offers four refined views, which will return messages from your email account. You can display All messages, Unread messages, Sent messages or Received messages.

Quick Configuration Messages

Users returns users from your tenant, whilst Guest users returns a list of guest users from your tenant.

Quick Configuration Users

Advanced Configuration Mode

Using the Advanced Configuration Mode, you can use the Graph API to return data from the following Entity Types:

  • User
  • Group
  • Contact
  • Drive
  • Drive Item
  • Calendar
  • Event
  • Message
  • Planner Plan
  • Planner Task
  • Site
  • Content Type
  • Column
  • List
  • List Item

Graph Rollup Provider

Entity Type

There is a good explanation of the Graph API Entities here: https://docs.microsoft.com/en-us/graph/api/resources/security-api-overview?view=graph-rest-1.0.

Each Entity Type can be queried either using our pre-defined queries or custom queries. There are a lot of variations that you can perform. We will continue to add to our documentation with possibilities. In the below example, we will query Microsoft Planner.

To add a Query, click the + icon next to query after selecting your desired entity type.

Construct Graph Query

You’ll notice that there are either pre-defined query types, or you can build your own custom query. You can use the User Planner Tasks, and leave the user empty for the current user.

The Lightning Conductor offers Query Syntax Checking, and will show a Valid symbol if your query is syntactically correct. You can edit or remove the query using the options shown below:

Query Syntax Checking

You can then select the columns from the Entity that you wish to display.

Configure Columns

Planner Tasks will then be displayed, and can now be grouped, formatted, etc., using the display properties.

Display Settings

Feedback

Was this helpful?

Yes No
You indicated this topic was not helpful to you ...
Could you please leave a comment telling us why? Thank you!
Thanks for your feedback.

Post your comment on this topic.

Please do not use this for support questions.
For customer support, please contact us here.

Post Comment