Data Providers
...
MS Graph
Graph Insights
Get item trending
6min
Get insights that include a list of documents trending around the user using a GET REST function and display the list in a list .
Resource links:
Required OAuth scope (least to most privilege):
Sites.Read.All Sites.ReadWrite.All
![Insights - trending Insights - trending](https://images.archbee.com/x7vdIDH6-ScTprfmi2XXX/p9BeCoKBDXDxGNvlXA4j1_graph-trending.png?format=webp)
Insights - trending
index.jigx
name: ms-graph-demonstrator
title: MS Graph Demonstrator
description: A sample solution that uses the Microsoft Graph API. You can deploy and use this solution without any additional configuration.
category: business
widgets:
- size: 2x2 # choose size of the widget on the home hub
jigId: view-user-jigx
- size: "4x2"
jigId: items-trending
MS Graph list trending function in GitHub.
get-calendar-list.jigx
provider: DATA_PROVIDER_REST
method: GET
url: https://graph.microsoft.com/v1.0/me/insights/trending
outputTransform: $.value
useLocalCall: true
parameters:
accessToken:
location: header
required: true
type: string
value: microsoft.OAuth #Use manage.jigx.com to define credentials for your solution
$top:
type: string
location: query
required: false
value: 100
continuation:
when: =$.nextLink
url: =$.nextLink
parameters:
accessToken:
location: header
required: true
type: string
value: microsoft.OAuth
MS Graph list trending s in GitHub.
view-calendar-list.jigx
view-trending-object-pdf.jigx
view-trending-object.jigx
title: Items Trending
type: jig.default
header:
type: component.jig-header
options:
height: small
children:
type: component.image
options:
source:
uri: https://www.windowslatest.com/wp-content/uploads/2018/12/Office-apps-new-icons.jpg
onRefresh:
type: action.action-list
options:
actions:
- type: action.sync-entities
options:
provider: DATA_PROVIDER_REST
entities:
- entity: items-trending
function: get-items-trending
functionParameters:
accessToken: microsoft.OAuth
datasources:
mydata:
type: datasource.sqlite
options:
provider: DATA_PROVIDER_LOCAL
entities:
- entity: items-trending
query: SELECT id, '$.weight',
json_extract(Data, '$.resourceReference.webUrl') as webUrl,
json_extract(Data, '$.resourceVisualization.containerDisplayName') as containerDisplayName,
json_extract(Data, '$.resourceVisualization.previewText') as previewText,
json_extract(Data, '$.resourceVisualization.title') as title,
json_extract(Data, '$.resourceVisualization.type') as type
FROM [items-trending]
order by '$.weight' desc
children:
- type: component.list
options:
data: [email protected]
maximumItemsToRender: =$count(@ctx.datasources.mydata)
item:
type: component.list-item
options:
title: [email protected]
subtitle: |
="Relevance: " & $round((@ctx.current.item.weight * 100),2) & "%"
description: [email protected]
divider: solid
leftElement:
element: icon
icon: gauge-dashboard
label:
title: [email protected]
onPress:
type: action.go-to
options:
linkTo: [email protected]='pdf'? 'view-trending-object-pdf':'view-trending-object'
parameters:
uri: [email protected]
widgets:
"4x2":
type: widget.group
options:
children:
- type: widget.image
options:
isContentOverlaid: true
bottom:
type: component.titles
options:
align: center
subtitle: =$count(@ctx.datasources.mydata) & " items trending around you."
source:
uri: https://www.windowslatest.com/wp-content/uploads/2018/12/Office-apps-new-icons.jpg
- type: widget.list
options:
data: [email protected]
item:
type: component.list-item
options:
title: [email protected]
subtitle: [email protected] & " document"
description: [email protected]
divider: solid
onPress:
type: action.go-to
options:
linkTo: [email protected]='pdf'? 'view-trending-object-pdf':'view-trending-object'
parameters:
uri: [email protected]
Updated 06 May 2024
![Doc contributor](https://s3.amazonaws.com/archbee-animals/rabbit.png)
Did this page help you?