Import Existing Wordpress Users into Discourse

There are a few ways you could approach it. If you are ok with doing some programming, there are some static functions that the WP Discourse plugin makes available for sites that are using WordPress as the SSO provider for Discourse. The functions are in this file: https://github.com/discourse/wp-discourse/blob/master/lib/utilities.php.

To use them, you would need to loop through all your WordPress users and for each user call:

$sso_params = \WPDiscourse\Utilities\Utilities::get_sso_params( $user );

\WPDiscourse\Utilities\Utilities::sync_sso_record( $sso_params );

The $user parameter in the first line should be a WordPress user object.

You will need to be aware of Discourse rate limiting. You’ll want to limit your requests to about one request per second. When the call to sync_sso_record is successful, a Discourse user will be returned.