json rest api, locally hosted, lan accessible - json

For some time now I try to figure it out how to create a json rest api and a database, host it locally and make it accessible in lan. I need this for an android app, exactly to parse data from database to app.
I created the json rest and database usimg XAMP but i didn't figure it out how to make them accessible from lan.
After that somebody recomanded me IIS and since then I did'n figure it out.
Some sugestions?

For the web api application, host in the IIS server in some other system. In the mobile application development environment is in same LAN network, then call the api using that web api system ipaddress instead of the localhost.

Related

Exposing React App with Local MySQL Database to Internet Using Ngrok

I am very new to ngrok, so please bear with me.
I have a very simple React test app that is using Django as a server and local MySQL database. Django pulls/inserts some info from the local database and sends to the frontend. Everything works well.
What I'm trying to do is expose this local app to public Internet. I have successfully installed and configured Ngrok, established a tunnel and was able to view the app on a different computer through the address generated by Ngrok. The problem is, I was able to see only the UI that is not related to the database. All data that React pulls from the local database, was not visible when I used a different computer. My question is, is there a way to use the same app through Ngrok and get the same data from the local MySQL database that I see when I just run the app locally? I know that I can create another tunnel that exposes the port MySQL or Django are running on (3306 and 8000 respectively) but if I do this, how would I access the data through Ngrok? Would I need to change anything in React code?
Thank you in advance!

Node JS Deploying API to client without any Front End

If i created api in nodejs like login,registration,delete,add,update user like system and i want to give it to my client how can i deploy it??
Like we run our API's on POstman so how client will use it! I don't want to add any front End to it.
You have a few options... you can go for heroku or a virtual private server. For vps you have options like aws ec2, google cloud platform etc. You can host your app in a vps with a static ip. You can use pm2 to host the app. Https is better. Use an nginx reverse proxy for security. Proffesional api servers do the above...

Node.js Server (Mobile Client)

I am trying to make a Data Monitoring with Mobile App.
I have a mysql database and i am planning use Node.js server.
My project:
Node.js server connect to mysql db.
Mobile apps connect to node.js server and when the new data add to mysql, node.js server send to data mobile apps using restful service.
Is it possible to communicate between node.js server and firemonkey mobile client apps? (I' ll build mobile apps via firemonkey - Delphi)
The reason to use push notifications, is so that your Mobile app does not waste resources to maintain constant connection to the server awaiting for new data, whether it is a web socket or a check for new data.
Keep in mind that Push notifications code might be different for Android and iOS platforms.

phonegap external storage

I am using phonegap to make iphone and android apps. I need to be able to store data on a mysql database on my server as well as use my websocket server.
How can I go about doing this as the app will be running on local html and javascript files which cant run ajax/websocket requests on external servers?
So let me convert my comments into an answer.
You need a client-server architecture, where the clients will be all your end devices. The server in this case needs to be a globally reachable host somewhere (Amazon cloud, perhaps?).
Your device will send updates to the backend server that has a connection to your database, using ajax calls. These updates will be stored on the server.
All your other clients need to periodically poll the same backend server using ajax, and will get the updates sent from your primary device.

Hosting a Silverlight database application that works with MySQL

I have a basic hosting package that gives me access to create a MySQL database. I can of course host silverlight applications on any site. But how can I work with a database from within Silverlight? I cannot run any service on my hosting provider, they only allow php or perl scripts.
You can use the C# webclient to make HTTP calls to a PHP page hosted on the server. The PHP page can proxy queries/results between the silverlight client and the mysql database.
remember, just because it's not a SOAP/WCF "service" does not mean that it's not a web service. Look into PHP based REST solutions for some nice alternatives that can easily be invoked via silverlight:
http://www.bing.com/search?q=PHP+REST
Edit: As #Spencer Ruport correctly points out in the comments, you of course have to be wary of the fact that the web service will be exposed to the public, and anyone can easily sniff the http traffic between your silverlight application and the server. This enable them to call your service directly so be sure to think about authentication and what it means in the context of your app/data
You can use the WebClient class in silverlight to communicate to a php service. Here is the first google result I found: link