Apify icon

Apify

Apify API

Overview

This node interacts with the Apify API to retrieve dataset information. Specifically, the 'Get dataset' operation under the 'Datasets' resource allows users to fetch a dataset by its ID or by a combination of username and dataset name. This is useful for workflows that need to process or analyze data stored in Apify datasets, such as extracting web scraping results or automation outputs.

Use Case Examples

  1. Fetch a dataset using its unique dataset ID to process the data in subsequent workflow steps.
  2. Retrieve a dataset by specifying 'username~dataset-name' along with an API token for authentication, enabling access to datasets owned by different users or shared datasets.

Properties

Name Meaning
Dataset Id The unique identifier of the dataset to retrieve, or a string in the format 'username~dataset-name' to specify the dataset by user and name. This is a required input.
Token An API authentication token required only when using the 'username~dataset-name' format for the Dataset Id. It is used to authenticate the request via query string parameter.
Use Custom Body A boolean flag indicating whether to use a custom request body for the API call. Defaults to false.

Output

JSON

  • dataset - The retrieved dataset object containing the dataset's data and metadata.

Dependencies

  • Requires an Apify API key credential for authentication to access the Apify API.

Troubleshooting

  • If the 'datasetId' is invalid or not found, the node will likely return an error indicating the dataset could not be retrieved. Verify the dataset ID or the 'username~dataset-name' format is correct.
  • When using the 'username~dataset-name' format, ensure the 'Token' is provided and valid; otherwise, authentication errors will occur.
  • If 'Use Custom Body' is enabled but the custom body is malformed or incomplete, the API request may fail. Ensure the custom body is correctly formatted JSON.

Links

Discussion