package_list应用程序介面

开发者可以透过package_list应用程式介面取得完整的数据集目录: https://data.gov.hk/sc-data/api/3/action/package_list

package_list应用程序介面支持两个可选的参数:limitoffsetlimit(int):指定最多可回传的数据集数量。 offset(int):指定第一个数据集的位置,须与限制一致使用。

例如,当我们想取得英文网站中的第5个至第14个资料集(索引头为0),可作以下请求: https://data.gov.hk/en-data/api/3/action/package_list?limit=10&offset=5

以下是应用程式介面所回传的例子:

{
    "help": "Return a list of the names of the site’s datasets (packages).\n\n …",
    "result": [
        "centaline-centanetod-ccipropertyinfo",
        "clp-team1-electric-vehicle-charging-location",
        "hk-afcd-afcdlist-pesticides-licensee-1",
        "hk-afcd-afcdlist-pesticides-licensee-2",
        …
    ],
    "success": true
}

小提示:回传的资料集ID可用于请求其它应用程序介面,以作进一步的处理.

results matching ""

    No results matching ""