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

Feature branch : Settings Synchronization #4002

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from

Conversation

hsingyuc
Copy link
Contributor

@hsingyuc hsingyuc commented Mar 3, 2025

Fixes #3916

Changes proposed in this Pull Request:

As part of the settings synchronization project, we want to make Stripe a single source of truth. This PR add a method to get the Stripe payment method configuration.

Testing instructions

  1. Install and activate Code Snippets
  2. Add below to code snippets
add_action( 'admin_init', function() {
	if ( class_exists( 'WC_Stripe_API' ) ) {
		error_log( print_r( WC_Stripe_API::get_payment_method_configurations(), true ) );
	}
}, 1000  );
  1. Refresh the page
  2. Visit your debug log and see below reponse
Screenshot 2025-02-28 at 3 05 35 PM
  • Covered with tests (or have a good reason not to test in description ☝️)
  • Tested on mobile (or does not apply)

Changelog entry

  • This Pull Request does not require a changelog entry. (Comment required below)
Changelog Entry Comment

Fetch Stripe settings with Stripe configuration API

Post merge

@hsingyuc hsingyuc requested review from a team and Mayisha and removed request for a team March 3, 2025 01:35
Copy link
Contributor

@Mayisha Mayisha left a comment

Choose a reason for hiding this comment

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

The get_payment_method_configurations method is retrieving the payment method configuration perfectly from Stripe :shipit:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Settings Synchronization : Fetch Stripe settings with Stripe configuration API
2 participants