I'm using the WhitePages API ( developer.whitepages.com ) to get a phone type (landline or cellular) and the phone's service provider (Verizon, T-Mobile, etc), but they only have a personal API which limits you to 2 calls a second and/or 1,500 calls a day. The paid version, or "Pro", is a minimum of $500 a month and/or $0.10 a call.
Does anyone know another service where I can get that information for free or cheaper than $500 / $0.10 a call? If not I'll have to try to cache everything and it'll technically be against their TOS...
We've tried using NetNumber and TargusInfo. Maybe you want to look at them. Not sure how much they cost though.
How much volume are you trying to do?
Related
I have a solana program that will transfer some amount. After agreeing to the amount to transfer, the transaction will take place a little later. Few hours to few days. Is there a way my solana smart contract can put a hold/lock kind of enforcement to make sure the funds are available when the transaction takes place ?
You are looking for an escrow smart contract.
One example that is really well explained is this one https://github.com/paul-schaaf/solana-escrow
There are a few existing solutions that will do this for you, including the Bonfida token-vesting program and the Streamflow timelock program.
You can find more information about these programs at https://spl.solana.com/token#token-vesting
The idea is to move the tokens to an account owned by the timelock / vesting program, and then these funds are unblocked after a certain amount of time.
It might be really simple but I cannot figure it out. I made a little script that is able to upload some photos/video using rest API.
Since they all count towards the storage quota (15gb free) I would like to query the remaining free space.
How do I do this?
You can retrieve your storage quota with the method About:get, setting the query parameter fields to storageQuota
This will give you the following information:
Your remaining quota can be calculated as "limit" - "usage", in my case around 1,5 GB which is in agreement with the information I can see from the user interface in Google Drive and Google Photos.
I am trying to figure out what is the fastest way the figure out the current user Country. I know there are a lot of location examples online, my actual is question: since I don't care much about precision, is it OK if I use RegionInfo.CurrentRegion.DisplayName; to figure out the user country?
What are the downsides of using this approach (besides precision)?
No, you shouldn't use RegionInfo.CurrentRegion for that.
For example, I live in Montenegro, but RegionInfo.CurrentRegion on my phone will return USA, which is completely irrelevant being almost 4000 miles away from here.
You have to use Geolocator class for that. Here's some sample code.
I am using API to get ec2 spot price history, but I cannot get anything except for last 90 or so days, and cannot specify frequency of observations. Is there a way to get a complete history of spot prices, preferable at minute or hourly frequency?
While not explicitly documented for the DescribeSpotPriceHistory API action, this restriction is at least mentioned for the AWS Management Console (which uses that API in turn), see Viewing Spot Price History:
You can view the Spot Price history over a period from one to 90 days based on the instance type, the operating system you want the instance to run on, the time period, and the Availability Zone in which it will be launched.
Since anybody could have retrieved and logged the entire spot price history ever since this API is available (and without a doubt quite some users and researchers have done just that; even the AWS blog listed some dedicated Third-Party AWS Tracking Sites, but these are all defunct at first sight), this restriction admittedly seems a bit arbitrary, but is certainly pragmatic from a strictly operational point of view, i.e. you have all the information you need to base future bids upon (esp. given AWS has only ever reduced prices so far, and regularly does so in fact much to the delight of its customers).
Likewise there's no option to change the frequency, so you'd need to resort to client side code for the hourly aggregation.
This website has re-sampled EC2 spot price histories for some regions, you may access them via a simple API directly from your Python script:
http://ec2-spot-prices.ai-mmo-games.de/
I hope this helps.
AWS only provides 90 days of history. And the data is raw, i.e., not normalized by hour or even minute. so there are holes in the data sometimes.
One approach would be to suck in the data into an ipython notebook and use pandas excellent time series tools to resample by minute or 5-min etc. here's a short tutorial:
https://medium.com/cloud-uprising/the-data-science-of-aws-spot-pricing-8bed655caed2
here are more details on using pandas for time-series resampling:
http://pandas.pydata.org/pandas-docs/stable/timeseries.html
hope that helps...
I've got a list of 6,000 company names (along with their headquarters address) and I need to find the web address for each of them. I'm considering using the Google Web API (obviously this will take a few days as only 1,000 queries per day are allowed) to do this(search for "COMPANY_NAME CITY STATE") and then take the first result. However I'm not 100% sure this will work, and I feel like there's a better way. I can do this in any language I know really, C++, Java, PHP, Python. This only has to be run once.
How would I use WHOIS to do this? I know how I would do it if I already knew the URL, but not the other way around(name to URL). And what would I do if it were privately registered?
BTW, these are US businesses.
You can use WHOIS instead of Google API for it.
Use Amazons Mechanical Turk. It's perfect for these kinds of tasks which can be hard to automate and typically need a person to validate them. It will cost a little but it should be manageable, depending on how bad you want the results.