Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

285
Views
Microsoft Outlook Add-in can't extract/pass data to a localhost server via Ajax

I'm trying to build an Outlook add-in for encrypting/decrypting emails. The Add-in itself uses a web app, which in turn uses Javascript. I basically want to pass the unencrypted/encrypted email to a local server running python using GET/POST requests, perform some encryption/decryption on it in python, and then pass it back to Outlook Add-in. The problem is that the Add-in just won't pass any data to the local server nor get something in return. I have tried to work with both Django and Flask with the same results. I also configured the local servers to use locally-generated certificates and keys with no improvement. I even tried routing the HTTP connection using ngrok, but none came of it.

Server response to GET request on HTTP

Server response to GET request on HTTPS using Werkzeug

The code given below never returns "Here5" on item-status. Clearly the success snippet isn't being run.

 $.ajax({
            url: "https://127.0.0.1:8000/getPost/hello/",
            type: 'GET',
            dataType: 'json', // added data type
            success: function (res) {
                $('#item-status').text("Here5");
                $('#item-message').text(res);
            }
        });

I've also added the required URLs in the App Domain part of the manifest file:

<AppDomain>https://127.0.0.1:8000/getPost/hello/</AppDomain>

The Add-in performs fine when running GET requests from other sites on the internet, like: https://api.github.com/users However, I just can't seem to run it on my local server. How do I solve this?

Edit: After some debugging, I've learned that XMLHttpRequest status is 0 and responseText is empty. I think it might have something to do with CORS. Am I correct in that assumption? If yes, then how do I disable Cross Origin for localhost in this particular case?

Thank You

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!