{"id":13452380,"url":"https://github.com/sowawa/fluent-plugin-slack","last_synced_at":"2025-03-23T19:34:07.917Z","repository":{"id":14230460,"uuid":"16937493","full_name":"sowawa/fluent-plugin-slack","owner":"sowawa","description":null,"archived":false,"fork":false,"pushed_at":"2023-03-02T04:13:45.000Z","size":114,"stargazers_count":132,"open_issues_count":15,"forks_count":52,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-03-14T23:14:25.892Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sowawa.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2014-02-18T04:53:24.000Z","updated_at":"2024-06-04T15:41:14.000Z","dependencies_parsed_at":"2024-01-14T18:05:25.686Z","dependency_job_id":null,"html_url":"https://github.com/sowawa/fluent-plugin-slack","commit_stats":{"total_commits":100,"total_committers":18,"mean_commits":5.555555555555555,"dds":0.61,"last_synced_commit":"4de3aa50d73c10242537f02d39aebf7e20a2f443"},"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sowawa%2Ffluent-plugin-slack","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sowawa%2Ffluent-plugin-slack/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sowawa%2Ffluent-plugin-slack/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sowawa%2Ffluent-plugin-slack/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sowawa","download_url":"https://codeload.github.com/sowawa/fluent-plugin-slack/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245159321,"owners_count":20570361,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-07-31T07:01:22.450Z","updated_at":"2025-03-23T19:34:07.607Z","avatar_url":"https://github.com/sowawa.png","language":"Ruby","funding_links":[],"categories":["Ruby"],"sub_categories":[],"readme":"# fluent-plugin-slack [![Build Status](https://travis-ci.org/sowawa/fluent-plugin-slack.svg)](https://travis-ci.org/sowawa/fluent-plugin-slack)\n\n# Installation\n\n```\n$ fluent-gem install fluent-plugin-slack\n```\n\n# Usage (Incoming Webhook)\n\n```apache\n\u003cmatch slack\u003e\n  @type slack\n  webhook_url https://hooks.slack.com/services/XXX/XXX/XXX\n  channel general\n  username sowasowa\n  icon_emoji :ghost:\n  flush_interval 60s\n\u003c/match\u003e\n```\n\n```ruby\nfluent_logger.post('slack', {\n  :message  =\u003e 'Hello\u003cbr\u003eWorld!'\n})\n```\n\n# Usage (Slackbot)\n\n```apache\n\u003cmatch slack\u003e\n  @type slack\n  slackbot_url https://xxxx.slack.com/services/hooks/slackbot?token=XXXXXXXXX\n  channel general\n  flush_interval 60s\n\u003c/match\u003e\n```\n\n```ruby\nfluent_logger.post('slack', {\n  :message  =\u003e 'Hello\u003cbr\u003eWorld!'\n})\n```\n\n# Usage (Web API a.k.a. Bots)\n\n```apache\n\u003cmatch slack\u003e\n  @type slack\n  token xoxb-XXXXXXXXXX-XXXXXXXXXXXXXXXXXXXXXXXX\n  channel C061EG9SL\n  username sowasowa\n  icon_emoji :ghost:\n  flush_interval 60s\n\u003c/match\u003e\n```\n\n```ruby\nfluent_logger.post('slack', {\n  :message  =\u003e 'Hello\u003cbr\u003eWorld!'\n})\n```\n\n### Parameter\n\n|parameter|description|default|\n|---|---|---|\n|webhook_url|Incoming Webhook URI (Required for Incoming Webhook mode). See https://api.slack.com/incoming-webhooks||\n|slackbot_url|Slackbot URI (Required for Slackbot mode). See https://api.slack.com/slackbot. NOTE: most of optional parameters such as `username`, `color`, `icon_emoji`, `icon_url`, and `title` are not available for this mode, but Desktop Notification via Highlight Words works with only this mode||\n|token|Token for Web API (Required for Web API mode). See https://api.slack.com/web||\n|as_user|post messages as a bot user. See https://api.slack.com/bot-users#post_messages_and_react_to_users. NOTE: This parameter is only enabled if you use the Web API with your bot token. You cannot use both of `username` and `icon_emoji`(`icon_url`) when you set this parameter to `true`.|nil|\n|username|name of bot|nil|\n|color|color to use such as `good` or `bad`. See `Color` section of https://api.slack.com/docs/attachments. NOTE: This parameter must **not** be specified to receive Desktop Notification via Mentions in cases of Incoming Webhook and Slack Web API|nil|\n|icon_emoji|emoji to use as the icon. either of `icon_emoji` or `icon_url` can be specified|nil|\n|icon_url|url to an image to use as the icon. either of `icon_emoji` or `icon_url` can be specified|nil|\n|mrkdwn|enable formatting. see https://api.slack.com/docs/formatting|true|\n|link_names|find and link channel names and usernames. NOTE: This parameter must be `true` to receive Desktop Notification via Mentions in cases of Incoming Webhook and Slack Web API|true|\n|parse|change how messages are treated. `none` or `full` can be specified. See `Parsing mode` section of https://api.slack.com/docs/formatting|nil|\n|channel|Channel name or id to send messages (without first '#'). Channel ID is recommended because it is unchanged even if a channel is renamed||\n|channel_keys|keys used to format channel. %s will be replaced with value specified by channel_keys if this option is used|nil|\n|title|title format. %s will be replaced with value specified by title_keys. title is created from the first appeared record on each tag. NOTE: This parameter must **not** be specified to receive Desktop Notification via Mentions in cases of Incoming Webhook and Slack Web API|nil|\n|title_keys|keys used to format the title|nil|\n|message|message format. %s will be replaced with value specified by message_keys|%s|\n|message_keys|keys used to format messages|message|\n|auto_channels_create|Create channels if not exist. Not available for Incoming Webhook mode (since Incoming Webhook is specific to a channel). A web api `token` for Normal User is required (Bot User can not create channels. See https://api.slack.com/bot-users)|false|\n|https_proxy|https proxy url such as `https://proxy.foo.bar:443`|nil|\n|verbose_fallback|Originally, only `title` is used for the fallback which is the message shown on popup if `title` is given. If this option is set to be `true`, messages are also included to the fallback attribute|false|\n\n`fluent-plugin-slack` uses `SetTimeKeyMixin` and `SetTagKeyMixin`, so you can also use:\n\n|parameter|description|default|\n|---|---|---|\n|timezone|timezone such as `Asia/Tokyo`||\n|localtime|use localtime as timezone|true|\n|utc|use utc as timezone||\n|time_key|key name for time used in xxx_keys|time|\n|time_format|time format. This will be formatted with Time#strftime.|%H:%M:%S|\n|tag_key|key name for tag used in xxx_keys|tag|\n\n`fluent-plugin-slack` is a kind of BufferedOutput plugin, so you can also use [Buffer Parameters](http://docs.fluentd.org/articles/out_exec#buffer-parameters).\n\n## FAQ\n\n### Desktop Notification seems not working?\n\nCurrently, slack.com has following limitations:\n\n1. Desktop Notification via both Highlight Words and Mentions works only with Slackbot Remote Control\n2. Desktop Notification via Mentions works for the `text` field if `link_names` parameter is specified in cases of Incoming Webhook and Slack Web API, that is,\n  * Desktop Notification does not work for the `attachments` filed (used in `color` and `title`)\n  * Desktop Notification via Highlight Words does not work for Incoming Webhook and Slack Web API anyway\n\n## ChangeLog\n\nSee [CHANGELOG.md](CHANGELOG.md) for details.\n\n# Contributors\n\n- [@sonots](https://github.com/sonots)\n- [@kenjiskywalker](https://github.com/kenjiskywalker)\n\n# Copyright\n\n* Copyright:: Copyright (c) 2014- Keisuke SOGAWA\n* License::   Apache License, Version 2.0\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsowawa%2Ffluent-plugin-slack","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsowawa%2Ffluent-plugin-slack","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsowawa%2Ffluent-plugin-slack/lists"}