#  CBDB API 

 



 ##  

  expand\_more  

 
  

 

### Introduction to CBDB API

API (application programming interfaces) is an application which allows system interoperability. Through API, each database can retrieve data from another database to supplement its own without actually storing them.

CBDB API now allows other databases to retrieve and present CBDB data on the fly. We accept two types of queries:

1\. Query by person ID (CBDB ID)

2\. Query by name (Chinese and Pinyin)

**How to Call CBDB API:**

Example: creating an API call to CBDB for 王安石 (Wang Anshi)

Send out http request using the following link:

1\. Query by person ID:

<https://cbdb.fas.harvard.edu/cbdbapi/person.php?id=1762> (Wang Anshi's CBDB ID)

2\. Query by name:

[https://cbdb.fas.harvard.edu/cbdbapi/person.php?name=王安石](https://cbdb.fas.harvard.edu/cbdbapi/person.php?name=%E7%8E%8B%E5%AE%89%E7%9F%B3)  
<https://cbdb.fas.harvard.edu/cbdbapi/person.php?name=Wang%20Anshi>

3\. Output to json:

[https://cbdb.fas.harvard.edu/cbdbapi/person.php?name=王安石&amp;o=json](https://cbdb.fas.harvard.edu/cbdbapi/person.php?name=王安石&o=json)

**Output Format:**

After calling the API, it will return the complete data of the person in CBDB.

HTML output:

 ![picture1.png](/sites/g/files/omnuum3101/files/cbdb/files/picture1.png)

 

 ![picture2.png](/sites/g/files/omnuum3101/files/cbdb/files/picture2.png)

 

CBDB API also supports JSON output formats:

 ![CBDB-JSON-OUTPUT](/sites/g/files/omnuum3101/files/2025-10/cbdb-api-json.png)

 

**Current Users of CBDB API:**

[**Ming Qing Women's Writings**](https://digital.library.mcgill.ca/mingqing/english/index.php) **by McGill University**

[**人名權威人物傳記資料**](http://archive.ihp.sinica.edu.tw/ttsweb/html_name/index.php) **by Academia Sinica**

[**Communication and Empire: Chinese Empires in Comparative Perspective**](https://chinese-empires.eu/) **by Hilde De Weerdt**

[**Digging into Data: Automating Chinese Text Extraction**](https://did-acte.org/) **by Peter K. Bol, Naomi Standen, Hilde De Weerdt**