Skip to main content
Glama

Get dataset items

get-dataset-items
Read-onlyIdempotent

Get items (rows) from a dataset — the output/results produced by an Actor run. Returns the rows themselves, not dataset metadata, counts, or a schema. When the user provides a datasetId and asks to retrieve results, output, data, or rows, call this tool directly. Default limit is 20. Use clean=true to skip empty items and hidden fields. A page over 262144 bytes is returned as an error with a link to download it, not as its items.

USAGE:

  • Use when you need to read data from a dataset (all items or only selected fields).

USAGE EXAMPLES:

  • user_input: Retrieve results from dataset abc123

  • user_input: Get only metadata.url and title from dataset username~my-dataset

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "datasetId": "<datasetId>"
    },
    "name": "get-dataset-items"
  }
}

Input Schema

NameRequiredDescriptionDefault
descNoIf true, results are returned in reverse order (newest to oldest).
omitNoComma-separated list of fields to exclude from results.
cleanNoIf true, returns only non-empty items and skips hidden fields (starting with #). Shortcut for skipHidden=true and skipEmpty=true.
limitNoMaximum number of items to return. Default is 20.
fieldsNoComma-separated list of fields to include in results. Fields in output are sorted as specified. Use dot notation for nested objects (e.g. "metadata.url"); the server auto-flattens parent prefixes and returns flat keys, unless the parent itself is listed (e.g. "metadata,metadata.url" returns metadata whole). A dotted path to or through an array (e.g. "results.url") returns nothing: select its top-level field (e.g. "results") for every element. Items that have none of the requested fields come back as {}, or are dropped when clean=true.
offsetNoNumber of items to skip at the start. Default is 0.
flattenNoComma-separated list of fields to flatten (e.g. flatten="metadata" turns {"metadata":{"url":"x"}} into {"metadata.url":"x"}). Normally derived automatically from dot-notation in `fields`; specify only as a diagnostic override.
datasetIdYesDataset ID, name (resolved against your own datasets), or full name as username~name.

Output Schema

NameRequiredDescriptionDefault
itemsYesDataset items
limitYesLimit used for pagination
offsetYesOffset used for pagination
summaryYesSummary of the result
nextStepYesOne follow-up action with tool name
datasetIdYesDataset ID
itemCountYesNumber of items returned
totalItemCountYesTotal items in dataset
apifyConsoleUrlNoPersonalized Apify Console link to the dataset; present only for Console sessions

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / offset / minimum
      Added value: +0
  2. Changed1 schema field changed
    • addedInput schema / properties / datasetId / maxLength
      Added value: +256
  3. Changed2 schema fields changed
    • changedInput schema / properties / fields / description
      Previous value: -"Comma-separated list of fields to include in results. Fields in output are sorted as specified. Use dot notation for nested objects (e.g. \"metadata.url\"); the server auto-flattens parent prefixes."New value: +"Comma-separated list of fields to include in results.\nFields in output are sorted as specified.\nUse dot notation for nested objects (e.g. \"metadata.url\"); the server auto-flattens parent prefixes and returns flat keys, unless the parent itself is listed (e.g. \"metadata,metadata.url\" returns metadata whole).\nA dotted path to or through an array (e.g. \"results.url\") returns nothing: select its top-level field (e.g. \"results\") for every element.\nItems that have none of the requested fields come back as {}, or are dropped when clean=true."
    • changedInput schema / properties / flatten / description
      Previous value: -"Comma-separated list of fields to flatten (e.g. flatten=\"metadata\" turns {\"metadata\":{\"url\":\"x\"}} into {\"metadata.url\":\"x\"}). Normally derived automatically from dot-notation in `fields`; specify only as a diagnostic override."New value: +"Comma-separated list of fields to flatten (e.g. flatten=\"metadata\" turns {\"metadata\":{\"url\":\"x\"}} into {\"metadata.url\":\"x\"}).\nNormally derived automatically from dot-notation in `fields`; specify only as a diagnostic override."
  4. Changed1 schema field changed
    • changedInput schema / properties / datasetId / description
      Previous value: -"Dataset ID or username~dataset-name."New value: +"Dataset ID, name (resolved against your own datasets), or full name as username~name."
  5. First observed

TDQS

A4.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare read-only, idempotent, non-destructive behavior, so the bar is lower. The description still adds real context beyond them: default limit of 20, clean=true semantics for skipping empty items and hidden fields, and the notable 262144-byte page error with a download link instead of items.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the resource definition and the key not-this disambiguation, then compact constraint sentences. Every line carries information; no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers purpose, trigger condition, default paging, empty-field filtering, and the large-page failure mode. With a full output schema and rich annotations already present, nothing an agent needs to call it correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is already 100%, so baseline would be 3; the description earns a step up by highlighting the default limit, clean=true behavior, and framing fields selection in the usage example. It does not cover desc, omit, offset, or flatten, which is acceptable given the schema documents them.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ("Get items (rows) from a dataset — the output/results produced by an Actor run") and explicitly contrasts with what it is not: metadata, counts, or schema. That disambiguates it from siblings like get-actor-run without needing their schemas.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives a clear trigger: when the user supplies a datasetId and asks for results, output, data, or rows, call this directly. Two usage examples reinforce the selection, though it gives no explicit when-not conditions or named alternatives.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.