Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/hugoalh/send-guilded-webhook-ghaction
A GitHub Action to send Guilded webhook.
https://github.com/hugoalh/send-guilded-webhook-ghaction
gh-action ghaction github-action guilded webhook
Last synced: 23 days ago
JSON representation
A GitHub Action to send Guilded webhook.
- Host: GitHub
- URL: https://github.com/hugoalh/send-guilded-webhook-ghaction
- Owner: hugoalh
- License: other
- Created: 2024-11-20T04:26:21.000Z (about 1 month ago)
- Default Branch: main
- Last Pushed: 2024-11-29T04:51:13.000Z (30 days ago)
- Last Synced: 2024-11-29T05:27:41.647Z (30 days ago)
- Topics: gh-action, ghaction, github-action, guilded, webhook
- Language: TypeScript
- Homepage: https://github.com/marketplace/actions/send-guilded-webhook
- Size: 51.8 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE.md
- Code of conduct: CODE_OF_CONDUCT.md
- Citation: CITATION.cff
- Codeowners: .github/CODEOWNERS
- Security: SECURITY.md
Awesome Lists containing this project
README
# Send Guilded Webhook (GitHub Action)
[**⚖️** MIT](./LICENSE.md)
[![GitHub: hugoalh/send-guilded-webhook-ghaction](https://img.shields.io/github/v/release/hugoalh/send-guilded-webhook-ghaction?label=hugoalh/send-guilded-webhook-ghaction&labelColor=181717&logo=github&logoColor=ffffff&sort=semver&style=flat "GitHub: hugoalh/send-guilded-webhook-ghaction")](https://github.com/hugoalh/send-guilded-webhook-ghaction)
A GitHub Action to send Guilded webhook.
> [!IMPORTANT]
> - This documentation is v0.1.0 based; To view other version's documentation, please visit the [versions list](https://github.com/hugoalh/send-guilded-webhook-ghaction/tags) and select the correct version.## 🌟 Features
- Support attachments/files.
## 🔰 Begin
### 🎯 Targets
| | **GitHub** |
|:--|:--|
| **[GitHub Actions Runner](https://github.com/actions/runner)** | [✔️ Docker](https://docs.github.com/en/actions) |> [!NOTE]
> - It is possible to use this action in other methods/ways which not listed in here, however those methods/ways are not officially supported, and should beware maybe cause security issues.### #️⃣ Resources Identifier
- **GitHub:**
```
hugoalh/send-guilded-webhook-ghaction[@{Tag}]
```> [!NOTE]
> - It is recommended to use this action with tag for immutability.### 🛡️ GitHub Token Permissions
*This action does not request any GitHub token permission.*
## 🧩 Inputs
Almost all of the inputs are optional, but these groups of inputs must be defined:
- [`key`](#key)
- [`content`](#content), [`embeds`](#embeds), and/or [`files`](#files)> | **Legend** | **Description** |
> |:-:|:--|
> | 🔐 | Should be an encrypted secret. |### `key`
**🔐** `` Guilded webhook key; These syntaxes are acceptable:
- **Webhook ID & Token:** `{webhook.id}/{webhook.token}`
- **URL:** `https://media.guilded.gg/webhooks/{webhook.id}/{webhook.token}`### `username`
`` Override the default webhook username, maximum 80 characters.
### `avatar_url`
`` Override the default webhook avatar, only support URL of HTTP and HTTPS.
### `content`
`` Message content, maximum 2000 characters; Support Guilded Markdown.
### `content_links_no_embed`
`` Links' regular expressions to prevent Guilded resolve and display matches links in the [`content`](#content) as embed under the message, only support URL of HTTP and HTTPS, separate each value per line.
Examples:
- **All:** `.+`
- **`.png` Image:** `\.png(?:\?|#|$)`
- **`.webp` Image:** `\.webp(?:\?|#|$)`
- **Twitch:** `twitch\.tv`### `embeds`
`` Message embed rich content, by JSON or YAML with restricted syntaxes, maximum 10 embeds, and maximum 6000 characters for summation from inputs:
- [`embeds[*].title`](#embedstitle)
- [`embeds[*].description`](#embedsdescription)
- [`embeds[*].footer.text`](#embedsfootertext)
- [`embeds[*].author.name`](#embedsauthorname)
- [`embeds[*].fields[*].name`](#embedsfieldsname)
- [`embeds[*].fields[*].value`](#embedsfieldsvalue)#### `embeds[*].title`
`` Message embed title, maximum 256 characters; Support Guilded Markdown.
#### `embeds[*].description`
`` Message embed description, maximum 4096 characters; Support Guilded Markdown.
#### `embeds[*].url`
`` Message embed URL.
#### `embeds[*].timestamp`
`` Message embed timestamp, by ISO 8601 format (e.g.: `"2011-11-11T11:11:11Z"`).
#### `embeds[*].color`
`` Message embed colour (i.e.: left border's colour of the embed); These syntaxes are acceptable:
- **RGB Integer:** `{number}` (e.g.: `2105893`)
- **Hex:** `#{hex}{hex}{hex}` / `#{hex}{hex}{hex}{hex}{hex}{hex}` (e.g.: `#0063B1`)
- **Namespace:** (e.g.: `Blue`)
- **CSS:** (e.g.: `rgb(32, 34, 37)`)
- **Random:** `Random`> [!NOTE]
> - Alpha channel is not supported.
> - General namespace are provided by NPM package [`color-name-list`](https://www.npmjs.com/package/color-name-list), list maybe change or remove without any notification, it is recommended to use value instead.#### `embeds[*].footer`
`` Message embed footer.
#### `embeds[*].footer.text`
`` Message embed footer text, maximum 2048 characters; Support Guilded Markdown.
#### `embeds[*].footer.iconUrl`
`` Message embed footer icon, only support URL of HTTP, HTTPS, and attachments.
#### `embeds[*].image`
`` Message embed image.
#### `embeds[*].image.url`
`` Message embed image URL, only support URL of HTTP, HTTPS, and attachments.
#### `embeds[*].thumbnail`
`` Message embed thumbnail.
#### `embeds[*].thumbnail.url`
`` Message embed thumbnail URL, only support URL of HTTP, HTTPS, and attachments.
#### `embeds[*].author`
`` Message embed author.
#### `embeds[*].author.name`
`` Message embed author name, maximum 256 characters.
#### `embeds[*].author.url`
`` Message embed author URL.
#### `embeds[*].author.iconUrl`
`` Message embed author icon, only support URL of HTTP, HTTPS, and attachments.
#### `embeds[*].fields`
`` Message embed fields, maximum 25 fields.
#### `embeds[*].fields[*].name`
`` Message embed field name, maximum 256 characters; Support Guilded Markdown.
#### `embeds[*].fields[*].value`
`` Message embed field value, maximum 1024 characters; Support Guilded Markdown.
#### `embeds[*].fields[*].inline`
`` Whether the message embed field should display inline.
### `files`
`` Message attachments/files, by Glob path or literal path (select by input [`files_glob`](#files_glob)) under the workspace, separate each value per line, maximum 8 MB and 10 files.
### `files_glob`
`` Whether input [files](#files) should accept Glob path instead of literal path.
### `truncate_enable`
`` Whether to try truncate firstly when inputs are too large.
### `truncate_ellipsis`
`` Ellipsis mark.
### `truncate_position`
`` Ellipsis position.
- **`"end"`:** At the end of the string.
- **`"middle"`:** At the middle of the string.
- **`"start"`:** At the start of the string.## 🧩 Outputs
### `response`
`` Response content.
### `status_code`
`` Request status code.
### `status_ok`
`` Whether the request was successful.
### `status_text`
`` Request status text.
## ✍️ Examples
- Hello, world!
```yml
jobs:
job_id:
name: "Send Guilded Webhook"
runs-on: "ubuntu-latest"
steps:
- uses: "hugoalh/[email protected]"
with:
key: "${{secrets.GUILDED_WEBHOOK_KEY}}"
content: "Hello, world!"
```## 📚 Guides
- GitHub Actions
- [Enabling debug logging](https://docs.github.com/en/actions/monitoring-and-troubleshooting-workflows/enabling-debug-logging)
- [Encrypted secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets)
- Guilded
- [Execute Webhook](https://guildedapi.com/resources/webhook/#execute-webhook)
- [Incoming Webhooks](https://support.guilded.gg/hc/en-us/articles/360038927934-Incoming-Webhooks)