<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Row level security python in Developer</title>
    <link>https://community.fabric.microsoft.com/t5/Developer/Row-level-security-python/m-p/396915#M11825</link>
    <description>&lt;P&gt;Hello,&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I have this python code to generate access token with power bi embedded, it is working fine, but I want to add the identities parameter to take into account rls functionality&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here is the python code:&lt;/P&gt;&lt;PRE&gt;    def __init__(self, report_id, group_id, settings=None):
        self.username = 'MyUserName'
        self.password = 'MyPassword'
        self.client_id = '28c7e68d-6eb1-4be3-8b97-4c0fa9cd83d7'
        self.report_id = report_id
        self.group_id = group_id
        if settings is None:
            self.settings = {'accessLevel': 'View', 'allowSaveAs': 'false'}  
        else:
            self.settings = settings
        self.access_token = self.get_access_token()
        self.config = self.get_embed_token()&lt;/PRE&gt;&lt;P&gt;&lt;BR /&gt;I think that identities should be added at this line :&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;PRE&gt;self.settings = {'accessLevel': 'View', 'allowSaveAs': 'false'}&lt;/PRE&gt;&lt;P&gt;&lt;BR /&gt;For more clarification I have a C# code that is working fine :&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;PRE&gt;generateTokenRequestParameters = new GenerateTokenRequest("View", null, identities: new List&amp;lt;EffectiveIdentity&amp;gt; { new EffectiveIdentity(username: "EffectiveUserName", roles: new List&amp;lt;string&amp;gt; { "FranceSales" }, datasets: new List&amp;lt;string&amp;gt; { "382ea16c-fbcc-4cec-bb60-470aff4aebaa" }) });&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 16 Apr 2018 08:08:20 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2018-04-16T08:08:20Z</dc:date>
    <item>
      <title>Row level security python</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Row-level-security-python/m-p/396915#M11825</link>
      <description>&lt;P&gt;Hello,&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I have this python code to generate access token with power bi embedded, it is working fine, but I want to add the identities parameter to take into account rls functionality&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here is the python code:&lt;/P&gt;&lt;PRE&gt;    def __init__(self, report_id, group_id, settings=None):
        self.username = 'MyUserName'
        self.password = 'MyPassword'
        self.client_id = '28c7e68d-6eb1-4be3-8b97-4c0fa9cd83d7'
        self.report_id = report_id
        self.group_id = group_id
        if settings is None:
            self.settings = {'accessLevel': 'View', 'allowSaveAs': 'false'}  
        else:
            self.settings = settings
        self.access_token = self.get_access_token()
        self.config = self.get_embed_token()&lt;/PRE&gt;&lt;P&gt;&lt;BR /&gt;I think that identities should be added at this line :&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;PRE&gt;self.settings = {'accessLevel': 'View', 'allowSaveAs': 'false'}&lt;/PRE&gt;&lt;P&gt;&lt;BR /&gt;For more clarification I have a C# code that is working fine :&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;PRE&gt;generateTokenRequestParameters = new GenerateTokenRequest("View", null, identities: new List&amp;lt;EffectiveIdentity&amp;gt; { new EffectiveIdentity(username: "EffectiveUserName", roles: new List&amp;lt;string&amp;gt; { "FranceSales" }, datasets: new List&amp;lt;string&amp;gt; { "382ea16c-fbcc-4cec-bb60-470aff4aebaa" }) });&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 16 Apr 2018 08:08:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Row-level-security-python/m-p/396915#M11825</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-04-16T08:08:20Z</dc:date>
    </item>
    <item>
      <title>Re: Row level security python</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Row-level-security-python/m-p/400581#M11926</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What is your current situation?&lt;/P&gt;&lt;P&gt;The &lt;A href="https://msdn.microsoft.com/en-us/library/mt784614.aspx" target="_self"&gt;generate Token API&lt;/A&gt; is used to generate EmbedToken.&lt;/P&gt;&lt;P&gt;I am not familiar with Python, just from the code structure you posted, I agree that the identities should be configured with the settings part.&lt;/P&gt;&lt;P&gt;Let us know if it works.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Michael&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 20 Apr 2018 01:29:36 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Row-level-security-python/m-p/400581#M11926</guid>
      <dc:creator>v-micsh-msft</dc:creator>
      <dc:date>2018-04-20T01:29:36Z</dc:date>
    </item>
  </channel>
</rss>

