{"id":13701950,"url":"https://github.com/ben-forster/revolt","last_synced_at":"2025-12-15T00:55:56.341Z","repository":{"id":155424125,"uuid":"632608139","full_name":"ben-forster/revolt","owner":"ben-forster","description":"Go wrapper for https://revolt.chat/","archived":false,"fork":false,"pushed_at":"2023-12-24T15:23:31.000Z","size":122,"stargazers_count":7,"open_issues_count":15,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-12-06T22:03:25.426Z","etag":null,"topics":["go","revolt","revolt-api","revolt-api-wrapper","revolt-chat","revolt-chat-api-wrapper"],"latest_commit_sha":null,"homepage":"","language":"Go","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/ben-forster.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}},"created_at":"2023-04-25T19:02:38.000Z","updated_at":"2024-06-07T02:12:31.000Z","dependencies_parsed_at":"2023-12-24T14:25:27.480Z","dependency_job_id":"16ce14e8-4571-443b-9f57-277056712a3a","html_url":"https://github.com/ben-forster/revolt","commit_stats":null,"previous_names":["ben-forster/revgo","ben-forster/revolt.go"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ben-forster%2Frevolt","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ben-forster%2Frevolt/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ben-forster%2Frevolt/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ben-forster%2Frevolt/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ben-forster","download_url":"https://codeload.github.com/ben-forster/revolt/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252439364,"owners_count":21747993,"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":["go","revolt","revolt-api","revolt-api-wrapper","revolt-chat","revolt-chat-api-wrapper"],"created_at":"2024-08-02T21:00:28.183Z","updated_at":"2025-12-15T00:55:56.279Z","avatar_url":"https://github.com/ben-forster.png","language":"Go","funding_links":[],"categories":["💻 API Libraries"],"sub_categories":["Go"],"readme":"[![Go Reference](https://pkg.go.dev/badge/github.com/ben-forster/revolt.svg)](https://pkg.go.dev/github.com/ben-forster/revolt)\n[![Go Report](https://goreportcard.com/badge/github.com/ben-forster/revolt)](https://goreportcard.com/report/github.com/ben-forster/revolt)\n[![Go Version](https://img.shields.io/github/go-mod/go-version/ben-forster/revolt?filename=go.mod)](https://golang.org/doc/devel/release.html)\n[![License](https://img.shields.io/badge/License-MIT%202.0-blue.svg)](https://github.com/ben-forster/revolt/blob/master/LICENSE)\n[![Revolt.go Version](https://img.shields.io/github/v/release/ben-forster/revolt?label=release)](https://github.com/ben-forster/revolt/releases/latest)\n\n# Revolt.go\n\nRevolt.go is a Go package for writing bots and self-bots for Revolt.\n\n## Features\n- Event listener.\n- Easy to use.\n- Support for self bots.\n- Simple caching system.\n\n## Getting Started\n\n### Installation\n- Create a new project and initiate the go.mod file. `go mod init example`\n- Install the package using `go get github.com/ben-forster/revolt`\n- Create your main bot file. `touch main.go`\n\n## API Reference\nClick [here](https://pkg.go.dev/github.com/ben-forster/revolt@v0.0.1) for the library's API reference.\n\nOfficial documentation will come in the near future.\n\n## Notice\n\nPlease note that you will need **Go 1.21** to use this library.\n\nThis package is still under development and while you can create a working bot, the library is not finished. You can see a development roadmap [here](https://github.com/users/ben-forster/projects/8). Please create an issue if you would like to contribute.\n\n## Ping Pong Example (Bot)\n\n```go\npackage main\n\nimport (\n    \"os\"\n    \"os/signal\"\n    \"syscall\"\n\n    \"github.com/ben-forster/revolt\"\n)\n\nfunc main() {\n    // Init a new client.\n    client := revolt.Client{\n        Token: \"bot token\",\n    }\n\n    // Listen a on message event.\n    client.OnMessage(func(m *revolt.Message) {\n        if m.Content == \"!ping\" {\n            sendMsg := \u0026revolt.SendMessage{}\n            sendMsg.SetContent(\"🏓 Pong!\")\n\n            m.Reply(true, sendMsg)\n        }\n    })\n\n    // Start the client.\n    client.Start()\n\n    // Wait for close.\n    sc := make(chan os.Signal, 1)\n\n    signal.Notify(\n        sc,\n        syscall.SIGINT,\n        syscall.SIGTERM,\n        os.Interrupt,\n    )\n    \u003c-sc\n\n    // Destroy client.\n    client.Destroy()\n}\n\n```\n\n## Ping Pong Example (Self-Bot)\n\n```go\npackage main\n\nimport (\n    \"os\"\n    \"os/signal\"\n    \"syscall\"\n\n    \"github.com/ben-forster/revolt\"\n)\n\nfunc main() {\n    // Init a new client.\n    client := revolt.Client{\n        SelfBot: \u0026revolt.SelfBot{\n            Id:           \"session id\",\n            SessionToken: \"session token\",\n            UserId:       \"user id\",\n        },\n    }\n\n    // Listen a on message event.\n    client.OnMessage(func(m *revolt.Message) {\n        if m.Content == \"!ping\" {\n            sendMsg := \u0026revolt.SendMessage{}\n            sendMsg.SetContent(\"🏓 Pong!\")\n\n            m.Reply(true, sendMsg)\n        }\n    })\n\n    // Start the client.\n    client.Start()\n\n    // Wait for close.\n    sc := make(chan os.Signal, 1)\n\n    signal.Notify(\n        sc,\n        syscall.SIGINT,\n        syscall.SIGTERM,\n        os.Interrupt,\n    )\n    \u003c-sc\n\n    // Destroy client.\n    client.Destroy()\n}\n\n```\n\n## Credit\n\nThis project is a mantained and re-worked version of 5elenay's library [revoltgo](https://github.com/5elenay/revoltgo).","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fben-forster%2Frevolt","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fben-forster%2Frevolt","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fben-forster%2Frevolt/lists"}