ייצוא משתמשים לקובץ CSV

:bookmark: This guide explains how to export user information from your Discourse site into a CSV file.

:person_raising_hand: Required user level: Administrator

Exporting user information can be useful for various administrative tasks or data analysis. This guide will walk you through the process of exporting your users’ data to a CSV file.

Exporting user data

Step 1: Access the Users List

  1. Navigate to the Admin panel of your Discourse site
  2. Go to the Users List page at /admin/users/list

Step 2: Initiate the export

  1. On the Users List page, locate and click the “Export” button

:bulb: The export respects the currently active user list filter. For example, if you are viewing users filtered by a specific trust level, only those users will be exported.

Step 3: Retrieve the CSV file

  1. After initiating the export, you’ll receive a personal message (PM) containing a download link for the exported CSV file

    :warning: The CSV file download link will expire after 48 hours. Make sure to download it within this timeframe.

Step 4: Download and view the exported data

  1. Click the download link in the PM to obtain the CSV file
  2. Open the CSV file using a spreadsheet application or text editor

The exported CSV includes the following fields:

  • User data: id, name, username, email, title, created_at, last_seen_at, last_posted_at, last_emailed_at, trust_level, approved, suspended_at, suspended_till, silenced_till, active, admin, moderator, ip_address, staged, secondary_emails
  • User stats: topics_entered, posts_read_count, time_read, topic_count, post_count, likes_given, likes_received
  • User profile: location, website, views
  • DiscourseConnect (if enabled): external_id, external_email, external_username, external_name, external_avatar_url
  • Custom user fields: any custom user fields defined on your site
  • Groups: group_names

Best practices

  • Handle the exported data with care, as it may contain sensitive information
  • Use the exported data in compliance with your site’s privacy policy and applicable data protection laws

FAQs

Q: How often can I export user data?
A: You can export user data as often as needed. However, consider the load on your server and only perform exports when necessary.

Q: Can I customize the fields included in the export?
A: The export includes the predefined set of fields listed above, plus any custom user fields and group names. If you need additional information not included in the export you can create a custom query using the data explorer.

Last edited by @JammyDodger 2024-07-09T06:59:14Z

Last checked by @hugh 2024-07-09T05:02:58Z

Check documentPerform check on document:
16 לייקים