Skip to main content

Notifications

Announcements

No record found.

Small and medium business | Business Central, N...
Suggested answer

OAuth service to service authentication

Posted on by 115

Hi, We have done Oauth Authentication with BC to access web services using a console application, it has been working perfectly before (4-5 months ago), but now it is returning internal server error 500. Intresting part is that its still working with Postman. 

Do anyone knows the issue ? if someone has faced this before ?

  • Suggested answer
    Marco Mels Profile Picture
    Marco Mels on at
    RE: OAuth service to service authentication

    Thank you for sharing.

  • faran1 Profile Picture
    faran1 115 on at
    RE: OAuth service to service authentication

    Hi, the issue resolved.

    Permissions set were missing on azure active directory page where we do App registration is business central.

  • Suggested answer
    YUN ZHU Profile Picture
    YUN ZHU 73,698 Super User 2024 Season 2 on at
    RE: OAuth service to service authentication

    Hi, I just tested it in the latest BC21.5, and there is no problem. I suggest to check the App settings on the Azure side as well.

    Version: W1 21.5 (Platform 21.0.53597.53923 + Application 21.5.53619.53813)

    pastedimage1678234276159v1.png

    Thanks.

    ZHU

  • Bilal Haider Profile Picture
    Bilal Haider 45 on at
    RE: OAuth service to service authentication

    Do you have telemetry or error log of this issue. Because it might be that you are missing some required parameter in request etc.

  • faran1 Profile Picture
    faran1 115 on at
    RE: OAuth service to service authentication

    Hi, yes its not about the authentication, access token is being retrieved. It could be any thing like something missing from the business central setup (related to web service) but nothing has been changed.

  • Suggested answer
    Bilal Haider Profile Picture
    Bilal Haider 45 on at
    RE: OAuth service to service authentication

    Hi Faran,

    Are you sure this is authentication issue? Because error code 500 does not mean necessarily authentication issue.

    May be you need to refresh the Token for authentication?

    If you can share log/more info then may be answer can be more specific.

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,235 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans