Releases: spgi-ci/spgci-python
Bug Fix
EU Gas Outages
Added EU Gas Outages Endpoints:
get_outages_event
get_outages_time_series
Added Additional Chemicals Endpoints
This release includes a function to find the unique values in a given dataset. This is useful for knowing the exact values to pass to endpoints for filtering operations:
import spgci as ci
chem = ci.Chemicals()
# just a single column
chem.get_unique_values(dataset='production', columns='region')
# distinct values across multiple columns
chem.get_unique_values(dataset='capacity', columns=['region', 'commodity'])
Additional Endpoints Added:
- capacity
- production
- capacity-utilization
- demand-by-derivative
- demand-by-end-use
- trade
- inventory-change
- total-supply
- total-demand
- assumptions
- country-supply-demand-balance
- region-supply-demand-balance
- world-supply-demand-balance
Oil and NGL Analytics
Included in this version:
- Added the Oil and NGL Analytics API.
- Added
modified_date_(gte|gt|lte|lt)
as a parameter in theMarketData().get_symbols
method. - Added
sector
as a parameter in theInsights().get_heards
,get_top_news
,get_latest_news
,get_spotlights
, andget_stories
methods.
Added LNG Forecast Prices
- Updated
WorldRefineryData
to using the latest endpoint (which no longer requires an Appkey) - Added LNG Forecast Prices Endpoints
LNG Market Fundamentals
Added the LNG Market Fundamentals endpoints:
Hub Balances and Removed ApiKey
Important
This release removes the ApiKey usage. You can still pass it in, for backwards compatibility, but it is ignored.
EU Gas Analytics:
We've added hub balances
df = egp.get_overview_hub_balance(
gas_day_gte="2024-10-01",
gas_day_lte="2024-10-31",
average_type="Daily value",
hub="PEG",
uom="MCM",
)
df.pivot_table(
index=["hubFlowType", "hubSubFlowType"],
columns="dayMonthOrdinal",
values="quantity",
)
(example from readme)
A few things to note on these endpoints:
- it's recommended to specify a
uom
, otherwise you will get duplicate records - Also, to specify a
direction
where supported. - we introduced a custom sort function for the
dayMonthOrdinal
field, so that the above pivot table columns are sorted sensibly.
Updated Outages, Added Assets and Contracts
This release is a breaking change. The previous get_outages
within LNGGlobalAnalytics was removed by the API, so therefore stopped working. In this change we have replaced it. The function name is the same, but the parameters and output are slightly different. The same applies for the get_ref_data
function. This was removed and now there are individual functions for get_liquefaction_projects
and get_liquefaction_trains
In addition, the LNG Assets and Contracts endpoints are now supported.
This includes 18 different functions. all prepended with get_asset_contracts_
- get_assets_contracts_feedstock
or get_assets_contracts_monthly_estimated_buildout_liquefaction_capacity
so they should be easy to find in intellisense.
LNG - Supply & Demand, Cargos
Added more functions to the LNGGlobalAnalytics
class:
Supply and Demand:
get_supply_forecast_current
- Latest supply forecast (project by project) per month.get_supply_forecast_history
- Historical supply forecasts (project by project) per month.get_demand_forecast_current
- Latest demand forecast (market by market) per month.get_demand_forecast_history
- Historical demand forecast (market by market) per month.
Cargos:
get_cargo_historical_bilateral_trade_flows
- Historical monthly aggregated volume data showing country to country flows.
get_cargo_trips
- Completed commercial journeys of (LNG) vessel from point A to point B.
get_cargo_events_partial_load
- Occurrences involving the loading of a portion of LNG cargo during a Transportation process.
get_cargo_events_partial_unload
- Incidents related to the partial unloading of LNG cargo during transportation.
get_cargo_events_partial_reexport
- Instances where a fraction of the initially imported LNG is re-exported during the transportation process.
get_cargo_waterborne_trade
- LNG cargos by load and arrival date as well as numerous volumetric, geographic, and commercial attributes