Skip to main content

Notifications

Microsoft Dynamics CRM (Archived)

Call an external Web Service from Plugin - Dynamics crm ONLINE

Posted on by 510

Hi all.

I'm facing a Permission error when i try to call an external WebService from my plugin.

Notes:
1. The web service was developed by another company and they said that they could not put a friendly name (dns) for this url
2. The web service is on IP format (http://200.279.18......).

So, for a temporary solution, i did a Windows Scheduler console APP that runs every 1min calling the Web Service and update the Quote entity. But i need this web service executing on real time.

Any help?

*This post is locked for comments

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Call an external Web Service from Plugin - Dynamics crm ONLINE

    Hi Henrique,

    I too am facing the same issue. I tried all ways but its giving me the same error.

    Can you send me the plugin code on prerak.parikh1@gmail.com

    Thanks in advance.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Call an external Web Service from Plugin - Dynamics crm ONLINE

    Hi, Henrique. Kindly send me the sample code of plugin to thetpaingsoe.mz67@gmail.com.

    Thanks for your help.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Call an external Web Service from Plugin - Dynamics crm ONLINE

    Hello Henrique! Could you kindly send me the code of the plugin to pinnintisantosh@gmail.com? Thank you in advance.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Call an external Web Service from Plugin - Dynamics crm ONLINE

    Hi

    I'm also very interested in the sample code: casperschau@gmail.com

    Thank you in advance!

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Call an external Web Service from Plugin - Dynamics crm ONLINE

    Hi Henrique,

    I have a similar issue. I have to pass certain data to an external web service. But I cannot call it directly due to sandbox issue.

    Will be it possible for you to share a complete sample code with me? My email address is siddharthgupta255@gmail.com

  • Jf Marwen Profile Picture
    Jf Marwen 75 on at
    RE: Call an external Web Service from Plugin - Dynamics crm ONLINE

    please send me code example (marwenjaffel@gmail.com)

  • RE: Call an external Web Service from Plugin - Dynamics crm ONLINE

    Hi guys, 

    this is and extract from the code of a CWA that invokes an external WCF with basic authentication. Before writing the code I added a service reference with the generation of message contracts

    BasicHttpBinding binding = new BasicHttpBinding(BasicHttpSecurityMode.TransportCredentialOnly);
    binding.Security.Transport.ClientCredentialType = HttpClientCredentialType.Basic;
    binding.Security.Message.ClientCredentialType = BasicHttpMessageCredentialType.UserName;
    
    
    
    EndpointAddress endPointAddress = new EndpointAddress("localhost/TestService.svc");
    
    
    
    TestServiceClient client = new TestServiceClient(binding, endPointAddress);
    client.ClientCredentials.UserName.UserName = "username";
    client.ClientCredentials.UserName.Password = "password";
    
    
    
    OperationRequest request = new OperationRequest();
    
    ........
    
    OperationResponse response = client.Operation(request);


    Hope this helps.

  • ayush kar Profile Picture
    ayush kar 2,654 on at
    RE: Call an external Web Service from Plugin - Dynamics crm ONLINE

    Hi, Could you please send me the solution code to gmail karayush2011@gmail.com

  • Rashi Saxena Profile Picture
    Rashi Saxena 95 on at
    RE: Call an external Web Service from Plugin - Dynamics crm ONLINE

    Hi,

    We are also facing the same issue. Could you please share the code with us?

    Can you please send it rashisaxena29@gmail.com?

    Thanks,

    Rashi

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Call an external Web Service from Plugin - Dynamics crm ONLINE

    hi can you please provide me sample code to alekyank@outlook.com

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!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,149 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans