Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

The security token service metadata document could not be parsed

(0) ShareShare
ReportReport
Posted on by 780

I am back again and trying this integration again !! - We have Dynamics CRM 2016 and SharePoint 2016 - both on-premise.  I am trying to integrate the two by following this article: - https://technet.microsoft.com/en-us/library/dn949332.aspx.  My CRM is an IFD deployment with ADFS and WAP. 

I am stuck on the following command New-SPTrustedSecurityTokenIssuer –Name "crm" –IsTrustBroker:$false –MetadataEndpoint https://MyCrmServerhostname/XrmServices/2015/metadataendpoint.svc/json?orgName=MyOrganizationName which gives the error as follows:

New-SPTrustedSecurityTokenIssuer : The security token service metadata document could not be parsed.
At line:1 char:1
+ New-SPTrustedSecurityTokenIssuer -Name "crm" -IsTrustBroker:$false -M ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidData: (Microsoft.Share...rityTokenIssuer:SPCmdletNewTrustedSecurityTokenIssuer) [
   New-SPTrustedSecurityTokenIssuer], InvalidOperationException
    + FullyQualifiedErrorId : Microsoft.SharePoint.PowerShell.SPCmdletNewTrustedSecurityTokenIssuer

If I enter the MetadataEndpoint in IE it asks if I want to save or open json.json. 

I have exhausted Google to find a solution.  Can anyone help me here - I am now desparate!!

*This post is locked for comments

  • Joe Woltering Profile Picture
    Joe Woltering 12,161 on at
    RE: The security token service metadata document could not be parsed

    "Where was the Options screen to disable IFD that you referenced?"

  • DLGross Profile Picture
    DLGross on at
    RE: The security token service metadata document could not be parsed

    Where was the Options screen to disable IFD that you referenced?

  • Verified answer
    RE: The security token service metadata document could not be parsed

    Thanks Ardee for sharing this article

  • Rose Duley Profile Picture
    Rose Duley 780 on at
    RE: The security token service metadata document could not be parsed

    Hi Rajkumar  -  It wasn't as daunting as I thought it would be!!  I was relieved to see that there was a "Disable" option to turn off Claims and IFD  and my settings were not lost!  So all went well.  THANKS so much for getting back to me and assisting here!!

    Just for others following the same article as I did - note that I had to use GET-SPauthenticationRealm -SerivceContext sharepointsite.contoso.com/.../crm to get realm ID for SharePoint site.  Going into Site settings did not work for me.

  • Rose Duley Profile Picture
    Rose Duley 780 on at
    RE: The security token service metadata document could not be parsed

    answers.flyppdevportal.com/.../9d3ebcf2-daf4-4564-a992-67a038aef9c5 REALLY???

    Is this the only way?  UNDO IFD? That is scary!  Do you guys know what hassles were had doing the IFD?  Is there no Microsoft update that will fix this?

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

Daivat Vartak – Community Spotlight

We are honored to recognize Daivat Vartak as our March 2025 Community…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Kudos to the February Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,516 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,409 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans