Package: ChinAPIs 0.1.1

ChinAPIs: Access Chinese Data via Public APIs and Curated Datasets

Provides functions to access data from public RESTful APIs including 'Nager.Date', 'World Bank API', and 'REST Countries API', retrieving real-time or historical data related to China, such as holidays, economic indicators, and international demographic and geopolitical indicators. Additionally, the package includes one of the largest curated collections of open datasets focused on China and Hong Kong, covering topics such as air quality, demographics, input-output tables, epidemiology, political structure, names, and social indicators. The package supports reproducible research and teaching by integrating reliable international APIs and structured datasets from public, academic, and government sources. For more information on the APIs, see: 'Nager.Date' <https://date.nager.at/Api>, 'World Bank API' <https://datahelpdesk.worldbank.org/knowledgebase/articles/889392>, and 'REST Countries API' <https://restcountries.com/>.

Authors:Renzo Caceres Rossi [aut, cre]

ChinAPIs_0.1.1.tar.gz
ChinAPIs_0.1.1.zip(r-4.7)ChinAPIs_0.1.1.zip(r-4.6)ChinAPIs_0.1.1.zip(r-4.5)
ChinAPIs_0.1.1.tgz(r-4.6-any)ChinAPIs_0.1.1.tgz(r-4.5-any)
ChinAPIs_0.1.1.tar.gz(r-4.7-any)ChinAPIs_0.1.1.tar.gz(r-4.6-any)
ChinAPIs_0.1.1.tgz(r-4.6-emscripten)
manual.pdf |manual.html
card.svg |card.png
ChinAPIs/json (API)
NEWS

