Jump to content

pjs32

Recommended Posts

Hi,

We are finding clients not being able to update their card details - it shows 

Payment method failed to create successfully. Please try again.
 
 
The logs show
UserID => 1333
message => An unexpected error - No Stripe Payment Method found from token
token => 
 
is their a fix?
Link to comment
Share on other sites

13 hours ago, WHMCS ChrisD said:

@pjs32 are you using a custom client area theme at all?   Does this issue occur on the "Six & Standard Cart" themes?

We are using a custom theme - but we have tested on six and the problem remains.

logs show

UserID => 1979
message => An unexpected error - No Stripe Payment Method found from token
token => 

Link to comment
Share on other sites

8 hours ago, WHMCS ChrisD said:

Does the user have any Pay methods on their profiles?

No - they have no other payment methods.

If they pay an invoice manually with their credit card, then the card is added ok - but when they go to delete the card, they get an error:

 

 [WHMCS Application] ERROR: Error: Call to undefined function WHMCS\Payment\PayMethod\run_hook() in /home/user/public_html/vendor/whmcs/whmcs-foundation/lib/Payment/PayMethod/MigrationProcessor.php:0 Stack trace: #0 /home/user/public_html/vendor/whmcs/whmcs-foundation/lib/User/Client.php(0): WHMCS\Payment\PayMethod\MigrationProcessor->migrateForClient(Object(WHMCS\User\Client)) #1 /home/user/public_html/vendor/whmcs/whmcs-foundation/lib/Auth.php(0): WHMCS\User\Client->migratePaymentDetailsIfRequired() #2 /home/user/public_html/vendor/whmcs/whmcs-foundation/lib/Utility/Bootstrap/Application.php(0): WHMCS\Auth::persistClientSession() #3 /home/user/public_html/init.php(0): WHMCS\Utility\Bootstrap\Application::persistSession() #4 /home/user/public_html/index.php(0): unknown() #5 {main} {"exception":"[object] (Error(code: 0): Call to undefined function WHMCS\\Payment\\PayMethod\\run_hook() at /home/user/public_html/vendor/whmcs/whmcs-foundation/lib/Payment/PayMethod/MigrationProcessor.php:0)"} []

Link to comment
Share on other sites

  • 4 months later...
  • 3 weeks later...
2 hours ago, PhilipUK said:

In our case it turned out to be a security header issue due to the way Stripe handles connections to avoid data hitting your server.  If you have some additional security headers set, I'd suggest looking there for a solution. 

Thanks Phillip -  do you know what header/s that was causing the issue?

 

 

Link to comment
Share on other sites

  • 3 weeks later...
  • 2 months later...
  • 4 months later...

Just ran into this problem myself. After finding nothing but a bunch of confused people discussing it online from a google search, I researched the issue myself and found a solution.

TL;DR

In my case my Content-Security-Policy header was a little too strict. Needed to add https://js.stripe.com to the script policy, and https://api.stripe.com to the script and frame policies.

Link to comment
Share on other sites

On 11/21/2020 at 1:24 AM, wired420 said:

Just ran into this problem myself. After finding nothing but a bunch of confused people discussing it online from a google search, I researched the issue myself and found a solution.

TL;DR

In my case my Content-Security-Policy header was a little too strict. Needed to add https://js.stripe.com to the script policy, and https://api.stripe.com to the script and frame policies.

Hi, how do you fix this? Where to you put https://js.stripe.com?

Link to comment
Share on other sites

On 11/28/2020 at 10:03 AM, Joseph T said:

Hi, how do you fix this? Where to you put https://js.stripe.com?

That would depend on one or many things. What web hosting software do you use? What web server? What kind of configuration setup do you use for that web server? That's not really a question someone else can answer. Probably better off asking google how to add a Content Security Policy header for your setup.

Edited by wired420
Link to comment
Share on other sites

  • 3 weeks later...

Did you ever get a fix for this guys?
I have just updated to 8 for Stripe SCA etc and i get the same error client and admin side adding a card or making a payment with Stripe:

An unexpected error - No Stripe Payment Method found from token

Appreciate any help.

Link to comment
Share on other sites

if it's applicable to your situation, the docs say...

Quote

An unexpected error - No Stripe Payment Method found from token

This error indicates that some of the required data is not being transmitted to Stripe. This is usually due to outdated order form templates. Test this using the Twenty-One or Six system themes and the Standard Cart order form template.

Contact our Support team if the issue persists.

Link to comment
Share on other sites

27 minutes ago, JimJ said:

Thanks but i am testing with those templates and have not changed them.
Issue still persists.

then I think you should follow the last line - contacting Support direct... posting here won't do that (unless you pretend this is just an 8.1 issue and post in the beta forums) - even then, there's no guarantees).

Link to comment
Share on other sites

  • 2 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated