Creating a Custom OAuth Application
WordPress uses the OAuth authentication standard, which requires the authenticating user to interact with WordPress via the browser.
Procedure
The following steps install the OAuth 2.0 plug-in and registers the provider in the WordPress admin console, creating what WordPress calls a "connected app". They also generate the OAuth credentials for
OAuthClientId and
OAuthClientSecret, which are needed to establish a connection for various authentication methods, as described in
Establishing a Connection.
- Log into your site through the WordPress admin panel.
- Install the OAuth2 Plugin.
To install the plugin manually:
- Download the plugin folder.
- Copy the downloaded folder to the wp-content\plugins folder.
- In the WordPress admin interface, use the Plugins menu to activate the plugin.
- Navigate to OAuth Server > Add New Client.
- Fill in all required fields. Set CallbackURL to http://localhost:portnumber.
- Click Create Client. The admin panel displays the Client Id, Client Key, and Client Secret. Record these values for future reference.
- Navigate to Users > Applications > YourAppName and approve your new application.