dsc

REST API CORS Headers

Discussion created by dsc on Jun 1, 2017
Latest reply on Jun 29, 2017 by beverly

Hello everyone,

 

I've been testing the REST API for a while and I have a question regarding calling the REST API from non same domain service.

 

Let me describe my issues:

I've made a test HTML file where I make some AJAX calls to my test FileMaker database. In this case I'm just posting my login information and the layout I want to target to receive a token. If I place this file on the server where I also host the REST API, I've no problems getting the token. I can do this through http:// and https:// without issues

 

If I place the exact same file on another server, or on my local PC, I get a HTTP 405 "Method not allowed" response.

 

I've attached an example screenshot.

 

Can this be caused by the server hosting the REST API not having a proper SSL certificate or is there somewhere on the server or in the server files where I can edit the headers to allow specific domains to make calls to the REST API?

Attachments

Outcomes