Skip to main content

Loading a Dataset Card

We assume that you have already obtained your Dateno API key. Let’s now load a dataset card using the Dateno REST API. Before writing any code, we will use a popular API testing tool.

Exercise Plan

Follow these steps to complete the process:

  1. Choosing a dataset for this exercise
  2. Retrieving the dataset identifier
  3. Configuring a request in the API testing tool
  4. Sending the request and reviewing the response

Choosing a Dataset for This Exercise

Any dataset will work for this simple exercise. However, it’s best to choose one that contains at least one data file to make the response more informative.

TIP
Use the Format facet to exclude datasets without data files. Select the CSV format to choose datasets that provide tabular data.

Retrieving the Dataset Identifier

To load a dataset card, you need its unique identifier. Follow these steps to find it:

  1. Open the dataset card for the dataset you want to use.
  2. Locate the ID field in the dataset card.
    Copying the dataset identifier
  3. Copy the unique dataset identifier.

Configuring a Request in a Testing Tool

Now, set up a GET HTTP request in your API testing tool. The request must include:

  • The endpoint URL
  • The dataset ID (as part of the path)
  • Your API key (as a query parameter named apikey)

Here’s a sample request:

https://api.dateno.io/search/0.1/entry/92ecad2c7fe1931cc13c29f28840f92269ae6d435e154a45a4e14734bef14d14?apikey=AbCdEfGhIjKlMnOpQrStUvWxYz123456

ATTENTION
Make sure you are using your valid Dateno API key.

Sending the Request and Reviewing the Response

Send the configured request and wait for the Dateno server to respond.

A successful response returns a JSON object that represents a dataset card. It contains top-level fields such as id, int_id, source, dataset and resources. You can download data files associated with the dataset using the resource descriptors from the resources array.

Below is an example of a successful JSON response:

{
"id": "8c173a36a51315afe02eb5f797d52ebc70ab370f6a67a86b76c13430a387ac2b",
"int_id": "2276763",
"source": {
"uid": "cdi00001986",
"name": "Kaggle",
"url": "https://kaggle.com/datasets",
"catalog_type": "Machine learning catalog",
"langs": [
{
"id": "EN",
"name": "English"
}
],
"owner_name": "Kaggle Inc.",
"owner_type": "Business",
"software": {
"id": "custom",
"name": "Custom software"
},
"countries": [
{
"id": "World",
"name": "World"
}
],
"macroregions": [
{
"id": "World",
"name": "World"
}
],
"subregions": [
{
"id": null,
"name": null
}
]
},
"dataset": {
"id": "8c173a36a51315afe02eb5f797d52ebc70ab370f6a67a86b76c13430a387ac2b",
"title": "Rabbit",
"num_resources": 1,
"url": "https://www.kaggle.com/datasets/rabbitdataset/rabbit",
"short_text": "",
"description": "",
"has_archive": null,
"tags": null,
"formats": [
".zip"
],
"datatypes": null,
"topics_original": null,
"responsible": [
{
"id": null,
"title": "RabbitDataset",
"role": "Author"
}
],
"license_id": null,
"license_name": null,
"license_url": null
},
"resources": [
{
"id": null,
"name": "rabbitdataset/rabbit",
"datasize": null,
"format": ".zip",
"mimetype": "application/zip",
"url": "https://www.kaggle.com/api/v1/datasets/download/rabbitdataset/rabbit"
}
]
}

For a detailed description of the fields in a dataset card, see Dataset Card.