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 :
Microsoft Dynamics CRM (Archived)

Calling custom WEB api from JavaScript

(1) ShareShare
ReportReport
Posted on by

Hi 

We have written new Web API service and it has POST methods.  We deployed it in one server.  CRM domain is enabled from this server.

We are trying to access API this API from HTML webresource in CRM using Javascript  but not able to call and getting below error

XXXXX_Jquery-3.3.1:9600
Mixed Content:
The page at 'abcd.dynamics.com/.../ABC.html' was loaded over HTTPS, but requested an insecure XMLHttpRequest endpoint 'testdomain/.../TestApi'.
This request has been blocked; the content must be served over HTTPS.

We have tried to provide the self sign certificate getting error - 

  • failed to load resource: net::err_cert_authority_invalid

Could please let me know how to resolve this ? 

Thanks

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    RaviKashyap Profile Picture
    55,410 Moderator on at

    Hi,

    Based on the error message "This request has been blocked; the content must be served over HTTPS", it looks like you are calling the service as http whereas it is hosted as https. Did you try change it to https?

    Hope this helps

  • Community Member Profile Picture
    on at

    Hi

    I have used the self signed certificate and assigned to WEB API in web server.   But it gives error like

    "failed to load resource: net::err_cert_authority_invalid"

    The certificate is created locally and not provided by any Certificate Authority. This might be reason for above one.

    Please let me know how we can remove this error ?

    Thanks

  • Suggested answer
    Dynamics365 Rocker Profile Picture
    7,755 on at

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 > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans