Upload Release Asset
github.upload_release_asset
ActionBusiness appsconnection required
Calls POST uploads.github.com/repos/{owner}/{repo}/releases/{id}/assets.
Attach a file to an existing GitHub release.
Connection
- Required
- Yes — the node will not save without one
- Auth type
- Bearer token
- Providers
- GitHub
- Secret shape
- the GitHub personal access token
- Resolved by
- config.connection_id, else node.connection_id, else the tenant's sole GitHub connection
Configuration
8 fields, 3 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 |
|---|---|---|---|---|---|
owner Repository owner — the user or organisation login. | string | Yes | — | — | octocat |
repo Repository name, without the owner prefix. | string | Yes | — | — | hello-world |
release_id Numeric release id, as returned by github.create_release. | string | Yes | — | — | 1 |
name File name for the asset. Defaults to the upstream file's name. | string | No | — | — | — |
label Display label shown instead of the file name. | string | No | — | — | — |
body File contents. Leave empty to upload the upstream file blob instead. | 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 Media type to upload with, e.g. application/zip. Defaults to the upstream file's type. | string | No | — | — | — |
Example configuration
Every value below is the contract’s own example or default — nothing invented.
{
"owner": "octocat",
"release_id": "1",
"repo": "hello-world"
}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.
asset
| Field | Type | Example |
|---|---|---|
ok | boolean | true |
asset_id Id of the uploaded asset. | string | — |
name File name the asset was stored under. | string | — |
label Display label, when one was set. | string | — |
size Asset size in bytes. | number | — |
content_type Media type it was uploaded with. | string | — |
browser_download_url Public download URL. | string | — |
{
"asset_id": "",
"browser_download_url": "",
"content_type": "",
"label": "",
"name": "",
"ok": true,
"size": 0
}Notes
- The release must already exist — create it with github.create_release first.
- GitHub answers 422 when an asset with the same name is already on the release.
Solutions with GitHub
See Upload Release Asset run in a workflow.
In a technical demo we add the GitHub connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.