Testing Dynamics CRM Online Service with SoapUI
Hi and thanks for reading my problem and maybe giving me some help!
I am working on a school project and I have to program a web application based on PHP / SOAP calls to a dynamic CRM server of a company. The number of problems I've encountered is astounding and it seems almost impossible to find a decent tutorial-style page on the internet about this. (Trust me, I tried)
Another background you should know: I have no idea how to work with SOAP, web application endpoints, even PHP is not what I'm familiar with. Keep this in mind ...
One recent issue is the SoapUI program (4.5.1, both free and Pro) causing rendering issues - possibly a hardware accelerated graphics issue as I had a very similar issue with Visual Studio 2012 and disabling this options Fixed. There seems to be no way to do this in SoapUI (neither in my catalyst control center, nor in screen resolution> advanced> troubleshooting "settings" - this is greyed out)
Anyway, this is beyond the point. I can deal with making me nuts for a couple more days before finding another computer to work with.
I "simulated" this CRM server by creating a trial account for an online CRM program. I am now trying to send some general requests to a web service using SoapUI (both SoapUI 4.5.1 and SoapUI Pro 4.5.1, 14 days trial). Step by step, here's what I did within the program:
1-Create a new project
a) named it "MSCRMOnlineTest"
b) As "Initial WSDL", I added a WSDL file saved locally on my machine. This file was downloaded from my CRM Online Trial account under Setup> Developer Resources> Organization Service. To clarify, this is the file obtained by going to this link: https: // {OrganizationName} .api.crm4.dynamics.com / XRMServices / 2011 / Organization.svc? Wsdl = wsdl0
c) The only key pressed was the very first one ("Create query templates for all operations?")
Now I had a list of 8 operations with each request auto-generated named "Request 1"
2-Add endpoint
a) I opened request 1 from Retrieve (seemed like a good place to start - getting some data)
b) Chose the message "no endpoint set" a top, so I decided to add it. I added:
https: //? {OrganizationName} .api.crm4.dynamics.com / XRMServices / 2011 / Organization.svc = wsdl0 WSDL
I know this is weird just like the link I got the WSDL file from, but was that the only sane option?
3-Enter your credentials and run the test
a) Paste your login credentials in the "Query Properties" box in the lower left corner. This is the exact information I use to log into the CRMOnline environment in a browser.
b) I pressed the play button (yey, something familiar!) and saw that a message was sent to the request (response time 249 ms, 576 bytes).
c) Examined the XML output, which boiled down to the following:
http://www.w3.org/2005/08/addressing/soap/fault s: Sender a: InvalidSecurity An error occurred while checking the security for the message.
4-Passed step 3 24 times with my computer set in each time zone
This is because this is a common reason for this error code. Not that it helped anyone, it stayed exactly the same
My questions:
- Have I used all the correct links / files / credentials / settings?
- How do I fix this error, or at least find some decent sources that can help me?
- I'll go back a bit to find out what all my soap messages should look like? In the meantime, there is no need to worry about it.
- How can I proceed?
- What else do I need to use in the .php website? (that is, when the user enters his login and can choose to "get data" to be displayed and liked).
If you need more information, do not hesitate to ask
Quick answers were appreciated - this project drove me crazy for about 20 hours with virtually no answers and many mysteries that need to be solved.
Cheers
Ward
source to share
Find the step to get the full CRM endpoint url https://social.technet.microsoft.com/wiki/contents/articles/2739.how-to-get-full-wsdl-schema-for-organization-service-in- microsoft-dynamics-crm-2011.aspx
Regard Kumar
source to share