Question Website purchase solutions

raysefo

Well-known member
Joined
Feb 22, 2019
Messages
191
Programming Experience
10+
Hi guys,

I have a web API as you will remember, that calls 3rd party web APIs in order to get online game codes that work on a market chain. Now, I would like to integrate my web API to this local website which sells lots of stuff including online game codes. In the market chain, my web API is being called from cashiers by using payment terminals. But on the other hand, I have to query the online website web API in order to get the online game code orders that are paid. I am planning to write a job that queries this online website web API for every 10 minutes in order to check if there are paid orders. Then call 3rd web APIs and continue other operations. What are your suggestions/solutions?

Best Regards.
 

Skydiver

Staff member
Joined
Apr 6, 2019
Messages
1,575
Location
Virginia Beach, VA
Programming Experience
10+
How expensive (time, memory, money) is it to query the 3rd party API on demand rather than every 10 minutes? Are you batching because you have a set number of calls to the 3rd party per day?
 

raysefo

Well-known member
Joined
Feb 22, 2019
Messages
191
Programming Experience
10+
I don't know when the online game code is purchased, I have to query the online website API in order to find out if online game codes are purchased from their website. That is why I am planning to write a job.
 

Skydiver

Staff member
Joined
Apr 6, 2019
Messages
1,575
Location
Virginia Beach, VA
Programming Experience
10+
If you are truly integrated with that website, why can't they call your web API the same way the market chain calls your web API? Why do you need to poll the website's web API to determine if you need to do anything? Is your web API so complicated that the web site cannot call you?
 

raysefo

Well-known member
Joined
Feb 22, 2019
Messages
191
Programming Experience
10+
Unfortunately, they don't have such a service. Their functioning is structured in this way.
 

Skydiver

Staff member
Joined
Apr 6, 2019
Messages
1,575
Location
Virginia Beach, VA
Programming Experience
10+
Then it seems like you have no choice other than to poll. But you do have a choice between polling and then calling your web service API normally which in turn will call the 3rd party, or polling and then calling the 3rd party.
 
Top Bottom