# Install 'ChinAPIs' in R:
install.packages('ChinAPIs', repos = c('https://lightbluetitan.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/lightbluetitan/chinapis/issues

Pkgdown/docs site:https://lightbluetitan.github.io

Datasets:

On CRAN:

Conda:

4.18 score 6 scripts 205 downloads 47 exports 27 dependencies

Last updated from:43c998fe9f. Checks:9 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-devel-x86_64OK145
source / vignettesOK231
linux-release-x86_64OK144
macos-release-arm64OK106
macos-oldrel-arm64OK111
windows-develOK131
windows-releaseOK101
windows-oldrelOK101
wasm-releaseOK114

Exports:bj_air_quality_tbl_dfchina_admin_divisions_dfchina_cars_tbl_dfchina_corruption_tbl_dfchina_io_2002_122_dfchina_io_2005_42_dfchina_io_2007_135_dfchina_io_2010_41_dfchina_io_2012_139_dfchina_io_2015_42_dfchina_io_2017_149_dfchina_io_2017_42_dfchina_io_2018_153_dfchina_io_2018_42_dfchina_io_2020_153_dfchina_io_2020_42_dfchinese_cities_tbl_dfchinese_dams_tbl_dfCOVID19_HongKong_dffamily_name_dfget_china_child_mortalityget_china_cpiget_china_energy_useget_china_gdpget_china_holidaysget_china_hospital_bedsget_china_life_expectancyget_china_literacy_rateget_china_populationget_china_unemploymentget_country_info_cngiven_name_dfhealth_family_life_dfhk_councillors_tbl_dfhk_districts_tbl_dfhk_population_tbl_dfhk_street_names_tbl_dfpanda_locations_dfpopulation_dfsars_hong_kong_listshanghai_factories_dfshanghai_pm25_dftop1000name_prov_dftop100name_year_dftop50char_year_dfview_datasets_ChinAPIswenchuan_ptsd_matrix

Dependencies:askpassclicurldplyrfarvergenericsgluehttrjsonlitelabelinglifecyclemagrittrmimeopensslpillarpkgconfigR6RColorBrewerrlangscalessystibbletidyselectutf8vctrsviridisLitewithr

ChinAPIs: Access Chinese Data via Public APIs and Curated Datasets

Rendered fromChinAPIs_vignette.Rmdusingknitr::rmarkdownon May 13 2026.

Last update: 2025-08-21
Started: 2025-08-01

Readme and manuals

Help Manual

Help pageTopics
Beijing Air Quality Dataset (2015)bj_air_quality_tbl_df
Administrative Divisions of Chinachina_admin_divisions_df
Stated Car Choice Data from Chinese Buyerschina_cars_tbl_df
China's Corruption Investigationschina_corruption_tbl_df
Input-output Table for China, 2002 (122 Sectors)china_io_2002_122_df
Input-output Table for China, 2005 (42 Sectors)china_io_2005_42_df
Input-output Table for China, 2007 (135 Sectors)china_io_2007_135_df
Input-output Table for China, 2010 (41 Sectors)china_io_2010_41_df
Input-output Table for China, 2012 (139 Sectors)china_io_2012_139_df
Input-output Table for China, 2015 (42 Sectors)china_io_2015_42_df
Input-output Table for China, 2017 (149 Sectors)china_io_2017_149_df
China Input-Output Table (2017, 42 Sectors)china_io_2017_42_df
China Input-Output Table (2018, 153 Sectors)china_io_2018_153_df
China Input-Output Table (2018, 42 Sectors)china_io_2018_42_df
Input-output Table for China, 2020 (153 Sectors)china_io_2020_153_df
China Input-Output Table (2020, 42 Sectors)china_io_2020_42_df
ChinAPIs: Access Chinese Data via APIs and Curated DatasetsChinAPIs-package ChinAPIs
List of Prominent Chinese Citieschinese_cities_tbl_df
Chinese Dams Datasetchinese_dams_tbl_df
COVID-19 Offspring Cases in Hong Kong (Jan–Apr 2020)COVID19_HongKong_df
Chinese Surnames and National Frequency (1930–2008)family_name_df
Get Under-5 Mortality Rate in China from World Bankget_china_child_mortality
Get China's Consumer Price Index from World Bankget_china_cpi
Get China's Energy Use (kg of oil equivalent per capita) from World Bankget_china_energy_use
Get China's GDP (Current US$) from World Bankget_china_gdp
Get Official Public Holidays in China for a Given Yearget_china_holidays
Get Hospital Beds per 1,000 People in China from World Bankget_china_hospital_beds
Get China's Life Expectancy at Birth from World Bankget_china_life_expectancy
Get China's Literacy Rate (Age 15+) from World Bankget_china_literacy_rate
Get China's Total Population from World Bankget_china_population
Get China's Unemployment Rate from World Bankget_china_unemployment
Get Key Country Information About China from the REST Countries APIget_country_info_cn
Chinese Given Name Characters and Frequency (1930–2008)given_name_df
Chinese Health and Family Life Surveyhealth_family_life_df
Hong Kong District Councillors Elected in 2019hk_councillors_tbl_df
Hong Kong District Labels and Regional Classificationhk_districts_tbl_df
Hong Kong Population by District and Age Grouphk_population_tbl_df
Hong Kong Street Names as of 2020hk_street_names_tbl_df
Giant Panda Location Datapanda_locations_df
Population Statistics from the Chinese Name Databasepopulation_df
Daily Incidence of the 2003 SARS Epidemic in Hong Kongsars_hong_kong_list
Per Capita Output of Workers in Shanghai Factoriesshanghai_factories_df
PM2.5 Pollution and Weather Data in Shanghaishanghai_pm25_df
Top 1,000 Given Names by Province in Mainland Chinatop1000name_prov_df
Top 100 Given Names in 6 Birth Cohortstop100name_year_df
Top 50 Given-Name Characters in 6 Birth Cohortstop50char_year_df
View Available Datasets in ChinAPIsview_datasets_ChinAPIs
PTSD Symptoms of Wenchuan Earthquake Survivorswenchuan_ptsd_matrix