web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Answered

Accessing the web service access key of a user from assisted setup in AL extension

(0) ShareShare
ReportReport
Posted on by 35

Hello Business Central Community,

This is my first question here so I hope it is posted in the right place and not asked before.

The existing assisted setup "Set up Dynamics 365 Sales connection" lets the user select a user account that will be used as service user and displays the webservice access key.

My question is how to accomplish this in our own extension. So far I haven't found a Table or CodeUnit that allows retrieving webservice access keys. Is this even possible from an extension?

  pastedimage1576574822364v1.png

Thanks in advance

I have the same question (0)
  • Mohana Yadav Profile Picture
    61,003 Super User 2025 Season 2 on at

    Did you check function "GetWebServicesKey" in codeunit 9801 - Identity Management?

  • Erik S Profile Picture
    35 on at

    Thanks for the response. I had not found that specific code unit yet so thanks again. Sadly the function cannot be used in an extension apparently as I get the following error:

    The type or method 'GetWebServicesKey' cannot be used for 'Extension' development.AL(AL0296)

  • Suggested answer
    Stefano Demiliani Profile Picture
    37,166 Most Valuable Professional on at

    I think this is not possible for security reasons.

  • Erik S Profile Picture
    35 on at

    Not the answer I was hoping for but thanks for clearing this up.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 2,917

#2
Jainam M. Kothari Profile Picture

Jainam M. Kothari 1,161 Super User 2025 Season 2

#3
YUN ZHU Profile Picture

YUN ZHU 1,025 Super User 2025 Season 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans