Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Redoing how we fetch access tokens from WooCommerce Connect Server. #2788

Merged
merged 5 commits into from
Aug 21, 2024

Conversation

rawdreeg
Copy link
Contributor

@rawdreeg rawdreeg commented Aug 14, 2024

Changes proposed in this Pull Request:

Must be tested together with https://github.com/Automattic/woocommerce-connect-server/pull/2563.

Refactors how oAuth access tokens are obtained. Instead of taking them from the incoming query string, a call to WooCommerce Connect Sever to exchange the incoming oAuth code for the access token is made.

Detailed test instructions:

  1. Set up a local wcs environment using the woocommerce-connect-server's (https://github.com/Automattic/woocommerce-connect-server/pull/2563) branch.
  2. Configure the extension to use your local WooCommerce Connect Server version by search-replacing api.woocommerce.com with your local wcs url through the includes/Handlers/Connection.php file of the plugin.
  3. Try to connect your Facebook for WooCommerce plugin to Facebook.

Changelog entry

Update - Access Token retrieval procedure.

@github-actions github-actions bot added the changelog: update Big changes to something that wasn't broken. label Aug 14, 2024
@rawdreeg rawdreeg self-assigned this Aug 14, 2024
@rawdreeg rawdreeg requested a review from a team August 14, 2024 13:19
@message-dimke message-dimke self-requested a review August 20, 2024 10:32
Copy link
Contributor

@message-dimke message-dimke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did test the update and it works. The only minor thing is I had to use wp_remote_get instead of the safe version of it when testing locally. Must be related to some certificate checks.

LGTM! Thank you, Rodrigue!

@rawdreeg rawdreeg merged commit 4a56dd9 into develop Aug 21, 2024
4 checks passed
@rawdreeg rawdreeg deleted the update/implement-token-exchange branch August 21, 2024 08:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog: update Big changes to something that wasn't broken.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants