【General】Power BI Connector Advanced 

I've previously posted an article Microsoft Power Power BI connector, and this time, I'd like to explain the setup it using Sharperlight token.

**Connector Setup**
Launch Microsoft Power BI Desktop.
Select **Options and settings** from the **File** menu.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/9adb596d-3899-d2b5-20c2-fbd1eee9cfdd.png)
Choose **Data source settings**.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/97585f1a-cf06-e557-95c7-12797e736bb4.png)
If a data source exists, refresh it by editing it.
Click the "Edit Permissions" button.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/e0a7fed7-9a8c-53ae-8768-8608b8df6f23.png)
The `Edit Permissions` dialog will appear. Proceed by clicking the `Edit` button.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/1bb28b25-f8f4-ef71-b099-f5ced8a9bd13.png)
From the left-side menu on the next screen, select **Sharperlight Feed Key**. Pause here with it open.
Generate the Sharperlight Feed Key.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/905af898-77c4-cb97-9251-3903257b07ad.png)


**Getting the Sharperlight Feed Key**
Launch `Site Setup` and select the intended user.
Right-click to open the context menu and choose **Client Secret / Feed Key** => **Create** to open a dedicated dialog.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/b6c35891-296f-e91b-2a3c-d038638b1d31.png)
Once the dialog is open, copy the automatically generated key to your clipboard using the `Copy to Clipboard` button.
Close the dialog with the `OK` button.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/f4661c9e-a1ac-b9d1-fecd-98f3516ce923.png)
Restart the Sharperlight service.

**Setting the Sharperlight Feed Key**
Paste the Feed Key you copied to your clipboard earlier into the `Sharperlight Site Setup - Token` text box.
Save using the `Save` button.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/c6085057-04b7-c4fd-6a52-4d0ea2c49a08.png)
Close this screen with the `OK` button.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/8d0e3a99-51bc-1ca4-6b76-ff32f7f41cad.png)
Back in the Power BI main screen, select **More...** from the **Get data** menu.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/78b82093-1824-978c-db50-c771b5c8e69e.png)
Enter "sh" in the search field and search for "Sharperlight."
Double-click on Sharperlight or select it by clicking the `Connect` button.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/5274b6ba-8924-2c21-fa30-7673126abf4f.png)
The `From Sharperlight.Content` dialog will open.
Set the Power BI URL for Sharperlight to the URL field. Keep this dialog open while you get the Power BI URL.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/5aa066f9-b67d-aa84-d45d-20bf9c88d67d.png)

**Getting URL with Sharperlight Publisher**
Launch Sharperlight Publisher from the Sharperlight application menu.
Choose any published report, right-click, and select **Links** => **Power BI** from the context menu.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/42a08a77-7d20-6f63-7d09-a720153f17f8.png)
A message will confirm that the URL has been copied to your clipboard.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/7bc84ad6-dbf1-b324-e181-9db4d65609e7.png)

**Loading a Datasource Designed with Sharperlight Published Query**
Paste the URL copied to your clipboard into the URL text field of the `From Sharperlight.Content` dialog.
Click OK.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/a52be186-0f18-d5c5-7711-b52e4597165c.png)
The Navigator screen will appear, showing a list of data sources accessible through Sharperlight service.
Tick the desired datasource and click the `Load` button to connect to it.
![image.png](https://qiita-image-store.s3.ap-northeast-1.amazonaws.com/0/2530698/c945e6b0-ced3-27e1-f3df-a8c9973a562d.png)

That concludes the setup. How was it? Please feel free to give it a try.