Effortlessly extract and analyze complete message histories from channels and DMs. Gain insights into community engagement, track communication patterns, and export valuable content—all in a clean, structured JSON format. Unlock the full potential of your Discord data with our advanced scraper!
Extract and analyze Discord channel and direct message history with ease. This scraper / API will return a comprehensive list of messages from your Discord conversations, including text content, attachments, and participant information.
The scraper provides detailed message data in JSON format with the following fields:
id
- Unique message identifiercontent
- The message text contentstype
- Message type (0 for normal messages)channel_id
- ID of the channel where the message was sentauthor
- Detailed information about the message sender:
id
- User's Discord IDusername
- User's display nameglobal_name
- User's global display namediscriminator
- User's discriminatoravatar
- Avatar hashtimestamp
- When the message was sent (ISO 8601 format)edited_timestamp
- When the message was last edited (null if never edited)attachments
- Array of attached filesembeds
- Array of rich embeds in the messagementions
- Array of mentioned usersmention_roles
- Array of mentioned rolespinned
- Whether the message is pinnedmention_everyone
- Whether the message mentions @everyone/@hereflags
- Message flags (e.g., crossposted, urgent, etc.)components
- Message components (buttons, select menus, etc.)Example output:
1{ 2 "type": 0, 3 "content": "Hello @here 👋
Welcome to the channel dedicated for intros and chat between community members. For support go to the relevant support section.
I will start with an introduction 😄
I am Saurav Jain from Delhi, India. 🇮🇳
I am the Developer Community Manager at Apify. You will see my replying to everybody in the community, helping members using our products, hosting events, and much more.
Feel free to tag me in your messages, would love to interact with everyone. ❤️", 4 "mentions": [], 5 "mention_roles": [], 6 "attachments": [], 7 "embeds": [], 8 "timestamp": "2024-02-12T12:32:13.826000+00:00", 9 "edited_timestamp": null, 10 "flags": 0, 11 "components": [], 12 "id": "1206578509569593364", 13 "channel_id": "1206131794261315594", 14 "author": { 15 "id": "636370983460274219", 16 "username": "sauain", 17 "avatar": "6a6cb07c7deaace0278061593f8979c0", 18 "discriminator": "0", 19 "public_flags": 64, 20 "flags": 64, 21 "banner": null, 22 "accent_color": null, 23 "global_name": "Saurav Jain", 24 "avatar_decoration_data": null, 25 "banner_color": null, 26 "clan": null, 27 "primary_guild": null 28 }, 29 "pinned": false, 30 "mention_everyone": true, 31 "tts": false 32}
Parameter | Type | Description |
---|---|---|
channelUrls | Array | Array of Discord channel URLs to scrape. Must be in format: https://discord.com/channels/SERVER_ID/CHANNEL_ID for server channels or https://discord.com/channels/@me/CHANNEL_ID for DMs |
authToken | String | Your Discord authorization token (required) |
maxMessagesPerChannel | Integer | Maximum number of messages to scrape per channel (optional, empty means unlimited) |
The scraper automatically handles:
In order for the scraper to work, you need to obtain your Discord authentication token. There are three possible ways to get it: through the Network section of the browser's Developer Tools, by pasting some JavaScript code in the browser console or through a browser extension. All three methods are described below.
The token looks something like this:
MTk4NjI0MzY5ODc1NDMyOTYw.HjKL9_.QWxZcVBnTmFsUHFaWXhDdkJyTnE2RHNqS3M0-8
webpackChunkdiscord_app.push([[Symbol()],{},e=>{t=Object.values(e.c).find(x=>x?.exports?.default?.getToken)?.exports?.default?.getToken();console.log(t);copy(t);}]);
These are third party extensions that will get you the token. We are not affiliated with them.
The scraper uses Discord's API with your authentication token to access specified channels and DMs. It fetches message history in batches of 100 messages at a time, automatically handling pagination to retrieve the complete history. The scraper respects Discord's rate limits (50 requests per second) and includes automatic retries for failed requests. All data is processed and returned in a clean, structured JSON format that preserves the complete message context including attachments, embeds, and user information.
Ready to extract your Discord chat history? Start scraping now! 🚀
Yes, if you're scraping publicly available data for personal or internal use. Always review Websute's Terms of Service before large-scale use or redistribution.
No. This is a no-code tool — just enter a job title, location, and run the scraper directly from your dashboard or Apify actor page.
It extracts job titles, companies, salaries (if available), descriptions, locations, and post dates. You can export all of it to Excel or JSON.
Yes, you can scrape multiple pages and refine by job title, location, keyword, or more depending on the input settings you use.
You can use the Try Now button on this page to go to the scraper. You’ll be guided to input a search term and get structured results. No setup needed!