AI prompts
base on Save or export your private and public Slack messages, threads, files, and users locally without admin privileges. # Slack Dumper
Purpose: archive your private and public Slack messages, users, channels,
files and emojis. Generate Slack Export without admin privileges.
[![Slackdump screenshot](doc/slackdump.webp)](https://github.com/rusq/slackdump/releases/)
**Quick links**:
- [Join the discussion in Telegram](https://t.me/slackdump).
- [Buy me a cup of tea](https://ko-fi.com/rusq_), or use **Github Sponsors**
button on the top of the page.
- [![Go reference](https://pkg.go.dev/badge/github.com/rusq/slackdump/v3.svg)][godoc]
- How to's:
- [Mattermost migration][mmost] steps
- [SlackLogViewerとSlackdumpを一緒に使用する](https://kenkyu-note.hatenablog.com/entry/2022/09/02/090949)
- [v1 Overview on Medium.com](https://medium.com/@gilyazov/downloading-your-private-slack-conversations-52e50428b3c2) (outdated)
[godoc]: https://pkg.go.dev/github.com/rusq/slackdump/v3/
[mmost]: doc/usage-export.rst
## Description
Typical use scenarios:
* archive your private conversations from Slack when the administrator
does not allow you to install applications OR you don't want to use
potentially privacy-violating third-party tools,
* archive channels from Slack when you're on a free "no archive" subscription,
so you don't lose valuable knowledge in those channels,
* create a Slack Export archive without admin access, or
* save your favourite emojis.
There are four modes of operation (more on this in [User Guide][ug]):
1. List users/channels
1. Dumping messages and threads
1. Creating a Slack Export in Mattermost or Standard modes.
1. Emoji download mode.
Slackdump accepts two types of input (see [Dumping
Conversations][usage-channels] section):
1. the URL/link of the channel or thread, OR
1. the ID of the channel.
[ug]: doc/README.rst
[usage-channels]: doc/usage-channels.rst
Quick Start
===========
On macOS, you can install Slackdump with Homebrew::
```shell
brew install slackdump
```
On other Operating Systems, please follow these steps:
1. Download the latest release for your operating system from the [releases] page.
1. Unpack the archive to any directory.
1. Run the `./slackdump` or `slackdump.exe` executable (see note below).
1. You know the drill: use arrow keys to select the menu item, and Enter (or
Return) to confirm.
[releases]: https://github.com/rusq/slackdump/releases/
By default, Slackdump uses the EZ-Login 3000 automatic login, and interactive
mode.
> [!NOTE]
> On Windows and macOS you may be presented with "Unknown developer" window,
> this is fine. Reason for this is that the executable hasn't been signed by
> the developer certificate.
To work around this:
- **on Windows**: click "more information", and press "Run
Anyway" button.
- **on macOS** 14 Sonoma and prior: open the folder in Finder, hold Option
and double click the executable, choose Run.
- **on macOS** 15 Sequoia and later: start the slackdump, OS will show the
"Unknown developer" window, then go to System Preferences -> Security and
Privacy -> General, and press "Open Anyway" button.
## Slackord2: Migrating to Discord
If you're migrating to Discord, the recommended way is to use
[Slackord2](https://github.com/thomasloupe/Slackord2) — a great tool with a
nice GUI, that is compatible with the export files generated by Slackdump.
## User Guide
For more advanced features and instructions, please see the [User Guide][ug].
# Previewing Results
Once the workspace data is dumped, you can run built-in viewer:
```shell
slackdump view <zip or directory>
```
The built-in viewer supports all types of dumps:
1. Slackdump Archive format;
1. Standard and Mattermost Slack Export;
1. Dump mode files
The built-in viewer is experimental, any contributions to make it better looking are welcome.
Alternatively, you can use one of the following tools to preview the
export results:
- [SlackLogViewer] - a fast and powerful Slack Export viewer written in C++, works on Export files (images won't be displayed, unless you used an export token flag).
- [Slackdump2Html] - a great Python application that converts Slack Dump to a
static browsable HTML. It works on Dump mode files.
- [slack export viewer][slack-export-viewer] - Slack Export Viewer is a well known viewer for
slack export files.
[SlackLogViewer]: https://github.com/thayakawa-gh/SlackLogViewer/releases
[Slackdump2Html]: https://github.com/kununu/slackdump2html
[slack-export-viewer]: https://github.com/hfaran/slack-export-viewer
## Using as a library
Download:
```shell
go get github.com/rusq/slackdump/v3
```
### Example
```go
package main
import (
"context"
"log"
"github.com/rusq/slackdump/v2"
"github.com/rusq/slackdump/v2/auth"
)
func main() {
provider, err := auth.NewValueAuth("xoxc-...", "xoxd-...")
if err != nil {
log.Print(err)
return
}
sd, err := slackdump.New(context.Background(), provider)
if err != nil {
log.Print(err)
return
}
_ = sd
}
```
See [Package Documentation][godoc].
### Using Custom Logger
Slackdump uses a "log/slog" package, it defaults to "slog.Default()". Set the
default slog logger to the one you want to use.
If you were using `logger.Silent` before, you would need to
[implement][slog-handler-guide] a discarding [Handler][godoc-slog-handler] for slog.
[slog-handler-guide]: https://github.com/golang/example/blob/master/slog-handler-guide/README.md
[godoc-slog-handler]: https://pkg.go.dev/log/slog#Handler
## FAQ
#### Do I need to create a Slack application?
No, you don't. Just run the application and EZ-Login 3000 will take
care of the authentication or, alternatively, grab that token and
cookie from the browser Slack session. See [User's Guide][ug].
#### I'm getting "invalid_auth" error
Go get the new Cookie from the browser and Token as well.
#### Slackdump takes a very long time to cache users
Disable the user cache with `-no-user-cache` flag.
#### How to read the export file?
```shell
slackdump view <ZIP-archive or directory>
```
#### My Slack Workspace is on the Free plan. Can I get data older than 90-days?
No, unfortunately you can't. Slack doesn't allow to export data older than 90
days for free workspaces, the API does not return any data before 90 days for
workspaces on the Free plan.
## Thank you
Big thanks to all contributors, who submitted a pull request, reported a bug,
suggested a feature, helped to reproduce, or spent time chatting with me on
the Telegram or Slack to help to understand the issue and tested the proposed
solution.
Also, I'd like to thank current sponsors:
- [<img class="avatar avatar-user" src="https://avatars.githubusercontent.com/u/9138285?s=60&v=4" width="30" height="30" alt="@malsatin">](https://github.com/malsatin) @malsatin
And everyone who made a donation to support the project in the past and keep
supporting the project:
- Vivek R.
- Fabian I.
- Ori P.
- Shir B. L.
- Emin G.
- Robert Z.
- Sudhanshu J.
# Bulletin Board
Messages that were conveyed with the donations:
- 25/01/2022: Stay away from [TheSignChef.com][glassdoor], ya hear, they don't
pay what they owe to their employees.
[glassdoor]: https://www.glassdoor.com/Reviews/The-Sign-Chef-Reviews-E1026706.htm
", Assign "at most 3 tags" to the expected json: {"id":"11505","tags":[]} "only from the tags list I provide: [{"id":77,"name":"3d"},{"id":89,"name":"agent"},{"id":17,"name":"ai"},{"id":54,"name":"algorithm"},{"id":24,"name":"api"},{"id":44,"name":"authentication"},{"id":3,"name":"aws"},{"id":27,"name":"backend"},{"id":60,"name":"benchmark"},{"id":72,"name":"best-practices"},{"id":39,"name":"bitcoin"},{"id":37,"name":"blockchain"},{"id":1,"name":"blog"},{"id":45,"name":"bundler"},{"id":58,"name":"cache"},{"id":21,"name":"chat"},{"id":49,"name":"cicd"},{"id":4,"name":"cli"},{"id":64,"name":"cloud-native"},{"id":48,"name":"cms"},{"id":61,"name":"compiler"},{"id":68,"name":"containerization"},{"id":92,"name":"crm"},{"id":34,"name":"data"},{"id":47,"name":"database"},{"id":8,"name":"declarative-gui "},{"id":9,"name":"deploy-tool"},{"id":53,"name":"desktop-app"},{"id":6,"name":"dev-exp-lib"},{"id":59,"name":"dev-tool"},{"id":13,"name":"ecommerce"},{"id":26,"name":"editor"},{"id":66,"name":"emulator"},{"id":62,"name":"filesystem"},{"id":80,"name":"finance"},{"id":15,"name":"firmware"},{"id":73,"name":"for-fun"},{"id":2,"name":"framework"},{"id":11,"name":"frontend"},{"id":22,"name":"game"},{"id":81,"name":"game-engine "},{"id":23,"name":"graphql"},{"id":84,"name":"gui"},{"id":91,"name":"http"},{"id":5,"name":"http-client"},{"id":51,"name":"iac"},{"id":30,"name":"ide"},{"id":78,"name":"iot"},{"id":40,"name":"json"},{"id":83,"name":"julian"},{"id":38,"name":"k8s"},{"id":31,"name":"language"},{"id":10,"name":"learning-resource"},{"id":33,"name":"lib"},{"id":41,"name":"linter"},{"id":28,"name":"lms"},{"id":16,"name":"logging"},{"id":76,"name":"low-code"},{"id":90,"name":"message-queue"},{"id":42,"name":"mobile-app"},{"id":18,"name":"monitoring"},{"id":36,"name":"networking"},{"id":7,"name":"node-version"},{"id":55,"name":"nosql"},{"id":57,"name":"observability"},{"id":46,"name":"orm"},{"id":52,"name":"os"},{"id":14,"name":"parser"},{"id":74,"name":"react"},{"id":82,"name":"real-time"},{"id":56,"name":"robot"},{"id":65,"name":"runtime"},{"id":32,"name":"sdk"},{"id":71,"name":"search"},{"id":63,"name":"secrets"},{"id":25,"name":"security"},{"id":85,"name":"server"},{"id":86,"name":"serverless"},{"id":70,"name":"storage"},{"id":75,"name":"system-design"},{"id":79,"name":"terminal"},{"id":29,"name":"testing"},{"id":12,"name":"ui"},{"id":50,"name":"ux"},{"id":88,"name":"video"},{"id":20,"name":"web-app"},{"id":35,"name":"web-server"},{"id":43,"name":"webassembly"},{"id":69,"name":"workflow"},{"id":87,"name":"yaml"}]" returns me the "expected json"