You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/// <param name="startTime">Start time of the time period</param>
18
18
/// <param name="endTime">End time of the time period</param>
19
19
/// <returns>An <see cref="Task{IEnumerable}{GridEmissionDataPoint}"/> which contains all emissions data points in a period.</returns>
20
20
/// <exception cref="WattTimeClientException">Can be thrown when errors occur connecting to WattTime client. See the WattTimeClientException class for documentation of expected status codes.</exception>
/// <param name="startTime">Start time of the time period</param>
28
28
/// <param name="endTime">End time of the time period</param>
29
29
/// <returns>An <see cref="Task{IEnumerable}{GridEmissionDataPoint}"/> which contains all emissions data points in a period.</returns>
30
30
/// <exception cref="WattTimeClientException">Can be thrown when errors occur connecting to WattTime client. See the WattTimeClientException class for documentation of expected status codes.</exception>
/// <returns>An <see cref="Task{Forecast}"/> which contains forecasted emissions data points.</returns>
38
38
/// <exception cref="WattTimeClientException">Can be thrown when errors occur connecting to WattTime client. See the WattTimeClientException class for documentation of expected status codes.</exception>
/// <returns>An <see cref="Task{Forecast}"/> which contains forecasted emissions data points.</returns>
46
46
/// <exception cref="WattTimeClientException">Can be thrown when errors occur connecting to WattTime client. See the WattTimeClientException class for documentation of expected status codes.</exception>
/// <param name="requestedAt">The historical time used to fetch the most recent forecast generated as of that time.</param>
54
54
/// <returns>An <see cref="Task{Forecast}"/> which contains forecasted emissions data points or null if no Forecast generated at the requested time.</returns>
55
55
/// <exception cref="WattTimeClientException">Can be thrown when errors occur connecting to WattTime client. See the WattTimeClientException class for documentation of expected status codes.</exception>
/// <param name="requestedAt">The historical time used to fetch the most recent forecast generated as of that time.</param>
63
63
/// <returns>An <see cref="Task{Forecast}"/> which contains forecasted emissions data points or null if no Forecast generated at the requested time.</returns>
64
64
/// <exception cref="WattTimeClientException">Can be thrown when errors occur connecting to WattTime client. See the WattTimeClientException class for documentation of expected status codes.</exception>
/// Async method to get the balancing authority for a given location.
68
+
/// Async method to get the region for a given location.
69
69
/// </summary>
70
70
/// <param name="latitude">Latitude of the location</param>
71
71
/// <param name="longitude">Longitude of the location</param>
72
-
/// <returns>An <see cref="Task{BalancingAuthority}"/> which contains the balancing authority details.</returns>
72
+
/// <returns>An <see cref="Task{region}"/> which contains the region details.</returns>
73
73
/// <exception cref="WattTimeClientException">Can be thrown when errors occur connecting to WattTime client. See the WattTimeClientException class for documentation of expected status codes.</exception>
/// Async method to get the balancing authority abbreviation for a given location.
77
+
/// Async method to get the region abbreviation for a given location.
78
78
/// </summary>
79
79
/// <param name="latitude">Latitude of the location</param>
80
80
/// <param name="longitude">Longitude of the location</param>
81
-
/// <returns>A string which contains the balancing authority details.</returns>
81
+
/// <returns>A string which contains the region details.</returns>
82
82
/// <exception cref="WattTimeClientException">Can be thrown when errors occur connecting to WattTime client. See the WattTimeClientException class for documentation of expected status codes.</exception>
/// <returns>An <see cref="Task{Stream}"/> which contains the binary data stream of the .zip file.</returns>
90
90
/// <exception cref="WattTimeClientException">Can be thrown when errors occur connecting to WattTime client. See the WattTimeClientException class for documentation of expected status codes.</exception>
/// <returns>An <see cref="Task{Stream}"/> which contains the data Stream of the .zip file.</returns>
98
98
/// <exception cref="WattTimeClientException">Can be thrown when errors occur connecting to WattTime client. See the WattTimeClientException class for documentation of expected status codes.</exception>
varbaValue=awaitJsonSerializer.DeserializeAsync<RegionResponse>(result,_options)??thrownewWattTimeClientException($"Error getting Balancing Authority for latitude {latitude} and longitude {longitude}");
varregionResponse=awaitJsonSerializer.DeserializeAsync<RegionResponse>(result,_options)??thrownewWattTimeClientException($"Error getting Region for latitude {latitude} and longitude {longitude}");
Copy file name to clipboardExpand all lines: src/CarbonAware.DataSources/CarbonAware.DataSources.WattTime/src/Client/WattTimeClientHttpException.cs
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -22,7 +22,7 @@ public WattTimeClientHttpException(string message, HttpResponseMessage response)
22
22
/// Gets the status code for the exception. See remarks for the status codes that can be returned.
23
23
/// </summary>
24
24
/// <remarks>
25
-
/// 400: Returned when the lattitude/longitude provided aren't associated with a known balancing authority.
25
+
/// 400: Returned when the lattitude/longitude provided aren't associated with a known region.
26
26
/// 401: Returned when no authorization header is passed. You should not expect to receive this status code.
27
27
/// 403: Returned when an invalid username or password is used for login. Please check your configuration and verify your account when this error is received.
28
28
/// 429: Returned when the number of requests has exceeded the WattTime rate limit, currently at 3,000 per rolling 5 minute window. For current limits, see https://www.watttime.org/api-documentation/#restrictions
Copy file name to clipboardExpand all lines: src/CarbonAware.DataSources/CarbonAware.DataSources.WattTime/src/Configuration/WattTimeClientConfiguration.cs
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -32,10 +32,10 @@ internal class WattTimeClientConfiguration
0 commit comments