responseMode: stream for any file an action returns: REST pipes the bytes to the caller, and an MCP tool call returns a single-use download link with the file’s name, type and size. A streaming step must be the last step of its action. The default, buffer, returns the content in data, which only suits content a later step in the same action needs to read. Use fileName when the provider’s response carries no file name.
Input
- v1
| Field | Description | Type | Required |
|---|---|---|---|
args | Additional request parameters sent as query params, headers, or the request body, per each entry’s in. | object[] | No |
authorization | Overrides the connector’s default authentication for this request. | union | No |
baseUrl | Overrides the connector’s base URL for the download. | string | No |
customErrors | Remaps matching provider error responses to different statuses or messages. | object[] | No |
encoding | Encoding applied to data when responseMode is buffer. Ignored when streaming. Use none to return a raw Buffer.Allowed: base64, utf8, binary, raw, noneDefault: base64 | enum | Yes |
fileName | Name to give the downloaded file, overriding any name from the provider’s Content-Disposition header or response.fileNameKey. Supports expressions, so it can come from an earlier step such as a metadata lookup. Falls back to the provider’s name when it resolves to nothing. A name with no extension gets one from the download’s content type, so an exported document named Q3 plan saves as Q3 plan.pdf. | string | No |
followRedirects | Whether to follow HTTP redirects. Default: true | boolean | Yes |
maxRedirects | Maximum number of redirects to follow. Default: 5 | number | Yes |
method | HTTP method to use for the download. Allowed: get, post, put, delete, patchDefault: get | enum | Yes |
response | Options for extracting file content from a JSON-wrapped response. | object | No |
responseMode | How the file is returned. buffer (the default) holds the whole file in memory and returns it in data, encoded per encoding, so an MCP tool call carries the entire file inline. stream returns a readable stream instead: REST pipes the bytes to the caller and an MCP tool call returns a single-use download link. Use stream for files. A streaming step must be the last step of its action.Allowed: buffer, streamDefault: buffer | enum | Yes |
responseType | Underlying HTTP response type requested. Used only when responseMode is buffer. Allowed: arraybuffer, blob, text, jsonDefault: arraybuffer | enum | Yes |
url | Download endpoint path appended to the base URL. | string | Yes |
args
args
Additional request parameters sent as query params, headers, or the request body, per each entry’s
in.| Field | Description | Type | Required |
|---|---|---|---|
arrayFormat | How array values are serialized in the query string: repeat, brackets, comma, or stringify. Allowed: repeat, brackets, comma, stringify | enum | No |
condition | A JEXL expression that includes the parameter only when it evaluates true. | string | No |
in | Where to send the parameter: query, body, or headers. Allowed: query, body, headers | enum | Yes |
name | Name of the request parameter. | string | Yes |
spread | Merges the value’s object entries into the target location instead of setting a single named field. | boolean | No |
value | Value of the parameter. Supports expressions. | any | Yes |
customErrors
customErrors
Remaps provider error responses to different statuses or messages. Useful for GraphQL APIs that return errors with a 200 status, normalizing provider-specific error formats, and giving AI agents clearer error messages.
| Field | Description | Type | Required |
|---|---|---|---|
condition | A JEXL expression that applies the remap only when it evaluates true. | string | No |
message | Error message to return in place of the provider’s. | string | No |
receivedStatus | Provider HTTP status code to match. | number | Yes |
targetStatus | HTTP status code to return in place of the matched one. | number | Yes |
response
response
Options for extracting file content from a JSON-wrapped response.
| Field | Description | Type | Required |
|---|---|---|---|
contentIsBase64 | Whether the content in the JSON response is already base64 encoded. Default: false | boolean | Yes |
contentType | Fallback content type used when the JSON response exposes none to extract. contentTypeKey wins if it resolves. | string | No |
contentTypeKey | JSONPath to the content type within a JSON-wrapped response. | string | No |
dataKey | JSONPath to the file content within a JSON-wrapped response. | string | No |
fileNameKey | JSONPath to the filename within a JSON-wrapped response. | string | No |
forwardAuth | Whether to forward authentication headers to the secondary download request when following urlKey. Default: false | boolean | Yes |
urlKey | JSONPath to a download URL in the response to follow for the file. | string | No |
Output
- v1
| Field | Description | Type | Required |
|---|---|---|---|
contentDisposition | Content-Disposition header value for the client to use. | string | No |
data | Downloaded file content. A string in the format set by the encoding input (base64 by default), or a raw binary Buffer when encoding: "none". Absent when responseMode: "stream" (content is piped via the stream output instead). | union | No |
fileMetadata | File metadata extracted from response headers or a JSON-wrapped response. | object | No |
finalUrl | Final URL the file was downloaded from after redirects or a followed link. | string | No |
headers | All response headers returned with the download. | object | No |
message | Status or error message from the response. | string | No |
raw | The raw provider response before parsing. | any | No |
statusCode | HTTP status code of the provider response. | number | Yes |
fileMetadata
fileMetadata
File metadata extracted from response headers or a JSON-wrapped response.
| Field | Description | Type | Required |
|---|---|---|---|
contentLength | Size of the file in bytes. | number | No |
contentType | MIME type of the downloaded file. | string | No |
etag | Entity tag identifying the file version. | string | No |
fileName | Name of the downloaded file. | string | No |
lastModified | Last-modified timestamp reported for the file. | string | No |