Actions15
Overview
This node interacts with the DatoCMS API to retrieve multiple upload assets ("uploads") from a DatoCMS project. Specifically, the "Get Many" operation under the "Upload" resource fetches a list of uploads, optionally filtered by an upload collection. It supports returning all uploads or limiting the number of results.
Typical use cases include:
- Retrieving a batch of media files (images, videos, documents) stored in DatoCMS for further processing or integration.
- Filtering uploads by collections to organize and manage assets more effectively.
- Using the retrieved upload metadata in workflows that automate content publishing, asset management, or synchronization with other systems.
Example: A user wants to get all images uploaded to a specific collection in DatoCMS to generate a gallery on their website or to back up those assets elsewhere.
Properties
| Name | Meaning |
|---|---|
| Filter by Collection | Optional client-side filter to restrict uploads to a specific upload collection. Options: select from list or specify ID. |
| Return All | Boolean flag indicating whether to return all uploads or limit the number of results. |
| Limit | Maximum number of uploads to return if "Return All" is false. Minimum value is 1. Default is 50. |
Output
The output JSON contains an object with these fields:
results: An array of upload objects representing the fetched uploads. Each upload object includes metadata such as ID, filename, URL, size, and associated collection info.count: The total number of uploads returned.query: An object summarizing the query parameters used, including:filterByCollection: The ID of the collection used for filtering, or null if none.returnAll: Boolean indicating if all uploads were returned.limit: The maximum number of uploads requested (undefined if returning all).
No binary data is output by this operation; it only returns metadata about uploads.
Dependencies
- Requires an API authentication token credential for DatoCMS.
- Uses the official DatoCMS Node.js client library to communicate with the API.
- No additional environment variables are needed beyond the API token and optional environment name.
Troubleshooting
Empty results when filtering by collection:
The DatoCMS API does not support server-side filtering by upload collection, so filtering is done client-side. If no uploads appear after filtering, verify the collection ID is correct and that uploads exist in that collection.Permission errors when listing collections:
If the node cannot access upload collections due to insufficient permissions, it will show a placeholder "(None - Upload Collections Not Accessible)". Ensure the API token has appropriate scopes to read upload collections.Limit vs Return All behavior:
When "Return All" is false and the limit is set too high, the node caps the page size at 50 per API constraints. To get more than 50 uploads, enable "Return All".API rate limits or network issues:
Errors from the DatoCMS API may occur due to rate limits or connectivity problems. Retrying or checking API usage quotas can help.