Put Object
gcs.put_object
ActionGoogle Cloudconnection required
Calls the GCS upload API POST /b/{bucket}/o — uploadType=media, or uploadType=multipart once any metadata field is set.
Upload a text or binary object to a Google Cloud Storage bucket.
Connection
- Required
- Yes — the node will not save without one
- Auth type
- OAuth 2.0
- Providers
- Google Cloud Storage
- Secret shape
- {"client_id", "client_secret", "refresh_token"}
- Config it needs
- bucket
- Resolved by
- config.connection_id, else node.connection_id
Configuration
10 fields, 1 required. A dotted path is a nested object and name[] an array of objects — the editor renders the same tree.
| Field | Type | Required | Default | Constraints | Example |
|---|---|---|---|---|---|
bucket Bucket name (overrides connection). | string | No | — | — | — |
object Object name/key. | string | Yes | — | — | — |
body Object contents: text, or a base64 blob when content_encoding='base64'. Leave empty to upload the upstream file (e.g. from GitHub/GitLab Download Archive). | string | No | — | — | — |
content_encoding Set to 'base64' when body is a base64 blob (e.g. from a download_archive node). Defaults to the upstream file's encoding, else text. | string | No | — | one of "text", "base64" | — |
content_type MIME type (defaults to the upstream file's). | string | No | — | — | — |
cache_control Cache-Control stored on the object, e.g. 'public, max-age=3600'. A CDN in front of the bucket obeys this. | string | No | — | — | — |
content_disposition Content-Disposition, e.g. attachment; filename="report.pdf" — what makes a browser download the file under a readable name. | string | No | — | — | — |
http_content_encoding Content-Encoding stored on the object, e.g. gzip when the body is already gzipped. Separate from content_encoding above, which only says how Mantle should read the body. | string | No | — | — | — |
custom_time RFC 3339 timestamp lifecycle rules can match on. | string | No | — | — | — |
metadata Custom key/value stamp to store on the object (JSON), e.g. {"stage": "raw"}. Readable later via Get Object Metadata. | object | No | — | — | {"stage":"raw"} |
Example configuration
Every value below is the contract’s own example or default — nothing invented.
{
"metadata": {
"stage": "raw"
}
}Input
| Field | Type | Example |
|---|---|---|
file_content The file, base64-encoded. | string | — |
content_encoding | string | base64 |
filename | string | app-main.zip |
content_type | string | application/zip |
size Raw size in bytes (before base64). | number | — |
Output
One shape.
result
| Field | Type | Example |
|---|---|---|
ok | boolean | — |
object | string | — |
size Bytes uploaded. | number | — |
generation Object version; pin it to fetch exactly what was listed. | string | — |
md5 Base64 MD5 of the content (absent for composite objects). | string | — |
crc32c Base64 CRC32C of the content; always present. | string | — |
storage_class STANDARD / NEARLINE / COLDLINE / ARCHIVE. | string | — |
media_link Authenticated download URL. | string | — |
content_disposition Stored Content-Disposition. | string | — |
cache_control Stored Cache-Control. | string | — |
custom_time User-set timestamp used by lifecycle rules. | string | — |
metadata The user-defined key/value map stamped on the object. | object | — |
{
"cache_control": "",
"content_disposition": "",
"crc32c": "",
"custom_time": "",
"generation": "",
"md5": "",
"media_link": "",
"metadata": {},
"object": "",
"ok": false,
"size": 0,
"storage_class": ""
}Related Google Cloud Storage nodes
See Put Object run in a workflow.
In a technical demo we add the Google Cloud Storage connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.