<?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 Re: Retrieving name of current user with API in Developer Q&amp;A Forum</title>
    <link>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263563#M1187</link>
    <description>&lt;P&gt;Hi flomaz,&lt;/P&gt;
&lt;P&gt;the permission should be&amp;nbsp;&lt;STRONG&gt;app-engine:apps:run&lt;/STRONG&gt;. Can you check if you have it?&lt;/P&gt;</description>
    <pubDate>Mon, 25 Nov 2024 11:20:36 GMT</pubDate>
    <dc:creator>haris</dc:creator>
    <dc:date>2024-11-25T11:20:36Z</dc:date>
    <item>
      <title>Retrieving name of current user with API</title>
      <link>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263224#M1174</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I'm trying to get the current user name and id using the platform API with a platform token.&lt;/P&gt;&lt;P&gt;I've checked the Swagger UI for the `Identity and Access Management` but did not find any solution.&lt;BR /&gt;&lt;BR /&gt;Is there an API available for fetching the medata of the owner of the platform token without administrator permissions?&lt;/P&gt;</description>
      <pubDate>Thu, 21 Nov 2024 13:50:00 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263224#M1174</guid>
      <dc:creator>flomaz</dc:creator>
      <dc:date>2024-11-21T13:50:00Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving name of current user with API</title>
      <link>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263252#M1177</link>
      <description>&lt;P&gt;Hi flomaz,&lt;/P&gt;
&lt;P&gt;we already have an SDK released earlier this year for this purpose. Please see:&amp;nbsp;&lt;A href="https://developer.dynatrace.com/develop/sdks/app-environment/" target="_blank" rel="noopener noreferrer"&gt;https://developer.dynatrace.com/develop/sdks/app-environment/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can also check this thread with more information:&amp;nbsp;&lt;A href="https://community.dynatrace.com/t5/Developer-Q-A-Forum/Dynatrace-App-Current-user-information/m-p/218433" target="_blank"&gt;https://community.dynatrace.com/t5/Developer-Q-A-Forum/Dynatrace-App-Current-user-information/m-p/218433&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Let me know if you need anything else.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 21 Nov 2024 15:48:07 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263252#M1177</guid>
      <dc:creator>haris</dc:creator>
      <dc:date>2024-11-21T15:48:07Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving name of current user with API</title>
      <link>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263258#M1178</link>
      <description>&lt;P&gt;Hi there&lt;BR /&gt;&lt;BR /&gt;You can use the&amp;nbsp;&lt;A href="https://www.npmjs.com/package/@dynatrace-sdk/app-environment" target="_blank" rel="noopener noreferrer"&gt;&lt;SPAN class="margin-right--xs"&gt;@dynatrace-sdk/app-environment&amp;nbsp;&lt;/SPAN&gt;&lt;/A&gt;sdk to get the user details as following:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;LI-CODE lang="javascript"&gt;// import the function
import { getCurrentUserDetails } from "@dynatrace-sdk/app-environment";

// get the user details
const userDetails = getCurrentUserDetails();

// do something wit it
console.log(userDetails);&lt;/LI-CODE&gt;
&lt;P&gt;&lt;BR /&gt;Thanks&lt;/P&gt;
&lt;P&gt;Indermohan Singh&lt;/P&gt;</description>
      <pubDate>Thu, 21 Nov 2024 15:54:52 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263258#M1178</guid>
      <dc:creator>imsingh</dc:creator>
      <dc:date>2024-11-21T15:54:52Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving name of current user with API</title>
      <link>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263259#M1179</link>
      <description>&lt;P&gt;Hello &lt;a href="https://community.dynatrace.com/t5/user/viewprofilepage/user-id/52863"&gt;@imsingh&lt;/a&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;BR /&gt;I would like to fetch it from a Python script, for this reason I cannot use the SDK. &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 21 Nov 2024 15:57:57 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263259#M1179</guid>
      <dc:creator>flomaz</dc:creator>
      <dc:date>2024-11-21T15:57:57Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving name of current user with API</title>
      <link>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263262#M1181</link>
      <description>&lt;P&gt;Hi flomaz,&lt;/P&gt;
&lt;P&gt;can you try using this:&lt;/P&gt;
&lt;PRE&gt;https://{environmentid}.apps.dynatrace.com/platform/metadata/v1/user&lt;/PRE&gt;
&lt;P&gt;This should return json with following info: username, ID and email address like so:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{"userName":"Haris H","userId":"621321d-1231-dsad-652321829b50","emailAddress":"haris.h@dynatrace.com"}&lt;/LI-CODE&gt;</description>
      <pubDate>Thu, 21 Nov 2024 16:11:25 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263262#M1181</guid>
      <dc:creator>haris</dc:creator>
      <dc:date>2024-11-21T16:11:25Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving name of current user with API</title>
      <link>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263263#M1182</link>
      <description>&lt;P&gt;Hello Haris,&lt;BR /&gt;Thanks, do you know if there are any permission to add to use this api ?&lt;BR /&gt;I've tried this url but I do get 403. Is there any specific scope that I should add to the platform token ?&lt;/P&gt;</description>
      <pubDate>Thu, 21 Nov 2024 16:13:49 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263263#M1182</guid>
      <dc:creator>flomaz</dc:creator>
      <dc:date>2024-11-21T16:13:49Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving name of current user with API</title>
      <link>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263563#M1187</link>
      <description>&lt;P&gt;Hi flomaz,&lt;/P&gt;
&lt;P&gt;the permission should be&amp;nbsp;&lt;STRONG&gt;app-engine:apps:run&lt;/STRONG&gt;. Can you check if you have it?&lt;/P&gt;</description>
      <pubDate>Mon, 25 Nov 2024 11:20:36 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263563#M1187</guid>
      <dc:creator>haris</dc:creator>
      <dc:date>2024-11-25T11:20:36Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving name of current user with API</title>
      <link>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263572#M1188</link>
      <description>&lt;P&gt;Hi Haris,&lt;/P&gt;&lt;P&gt;Thanks, I've created a new platform token with the permission `&lt;STRONG&gt;app-engine:apps:run&lt;/STRONG&gt;` and now I get a http 500.&lt;/P&gt;&lt;BLOCKQUOTE&gt;{&lt;BR /&gt;"error": {&lt;BR /&gt;"code": 500,&lt;BR /&gt;"message": "Internal Server Error occurred.",&lt;BR /&gt;"details": {&lt;BR /&gt;"errorRef": "",&lt;BR /&gt;"traceId": ""&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 25 Nov 2024 12:34:09 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/263572#M1188</guid>
      <dc:creator>flomaz</dc:creator>
      <dc:date>2024-11-25T12:34:09Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving name of current user with API</title>
      <link>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/264077#M1196</link>
      <description>&lt;P&gt;Hi flomaz,&lt;/P&gt;
&lt;P&gt;thanks for the patience. We're currently working on fixing this. I'll update you as soon as I have new info.&lt;/P&gt;</description>
      <pubDate>Sun, 01 Dec 2024 22:12:58 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Developer-Q-A-Forum/Retrieving-name-of-current-user-with-API/m-p/264077#M1196</guid>
      <dc:creator>haris</dc:creator>
      <dc:date>2024-12-01T22:12:58Z</dc:date>
    </item>
  </channel>
</rss>

