J
J
jopayoruya2017-05-16 03:05:27
API
jopayoruya, 2017-05-16 03:05:27

How to use your API server on other domains?

Hello. Got a question. Can I use the API server that I set up on one domain to use on other domains? GET, POST requests, over HTTPS. Server on Express, for example. Please don’t kick me for stupid questions, I didn’t have much experience with the backend, and I almost never worked with HTTP at all.
What difficulties will I face? CORS etc? So in general it is possible to do, is this a normal architecture?
I want to use it to receive content (like a JSON server) and authorize, save users, messages to the database, and generally backend logic, such as transactional emails and everything that requires third-party APIs, services. Use on static sites.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vitaly, 2017-05-16
@vshvydky

the server must have the header Access-Control-Allow-Origin
awareness will come from here

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question