• Hi,

    Is it possible to programatically filter the “Customer bank statement”?

    Scenario: Multi-lingual shop (in this case WPML, but it could be anything else) with a different domain name on each language.

    For Spanish the back statement should be tortillas.es and for Portuguese it should be pasteisdenata.pt

    I’ve looked into the code and I couldn’t find a specific filter for this field. O course I could just go Cowboy Style and use the wc_stripe_generate_payment_request filter, but that would not benefit from all the WC_Stripe_Helper functions that clean and generate the descriptor with or without the order number.

    Maybe implement two filters right at the beginning of WC_Stripe_Payment_Gateway::generate_payment_request for the $statement_descriptor and $short_statement_descriptor variables?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi Marco,

    Thank you for contacting WooCommerce Plugin Support. I’m glad to help you with your question. The customer bank statement descriptor is the text that appears on your customers’ bank statements when they make a purchase from your site. It is important to have a clear and accurate descriptor to avoid confusion and disputes.

    By default, WooPayments uses your site’s URL as the statement descriptor, but you can change this under Payments > Settings. However, this setting applies to all transactions, regardless of the language or domain name of your site. If you want to have different statement descriptors for different languages or domains, you will need to use some custom code to filter the statement descriptor based on the current site language or domain.

    Unfortunately, there is no specific filter for the statement descriptor in WooPayments, but you can use the wc_stripe_generate_payment_request filter to modify the payment request array before it is sent to Stripe. This filter is applied in the WC_Stripe_Payment_Gateway::generate_payment_request method, which is where the statement descriptor and the short statement descriptor are generated.

    Please note that this filter is not officially supported by WooPayments, and it may change or be removed in future updates. Therefore, you should use it with caution and test it thoroughly before applying it to your live site.

    Also, please be aware that the statement descriptor has some requirements and limitations. You can find more information on the statement descriptor requirements and recommendations here: Requirements and recommendations for bank statement descriptor.

    I hope this helps you achieve what you want. Please let us know if you have any other questions or concerns.

    Hi,

    Not using WooPayments. This is the regular Stripe plugin, not through Woo, support forum.

    My ticket was basically a suggestion to add two new filters directly to the variables so that this would be taken for (as it is right now for the unfiltered variables):

    be aware that the statement descriptor has some requirements and limitations.

    Hi there @webdados ??

    Scenario: Multi-lingual shop (in this case WPML, but it could be anything else) with a different domain name on each language.

    For Spanish the back statement should be tortillas.es and for Portuguese it should be pasteisdenata.pt

    From what I gather, a way to differentiate the transactions for the Spanish and Portuguese sales on the site is needed, via the FULL BANK STATEMENT found within the settings of WooCommerce Stripe Payment Gateway. Correct?

    Could you share some further details of how it is set up, please? For example, is it a WordPress Multisite?

    How about the following:

    • One Stripe account
    • Keys, and webhooks, set up for each site

    Would that be an option for the site’s needs?

    To get an idea of how your site is configured, could you please share a copy of your site’s System Status, as exemplified here? Once you’ve done that, paste it here in your response.

    Looking forward to hearing from you!

    A multi-lingual website is just one website that look like being several websites. For example: https://quadrosvidro.pt/ and https://pizarracristal.es/

    These are the exact same unique WordPress, WooCommerce, Stripe plugin, … install. It’s just that a different language is served depending on the domain.

    So, we’re using the same Keys because it’s actually just one website and one instance of the Stripe plugin.

    Creating those filters would allow developers to change the descriptor based on the current language being shown to the customer. Yes, we can use the wc_stripe_generate_payment_request but it’s not as elegant from a developer point of view.

    I just submitted an issue and a PR: https://github.com/woocommerce/woocommerce-gateway-stripe/issues/2841 so I’ll close this ticket here and go on on Github.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Is it possible to filter bank statement descriptor’ is closed to new replies.