API Documentation of the DataBridges platform: https://databridges.vam.wfp.org/. For API discussions and details: #api-integration-vam-data-bridges on Slack, Teams channel API Integration - This endpoint uses Hey Jude pattern
This Python package is automatically generated by the OpenAPI Generator project:
- API version: 7.0.0
- Package version: 1.0.0
- Generator version: 7.8.0
- Build package: org.openapitools.codegen.languages.PythonClientCodegen
Python 3.7+
If the python package is hosted on a repository, you can install directly using:
pip install git+https://github.com/WFP-VAM/DataBridgesAPI.git(you may need to run pip with root permission: sudo pip install git+https://github.com/WFP-VAM/DataBridgesAPI.git)
Then import the package:
import data_bridges_clientInstall via Setuptools.
python setup.py install --user(or sudo python setup.py install to install the package for all users)
Then import the package:
import data_bridges_clientExecute pytest to run the tests.
Please follow the installation procedure and then run the following:
import data_bridges_client
from data_bridges_client.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to https://api.wfp.org/vam-data-bridges/7.0.0
# See configuration.py for a list of all supported configuration parameters.
configuration = data_bridges_client.Configuration(
host = "https://api.wfp.org/vam-data-bridges/7.0.0"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.access_token = os.environ["ACCESS_TOKEN"]
# Enter a context with an instance of the API client
with data_bridges_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = data_bridges_client.CommoditiesApi(api_client)
country_code = 'country_code_example' # str | The code to identify the country. It can be a ISO-3166 Alpha 3 code or the VAM internal admin0code (optional)
category_name = 'category_name_example' # str | The name, even partial and case insensitive, of a commodity category. (optional)
category_id = 0 # int | The exact ID of a Commodity, as found in /Commodities/List. (optional) (default to 0)
page = 1 # int | page number for paged results (optional) (default to 1)
format = 'json' # str | Output format: [JSON|CSV] Json is the default value (optional) (default to 'json')
env = 'env_example' # str | Environment. * `prod` - api.vam.wfp.org * `dev` - dev.api.vam.wfp.org (optional)
try:
# Provides the list of categories.
api_response = api_instance.commodities_categories_list_get(country_code=country_code, category_name=category_name, category_id=category_id, page=page, format=format, env=env)
print("The response of CommoditiesApi->commodities_categories_list_get:\n")
pprint(api_response)
except ApiException as e:
print("Exception when calling CommoditiesApi->commodities_categories_list_get: %s\n" % e)All URIs are relative to https://api.wfp.org/vam-data-bridges/7.0.0
| Class | Method | HTTP request | Description |
|---|---|---|---|
| CommoditiesApi | commodities_categories_list_get | GET /Commodities/Categories/List | Provides the list of categories. |
| CommoditiesApi | commodities_list_get | GET /Commodities/List | Provide the detailed list of the commodities available in DataBridges platform |
| CommodityUnitsApi | commodity_units_conversion_list_get | GET /CommodityUnits/Conversion/List | Provides conversion factors to Kilogram or Litres for each convertible unit of measure. |
| CommodityUnitsApi | commodity_units_list_get | GET /CommodityUnits/List | Provides the detailed list of the unit of measure available in DataBridges platform |
| CurrencyApi | currency_list_get | GET /Currency/List | Returns the list of currencies available in the internal VAM database, with Currency 3-letter code, matching with ISO 4217. |
| CurrencyApi | currency_usd_indirect_quotation_get | GET /Currency/UsdIndirectQuotation | Returns the value of the Exchange rates from Trading Economics, for official rates, and DataViz for unofficial rates. |
| EconomicDataApi | economic_data_indicator_list_get | GET /EconomicData/IndicatorList | Returns the lists of indicators. |
| EconomicDataApi | economic_data_indicator_name_get | GET /EconomicData/{indicatorName} | Returns the time series of values for different indicators. |
| GlobalOutlookApi | global_outlook_country_latest_get | GET /GlobalOutlook/CountryLatest | Return the latest country dataset of number of acutely food insecure (in thousands) based on WFP's Global Outlook. |
| GlobalOutlookApi | global_outlook_global_latest_get | GET /GlobalOutlook/GlobalLatest | Return the latest global dataset of number of acutely food insecure (in millions) based on WFP's Global Outlook. |
| GlobalOutlookApi | global_outlook_regional_latest_get | GET /GlobalOutlook/RegionalLatest | Return the latest regional dataset of number of acutely food insecure (in millions) based on WFP's Global Outlook. |
| HungerHotspotApi | hunger_hotspot_categories_and_indicators_get | GET /HungerHotspot/CategoriesAndIndicators | Retrieves Hunger Hotspot categories and indicators. |
| HungerHotspotApi | hunger_hotspot_data_get | GET /HungerHotspot/Data | Retrieves a paginated list of Hunger Hotspot data. |
| IncubationApi | cari_adm0_values_get | GET /Cari/Adm0Values | Retrieves a paginated list of Adm0 CARI results based on the specified indicator, administrative code, and survey. |
| IncubationApi | cari_adm1_values_get | GET /Cari/Adm1Values | Retrieves a paginated list of Adm1 CARI results based on the specified indicator, administrative code, and survey. |
| IncubationApi | household_draft_internal_base_data_get | GET /Household/DraftInternalBaseData | Get data that includes the core household fields only by Survey ID. To access this data, please contact Wael ATTIA for authorization. This endpoint will send you only data you have access to, based on permissions assigned to your application profile. The "apiKey" can be found in the profile section of the DataBridges application. |
| IncubationApi | household_full_data_get | GET /Household/FullData | Get a full dataset that includes all the fields included in the survey in addition to the core household fields by Survey ID. To access this data, please contact Wael ATTIA for authorization. This endpoint will send you only data you have access to, based on permissions assigned to your application profile. The "apiKey" can be found in the profile section of the DataBridges application. |
| IncubationApi | household_official_use_base_data_get | GET /Household/OfficialUseBaseData | Get data that includes the core household fields only by Survey ID |
| IncubationApi | household_public_base_data_get | GET /Household/PublicBaseData | Get data that includes the core household fields only by Survey ID |
| IncubationApi | household_surveys_get | GET /Household/Surveys | Retrieve 1) Survey IDs, 2) their corresponding XLS Form IDs, and 3) Base XLS Form of all household surveys conducted in a country. A date of reference, SurveyDate, for the data collection is set by the officer responsible for the upload for each survey. |
| IncubationApi | m_fi_surveys_processed_data_with_keyset_pagination_get | GET /MFI/Surveys/ProcessedDataWithKeysetPagination | Please use this endpoint only for large data retrieval - Response will include only JSON format - Get a MFI processed data in long format; levels indicate the data aggregation level 1) Normalized Score, 2) Trader Aggregate Score, 3) Market Aggregate Score, 4) Trader Median, 5) Trader Mean, 6) Market Mean; each line corresponds to one of the nine dimensions of scores plus the final MFI aggregate score; 1) Assortment, 2) Availability, 3) Price, 4) Resilience, 5) Competition, 6) Infrastructure, 7) Service, 8) Quality, 9) Access and Protection, and 10) MFI final score; the variable label describes each variable and its value range |
| IncubationApi | xls_forms_definition_get | GET /XlsForms/definition | Get a complete set of XLS Form definitions of a given XLS Form ID. This is the digital version of the questionnaire used during the data collection exercise. |
| IpcchApi | ipcch_ipcch_and_equivalent_historical_peaks_get | GET /Ipcch/IPCCHAndEquivalent-HistoricalPeaks | Retrieves a paginated list of historical IPCCH and Equivalent peaks data, optionally filtered by ISO3 country code. |
| IpcchApi | ipcch_ipcch_and_equivalent_latest_peaks_get | GET /Ipcch/IPCCHAndEquivalent-LatestPeaks | Retrieves a paginated list of the latest IPCCH and Equivalent peaks data, optionally filtered by ISO3 country code. |
| IpcchApi | ipcch_ipcch_and_equivalent_most_recent_get | GET /Ipcch/IPCCHAndEquivalent-MostRecent | Retrieves a paginated list of the most recent IPCCH and Equivalent data, optionally filtered by ISO3 country code. |
| IpcchApi | ipcch_ipcch_and_equivalent_peaks_wfp_dashboard_get | GET /Ipcch/IPCCHAndEquivalentPeaks-WFPDashboard | Retrieves a paginated list of IPCCH and Equivalent Peaks data for the WFP Dashboard. |
| IpcchApi | ipcch_ipcch_historical_data_get | GET /Ipcch/IPCCH-HistoricalData | Retrieves a paginated list of IPCCH and Equivalent Historical Data. |
| MarketPricesApi | market_prices_alps_get | GET /MarketPrices/Alps | Returns time series values of ALPS and PEWI. |
| MarketPricesApi | market_prices_price_daily_get | GET /MarketPrices/PriceDaily | Returns a daily time series of commodity market prices. |
| MarketPricesApi | market_prices_price_monthly_get | GET /MarketPrices/PriceMonthly | Returns a monthly time series of commodity market prices. |
| MarketPricesApi | market_prices_price_raw_get | GET /MarketPrices/PriceRaw | Returns original commodity market prices |
| MarketPricesApi | market_prices_price_weekly_get | GET /MarketPrices/PriceWeekly | Returns a weekly time series of commodity market prices. |
| MarketsApi | markets_geo_json_list_get | GET /Markets/GeoJSONList | Provide a list of geo referenced markets in a specific country |
| MarketsApi | markets_list_get | GET /Markets/List | Get a complete list of markets in a country |
| MarketsApi | markets_markets_as_csv_get | GET /Markets/MarketsAsCSV | Get a complete list of markets in a country |
| MarketsApi | markets_nearby_markets_get | GET /Markets/NearbyMarkets | Find markets near a given location by longitude and latitude within a 15Km distance |
| RpmeApi | rpme_base_data_get | GET /Rpme/BaseData | Get data that includes the core RPME fields only by Survey ID |
| RpmeApi | rpme_full_data_get | GET /Rpme/FullData | Get a full dataset that includes all the fields included in the survey in addition to the core RPME fields by Survey ID. |
| RpmeApi | rpme_output_values_get | GET /Rpme/OutputValues | Processed values for each variable used in the assessments |
| RpmeApi | rpme_surveys_get | GET /Rpme/Surveys | Retrieve 1) Survey IDs, 2) their corresponding XLS Form IDs, and 3) Base XLS Form of all RPME surveys conducted in a country. The date of reference, SurveyDate, for the data collection is set by the officer responsible for the upload of each survey. |
| RpmeApi | rpme_variables_get | GET /Rpme/Variables | List of variables |
| RpmeApi | rpme_xls_forms_get | GET /Rpme/XLSForms | Get a complete list of XLS Forms uploaded on the RPME in a given period of data collection. This is the digital version of the questionnaire used during the data collection exercise. |
| SurveysApi | m_fi_surveys_base_data_get | GET /MFI/Surveys/BaseData | Get data that includes the core Market Functionality Index (MFI) fields only by Survey ID |
| SurveysApi | m_fi_surveys_full_data_get | GET /MFI/Surveys/FullData | Get a full dataset that includes all the fields included in the survey in addition to the core Market Functionality Index (MFI) fields by Survey ID. To access this data, please contact [email protected] for authorization. |
| SurveysApi | m_fi_surveys_get | GET /MFI/Surveys | Retrieve 1) Survey IDs, 2) their corresponding XLS Form IDs, and 3) Base XLS Form of all MFI surveys conducted in a country. A date of reference, SurveyDate, for the data collection is set by the officer responsible for the upload for each survey. |
| SurveysApi | m_fi_surveys_processed_data_get | GET /MFI/Surveys/ProcessedData | Get a MFI processed data in long format; levels indicate the data aggregation level 1) Normalized Score, 2) Trader Aggregate Score, 3) Market Aggregate Score, 4) Trader Median, 5) Trader Mean, 6) Market Mean; each line corresponds to one of the nine dimensions of scores plus the final MFI aggregate score; 1) Assortment, 2) Availability, 3) Price, 4) Resilience, 5) Competition, 6) Infrastructure, 7) Service, 8) Quality, 9) Access and Protection, and 10) MFI final score; the variable label describes each variable and its value range |
| XlsFormsApi | m_fi_xls_forms_get | GET /MFI/XlsForms | Get a complete list of XLS Forms uploaded on the MFI Data Bridge in a given period of data collection. This is the digital version of the questionnaire used during the data collection exercise. |
- BadRequestDTO
- CariAdm0ValuesDTO
- CariAdm0ValuesDTOPagedResult
- CariAdm1ValuesDTO
- CariAdm1ValuesDTOPagedResult
- CategoriesAndIndicatorsDTO
- CommodityDTO
- CommodityPriceDTO
- CommodityProcessingDTO
- CommodityQualityDTO
- CurrencyDTO
- EconomicDataDTO
- EconomicIndicatorProperty
- EconomicIndicatorPropertyPagedResult
- ExtendedAlpsValueDto
- ExtendedAlpsValueDtoPagedResult
- Feature
- Geometry
- GlobalOutlookApiDto
- GlobalOutlookCountryApiDto
- GlobalOutlookRegionalApiDto
- HouseholdSurveyListDTO
- HouseholdSurveyListDTOPagedResult
- HungerHotSpotDataDTO
- HungerHotSpotDataDTOPagedResult
- IpcHistoricalDatumDto
- IpcHistoricalDatumDtoPagedResult
- IpcchAndEquivalentPeaksDTO
- IpcchAndEquivalentPeaksDTOPagedResult
- IpcchBaseDto
- IpcchBaseDtoPagedResult
- IpcchPeaksDto
- IpcchPeaksDtoPagedResult
- KeyNameDto
- ListItemDto
- MFIProcessedDataDTO
- MarketDTO
- MarketGeoJsonRoot
- NearbyMarketsDTO
- PagedCommodityListDTO
- PagedCommodityPriceListDTO
- PagedCommodityWeeklyAggregatedPriceListDTO
- PagedCurrencyListDTO
- PagedEconomicDataDTO
- PagedMarketListDTO
- PagedProcessedDataDTO
- PagedSurveyListDTO
- PagedSurveyResponsesDTO
- PagedXlsFormListDTO
- ProblemDetails
- Properties
- RpmeAssessment
- RpmeAssessmentPagedResult
- RpmeOutputValues
- RpmeVariable
- RpmeVariablePagedResult
- SurveyListDTO
- UsdIndirectQuotation
- UsdIndirectQuotationPagedResult
- ViewExtendedMonthlyAggregatedPrice
- ViewExtendedMonthlyAggregatedPricePagedResult
- WeeklyAggregatedPrice
- XlsFormDTO
- XlsFormDefinitionNewSchemaDTO
- XlsFormFieldsDTO
- XlsFormListChoiceDTO
- XlsFormListChoicesDTO
Authentication schemes defined for the API:
- Type: OAuth
- Flow: implicit
- Authorization URL: https://api.wfp.org/authorize
- Scopes:
- vamdatabridges_rpme-fulldata_get: vamdatabridges_rpme-fulldata_get
- vamdatabridges_ipcch-ipcchandequivalent-latestpeaks_get: vamdatabridges_ipcch-ipcchandequivalent-latestpeaks_get
- vamdatabridges_ipcch-ipcchandequivalentpeakswfpdashboard_get: vamdatabridges_ipcch-ipcchandequivalentpeakswfpdashboard_get
- vamdatabridges_commodities-list_get: vamdatabridges_commodities-list_get
- vamdatabridges_commodityunits-list_get: vamdatabridges_commodityunits-list_get
- vamdatabridges_markets-nearbymarkets_get: vamdatabridges_markets-nearbymarkets_get
- vamdatabridges_globaloutlook-globallatest_get: vamdatabridges_globaloutlook-globallatest_get
- vamdatabridges_rpme-outputvalues_get: vamdatabridges_rpme-outputvalues_get
- vamdatabridges_marketprices-alps_get: vamdatabridges_marketprices-alps_get
- vamdatabridges_mfi-surveys_get: vamdatabridges_mfi-surveys_get
- vamdatabridges_commodities-categories-list_get: vamdatabridges_commodities-categories-list_get
- vamdatabridges_commodityunits-conversion-list_get: vamdatabridges_commodityunits-conversion-list_get
- vamdatabridges_economicdata_get: vamdatabridges_economicdata_get
- vamdatabridges_mfi-surveys-processeddata_get: vamdatabridges_mfi-surveys-processeddata_get
- vamdatabridges_marketprices-priceweekly_get: vamdatabridges_marketprices-priceweekly_get
- vamdatabridges_markets-marketsascsv_get: vamdatabridges_markets-marketsascsv_get
- vamdatabridges_cari-adm1values_get: vamdatabridges_cari-adm1values_get
- vamdatabridges_household-publicbasedata_get: vamdatabridges_household-publicbasedata_get
- vamdatabridges_mfi-xlsforms_get: vamdatabridges_mfi-xlsforms_get
- vamdatabridges_economicdata-indicatorlist_get: vamdatabridges_economicdata-indicatorlist_get
- vamdatabridges_markets-geojsonlist_get: vamdatabridges_markets-geojsonlist_get
- vamdatabridges_mfi-surveys-processeddatakeysetpagination_get: vamdatabridges_mfi-surveys-processeddatakeysetpagination_get
- vamdatabridges_rpme-surveys_get: vamdatabridges_rpme-surveys_get
- vamdatabridges_rpme-xlsforms_get: vamdatabridges_rpme-xlsforms_get
- vamdatabridges_mfi-surveys-basedata_get: vamdatabridges_mfi-surveys-basedata_get
- vamdatabridges_mfi-surveys-fulldata_get: vamdatabridges_mfi-surveys-fulldata_get
- vamdatabridges_globaloutlook-regionallatest_get: vamdatabridges_globaloutlook-regionallatest_get
- vamdatabridges_household-fulldata_get: vamdatabridges_household-fulldata_get
- vamdatabridges_hungerhotspot-categoriesandindicators_get: vamdatabridges_hungerhotspot-categoriesandindicators_get
- vamdatabridges_household-officialusebasedata_get: vamdatabridges_household-officialusebasedata_get
- vamdatabridges_globaloutlook-countrylatest_get: vamdatabridges_globaloutlook-countrylatest_get
- vamdatabridges_marketprices-pricemonthly_get: vamdatabridges_marketprices-pricemonthly_get
- vamdatabridges_ipcch-ipcch-historicaldata_get: vamdatabridges_ipcch-ipcch-historicaldata_get
- vamdatabridges_markets-list_get: vamdatabridges_markets-list_get
- vamdatabridges_currency-list_get: vamdatabridges_currency-list_get
- vamdatabridges_ipcch-ipcchandequivalent-historicalpeaks_get: vamdatabridges_ipcch-ipcchandequivalent-historicalpeaks_get
- vamdatabridges_ipcch-ipcchandequivalent-mostrecent_get: vamdatabridges_ipcch-ipcchandequivalent-mostrecent_get
- vamdatabridges_marketprices-priceraw_get: vamdatabridges_marketprices-priceraw_get
- vamdatabridges_rpme-variables_get: vamdatabridges_rpme-variables_get
- vamdatabridges_currency-usdindirectquotation_get: vamdatabridges_currency-usdindirectquotation_get
- vamdatabridges_hungerhotspot-data_get: vamdatabridges_hungerhotspot-data_get
- vamdatabridges_xlsforms-definition_get: vamdatabridges_xlsforms-definition_get
- vamdatabridges_household-draftinternalbasedata_get: vamdatabridges_household-draftinternalbasedata_get
- vamdatabridges_household-surveys_get: vamdatabridges_household-surveys_get
- vamdatabridges_marketprices-pricedaily_get: vamdatabridges_marketprices-pricedaily_get
- vamdatabridges_cari-adm0values_get: vamdatabridges_cari-adm0values_get
- vamdatabridges_rpme-basedata_get: vamdatabridges_rpme-basedata_get