Skip to content

Commit

Permalink
docs(README): add chat export
Browse files Browse the repository at this point in the history
  • Loading branch information
iyear committed Oct 14, 2022
1 parent 823e481 commit 22b9ce5
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 1 deletion.
15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,21 @@ List all your chats:
tdl chat ls
```

Export minimal JSON for tdl download (NOT for backup):

```shell
# will export all media files in the chat.
# chat input examples: `@iyear`, `iyear`, `123456789`(chat id), `https://t.me/iyear`, `+1 123456789`

tdl chat export -c CHAT_INPUT

# specify the time period with timestamp format, default is start from 1970-01-01, end to now
tdl chat export -c CHAT_INPUT --from 1665700000 --to 1665761624

# specify the output file path, default is `tdl-export.json`
tdl chat export -c CHAT_INPUT -o /path/to/output.json
```

## Env

Avoid typing the same flag values repeatedly every time by setting environment variables.
Expand Down
11 changes: 10 additions & 1 deletion docs/desktop_export.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
## Get desktop clients exported JSON

1. Choose the dialog you want to export, and click the three dots in the upper right corner, then click `Export Chat History`.
There are two ways to export the JSON you need

### TDL (especially for protected chats)

Please refer to [README](../README.md#chat-utilities)

### Official desktop clients

1. Choose the dialog you want to export, and click the three dots in the upper right corner, then
click `Export Chat History`.

2. Uncheck all boxes(you don't need to download them now) and set `Size Limit` to minimum

Expand Down

0 comments on commit 22b9ce5

Please sign in to comment.