ASP.NET Web API prototype design

Posted by Honey5 under ASP.NET on 1/23/2018 | Points: 10 | Views : 702 | Status : [Member] | Replies : 0
Hi,
I am quite new to Web API and I am planning to design a prototype that I am not sure that is gonna work as expected, this is the reason why I should discuss with somebody to see if my plans are right.

The scenario is the following:

The users are having installed on their machines an application (ex a Windows Forms app).
The users will install on their machines a self-hosted WEB API
The self-hosted WEB API will expose some data from the application (the initial Windows Forms app)
The exposed data from the self-hosted WEB API is gonna be loaded and presented in a Web Page (loaded probably from a JavaScript call that needs to know the address of the self-hosted WEB API).
First, what do you think, is this a realistic scenario? Am I taking the right approach in using a self-hosted WEB API?

In most of the online tutorials the self-hosted WEB API is hosted at "http://localhost:8080" but in a real environment, this address needs to be changed. Since the WEB API in my plan tends to be more like a "client" than a "server", which address should be put instead for the self-hosted WEB API instead of the classic "localhost" so that the web page will know from where to load the exposed data?

For me that WEB API self-hosted address looks more like an internal network IP address that changes from a client machine to other and that needs to go through a firewall so that it can be accessed from a web page that is gonna be hosted on a web server.

So at this point, I cannot understand how could I get such an address, and how a "production" address for a self-hosted WEB API will look like (probably more like an internal network address rather than a web server address).

I am feeling that is something that I misunderstood and I am not sure what, that is the reason why I am asking your option.

Thank You
kosmiktechnologies.com




Responses

(No response found.)

Login to post response