{"id":13821409,"url":"https://github.com/TimboKZ/discord-spoiler-bot","last_synced_at":"2025-05-16T12:33:19.622Z","repository":{"id":50754698,"uuid":"83085808","full_name":"TimboKZ/discord-spoiler-bot","owner":"TimboKZ","description":"🗣️🛑 Spoiler support for Discord","archived":false,"fork":false,"pushed_at":"2024-06-18T08:16:34.000Z","size":279,"stargazers_count":60,"open_issues_count":4,"forks_count":18,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-04-30T22:05:03.869Z","etag":null,"topics":["bot","discord","es6","javascript","spoiler"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/discord-spoiler-bot","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TimboKZ.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-02-24T21:52:15.000Z","updated_at":"2025-03-09T20:01:42.000Z","dependencies_parsed_at":"2024-06-21T14:23:30.310Z","dependency_job_id":"18237476-cbb1-4841-bedf-ba68b77e17a2","html_url":"https://github.com/TimboKZ/discord-spoiler-bot","commit_stats":{"total_commits":48,"total_committers":4,"mean_commits":12.0,"dds":0.0625,"last_synced_commit":"b6fe9746a9a76c633b879f0025a9f8f4c23e6013"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TimboKZ%2Fdiscord-spoiler-bot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TimboKZ%2Fdiscord-spoiler-bot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TimboKZ%2Fdiscord-spoiler-bot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TimboKZ%2Fdiscord-spoiler-bot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TimboKZ","download_url":"https://codeload.github.com/TimboKZ/discord-spoiler-bot/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254530650,"owners_count":22086653,"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":["bot","discord","es6","javascript","spoiler"],"created_at":"2024-08-04T08:01:21.386Z","updated_at":"2025-05-16T12:33:17.377Z","avatar_url":"https://github.com/TimboKZ.png","language":"JavaScript","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"readme":"# Discord Spoiler Bot\n\n[![npm](https://img.shields.io/npm/v/discord-spoiler-bot.svg)](https://www.npmjs.com/package/discord-spoiler-bot)\n[![npm](https://img.shields.io/npm/dt/discord-spoiler-bot.svg)](https://www.npmjs.com/package/discord-spoiler-bot)\n![npm dependencies](https://david-dm.org/TimboKZ/discord-spoiler-bot.svg)\n\nA Discord bot that replaces spoiler messages with GIFs that reveal content on hover.\n\n# Demo\n\n### Single line\n\n![Discord Spoiler Bot in action](https://foxypanda-ghost.s3.amazonaws.com/2017/Feb/Spoiler_Bot_One_Line-1487990846207.gif)\n\n### Multi-line\n\n![Discord Spoiler Bot with multi-line comments](https://foxypanda-ghost.s3.amazonaws.com/2017/Feb/Spoiler_Bot_Multiple_Lines-1487991244852.gif)\n\n### Marking someone else's message as a spoiler\n\n![Discord Spoiler Bot marking other messages as spoilers](https://foxypanda-ghost.s3.amazonaws.com/2017/Feb/Spoiler_Bot_Other_Messages-1488088171731.gif)\n\n# Documentation\n \n Check [Discord Spoiler Bot Wiki](https://github.com/TimboKZ/discord-spoiler-bot/wiki) on GitHub for full documentation. See section below for the quick start guide.\n\n### Quick start\n\nIf you know what you're doing, you can jump right in. First, make sure you have [all prerequisites for `node-canvas` installed](https://github.com/Automattic/node-canvas#installation). Then add Discord Spoiler Bot to your npm project:\n\n```shell\n$ npm install discord-spoiler-bot --save\n```\n\nNow get a secret token for your bot and make sure the bot has permission to read, write and delete messages as well as upload files. Create a file called `index.js` and put the following inside:\n\n```javascript\n'use strict';\n\nconst SpoilerBot = require('discord-spoiler-bot');\n\nlet config = {\n    token: 'you_secret_token_here',\n};\n\nlet bot = new SpoilerBot(config);\nbot.connect();\n```\n\nLaunch your bot using Node.js:\n\n```shell\n$ node index.js\n```\n\nAnd you're done! Write messages of format `\u003ctopic\u003e:spoiler:\u003ccontent\u003e` to mark your own messages as spoilers, e.g.:\n\n```\nFMA:spoiler:Elric brothers are alchemists!\n```\n\nTo mark someone else's messages, use `\u003cmessage-id\u003e:spoils:\u003ctopic\u003e`, but you will have to configure permissions first. See [Configuration](https://github.com/TimboKZ/discord-spoiler-bot/wiki/Configuration) section.\n\nAlready have a bot running on [discord.js](https://github.com/hydrabolt/discord.js/) or [discord.io](https://github.com/izy521/discord.io)? You can supply an instance of `Client` instead of a token, see [Usage](https://github.com/TimboKZ/discord-spoiler-bot/wiki/Usage) section for examples.\n\n# Reporting bugs\n\nPlease create an issue thread [here](https://github.com/TimboKZ/discord-spoiler-bot/issues). I will try to reply and resolve issues to the best of my ability.\n\n### Known issues\n\n* It's been reported that GIFs play continuously on mobile devices instead of stopping after revealing the spoiler. Sadly this is a limitation of the mobile Discord app and I can't do anything about it.\n* On Windows, `node-canvas` library does not support true type fonts so Discord Spoiler Bot uses the default `node-canvas` font instead of Source Sans Pro Regular. \n\n# Contributing\n\nI believe this bot is feature-complete, and from now on will most likely only fix bugs. Before adding a new feature to this bot and creating a pull request, make sure said feature makes sense in the context of Discord Spoiler Bot.\n\nMake sure `npm test` and `npm run lint` return no errors before making a pull request, otherwise I might reject it. `npm run test-no-delete` is available for your convenience, running this command will make sure that GIFs produced during testing are not removed so you can inspect them for any artifacts.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FTimboKZ%2Fdiscord-spoiler-bot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FTimboKZ%2Fdiscord-spoiler-bot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FTimboKZ%2Fdiscord-spoiler-bot/lists"}