OpenWeatherMap Get data for today - openweathermap

I am trying to create something similar to what the weather apps have which show a graph of the temperatures from today.
I am currently using the onecall endpoint which returns the current weather along with forecasts for the next 48 hours but this doesn't cover my case of showing earlier data from the day.
Am I miss using this endpoint or is there a way to show the data for the current day (both historical from earlier and forecast for later)? Or do I need to use the historical data endpoints?

Related

Openweather api differnce hourly and now

I am trying to get the local hourly forecast however the weather at 0 hours is very different to weather now for the same location. Please see below the url and result
https://api.openweathermap.org/data/2.5/onecall?lat=51.5736&lon=0.03287&exclude=daily,minutely,current,alerts&units=metric&appid={mykey}
First hour (ie now)
{"lat":51.5736,"lon":0.0329,"timezone":"Europe/London","timezone_offset":0,"hourly":
{"dt":1675846800,"temp":2.31,"feels_like":2.31,"pressure":1037,"humidity":83,"dew_point":-0.24,"uvi":0.36,"clouds":81,"visibility":10000,"wind_speed":1.32,"wind_deg":186,"wind_gust":2.49,"weather":[{"id":803,"main":"Clouds","description":"broken clouds","icon":"04d"}],"pop":0},
https://api.openweathermap.org/data/2.5/weather?lat=51.5736&lon=0.03287&units=metric&appid={mykey}
{"coord":{"lon":0.0329,"lat":51.5736},"weather":[{"id":741,"main":"Fog","description":"fog","icon":"50d"}],"base":"stations","main":{"temp":2.14,"feels_like":2.14,"temp_min":-3.07,"temp_max":6.78,"pressure":1037,"humidity":88},"visibility":150,"wind":{"speed":1.03,"deg":0},"clouds":{"all":100},"dt":1675849786,"sys":{"type":1,"id":1414,"country":"GB","sunrise":1675841260,"sunset":1675875628},"timezone":0,"id":2633658,"name":"Woodford","cod":200}
As you can see there's a big difference in the weather (is visibility). The weather now seems correct, the hourly seems wrong compared to what it is actually like here now. Am I doing something wrong?

BigQuery Weather Public Data Sets - Missing Last Few Days Data

I have run some queries against BigQuery public data sets for weather. I have used both GSOD (bigquery-public-data.noaa_gsod.gsod2019)and GHCN (bigquery-public-data.ghcn_d). In both cases, the most recent data I get is from 4 or 5 days ago. Why is that? What can I do to get more recent historic data e.g. this morning or yesterday by lat and long.
Those historical datasets are provided by NOAA a few days delayed. For real-time weather, you have to use one of the commercial weather data providers in the Marketplace.

Coinbase API v2 Getting Historic Price for Multiple Days

I'm having some trouble with a Coinbase.com API call for historical data.
Previously, I was getting a variable length of days that would match the amount of space available on a terminal screen with a request URL that looked like this:
https://api.coinbase.com/v2/prices/historic?currency=USD&days=76
This would pull the previous 76 days of price history. An example of the old output is here:
https://gist.github.com/KenDB3/f071a06ab3ef1a899d3cd8df8b40a049#file-coinbase-historic-days-example-2017-12-23-json
This stopped working a few days ago. The closest I can get to this is with this request URL (though I don't get the data I want):
https://api.coinbase.com/v2/prices/BTC-USD/historic?days=76
The output from this can be seen here:
https://gist.github.com/KenDB3/f071a06ab3ef1a899d3cd8df8b40a049#file-coinbase-historic-days-example-2018-07-19-json
In the second example, it is just displaying prices from the day of the query at different times of that day. What I really want is the first example output where it gives a single price per day going back as many days as the request is for.
The project this is connected to is here:
https://github.com/KenDB3/SyncBTC
Links that do not work:
https://api.coinbase.com/v2/prices/historic?currency=BTC-USD&days=76
(No Results)
https://api.coinbase.com/v2/prices/BTC-USD/historic?2018-07-15T00:00:00-04:00
(Does not pull data from 7/15/2018)
Any reason you aren't using coinbase pro?
The new api is very easy to use. Simply add the get command you want followed by the parameters separated with a question mark. Here is the new historic rates api documentation:
https://docs.cloud.coinbase.com/exchange/reference/exchangerestapi_getproductcandles
The get command with the new api most similar to prices is "candles". It requires three parameters to be identified, start and stop time in iso format and granularity which is in seconds. Here is an example:
https://api.pro.coinbase.com/products/BTC-USD/candles?start=2018-07-10T12:00:00&end=2018-07-15T12:00:00&granularity=900
EDIT: also, note the time zone is not for your time zone, I believe its GMT.
Here is a wrapper for the CoinBase API for the export of Historical Data: https://pypi.org/project/Historic-Crypto/
It should provide the required outcome through invoking:
pip install Historic-Crypto
from Historic_Crypto import HistoricalData
new = HistoricalData('ETH-USD',300,'2020-06-01-00-00').retrieve_data()
for a full list of cryptocurrencies available:
pip install Historic-Crypto
from Historic_Crypto import Cryptocurrencies
data = Cryptocurrencies(extended_output=False).find_crypto_pairs()

Report of actuals entered by date

I need to pull out a report of the actuals that is being entered by each person in my team date-wise in the time span which I am allowed to specify. Its basically not for any accounting purposes but just to monitor the effort entered by each user on a day.
The closest thing I have found based on my preliminary search is the Weekly Actuals custom report(https://help.rallydev.com/weekly-actuals-report).
But it doesn't show the date-wise information. Is there any app already developed for my requirement or should I need to tweak the weekly actuals report?
Note: Not interested to install the time-tracker module since most of the users in my organization are used to tracking effort through actuals.
Rally LookbackAPI will give you historic data. You may write an app using shapshot store intended to retrieve data from the Lookback API.
Here is a LookbackAPI endpoint that returns snapshots where Actuals were updated:
https://rally1.rallydev.com/analytics/v2.0/service/rally/workspace/111/artifact/snapshot/query.js?find={"Project":222,"_TypeHierarchy":"Task","_PreviousValues.Actuals":{$exists: true},_ValidFrom:{$gte: "2014-05-01T00:00:00.000Z",$lt: "2014-05-13T00:00:00.000Z"}}&fields=["_UnformattedID","Actuals","_PreviousValues.Actuals","_ValidFrom","_ValidTo"]
and an example of the returned result:
Results: [
{
_ValidFrom: "2014-05-12T17:08:27.598Z",
_ValidTo: "9999-01-01T00:00:00.000Z",
_UnformattedID: 157,
Actuals: 4,
_PreviousValues: {
Actuals: 0
}
}
]
where _ValidFrom: "2014-05-12T17:08:27.598Z" indicates the time when the snapshot was created - the Actuals was updated. Since this was the last change to Actuals on this task TA157, the _ValidTo is set to infinity. The result shows both the updated value (4) and previous value (0) of Actuals.
To try this endpoint make sure to change 111 and 222 with valid ObjectIDs of your workspace and project respectively.
There is a similar question about ToDo answered in this post.
It is possible to get some historic data by parsing revision history via Web Services API and looking for CreationDate on a revision where Actuals update was recorded. See 'side note' in this post. But this is expensive and inefficient.
Weekly Actuals is a legacy app based on AppSDK1. AppSDK1 cannot access LookbackAPI.

Rally web service API: get Hierarchical Requirements from a specific day in an Iteration

Is it possible to get the user stories (Hierarchical Requirements) from a specific day in an iteration using the Rally Web Service API? I'm developing a java application which will generate a history chart for an iteration. For example if the iteration was 14 days long, I need to get the Hierarchical Requirements with all their attributes for each day in that iteration, something like: [day1,Hierarchical Requirements], [day2,Hierarchical Requirements], and so on.
Check out the IterationCumulativeFlowData object in the WSAPI.
https://rally1.rallydev.com/slm/doc/webservice/
That should give you the total number of items and their todo/estimate totals for each day.