Gravity Form Stripe trial + setup fee - stripe-payments

I'm trying to build a subscription plan with free 30day period and a setup fee.
I'm using wordpress with Gravity Form and the Stripe add-on.
In the Stripe form settings the trial can be defined but If I enable the trial period I can't define the setup fee (there's a js hiding the input).
If I setup both of them (forcing the visibility of the field) and try out the form, I get the currency mismatching error (you cannot combine currencies on a single customer stripe). Removing the setup fee fix the error.
How can I solve? Anyone can give me some hint?
Many thanks

For anyone facing these problem: the solution is using the gform_stripe_customer_after_create hook:
https://docs.gravityforms.com/gform_stripe_customer_after_create/#1-create-invoice-item
Have a nice day :)

Related

Stripe Testing - Charge user right away even if subscription due date is next month

I have created a project that allows users to subscribe to our service monthly or yearly.
Now, I want to test our Stripe integration by attaching a working credit card, then changing that credit card into a "decline card" which I found here (4000000000000341).
Now, I wanted to test that flow. I can see that the user's upcoming invoice is still next month, but obviously, I cannot wait for next month since I want to test it right away.
I was Googling and I see that they mentioned that I should put a trial date, I tried that by modifying the user's subscription in the Stripe dashboard, but seems not to work. Maybe I'm missing something or did something wrong? The current flow of our subscription basis is we don't have a trial period, so I am not sure if putting a trial date is applicable to us.
Any help/tips is greatly appreciated! Thank you!
You should use test clocks.
You can simply advance the clock's time to one month later so that the upcoming invoice will be ready for you.
I believe the upcoming invoice won't be paid successfully as you are using a decline test card. You can read this doc to learn more about invoice payment handling.

nodejs Stripe, retrieveUpcoming and upgrading subscription

I am a bit stuck so I'm turning to you.
I have a system of subscriptions. The customer can only upgrade his subscription.
So the idea is that you have the different plans we offer, let's say you have account: silver (30$) gold (90$) and platinium(180$)
if the user has a free account, it's a regular subscription creation.
So the scenario is the following:
My customer goest from free to silver.
After a weeks he realize gold is fitting to his needs so he upgrades he has a preview of his next invoice and this works no problem so far with the following function:
await stripe.invoices.retrieveUpcoming({
customer: this.body('customer'),
subscription: this.body('sub'),
subscription_plan: this.body('newPlan'),
});
so the problem arise when the customer wants to upgrade again. Using the subscription_plan parameters bugs, and prevent the upgrade from being done.
How can i do that ? Do i need to create a new subscription ? What am i doing wrong
Using subscription_items seemed to do the job, the the invoice is giving me hell to fetch the data correctly with the prorata.
You can upgrade (or downgrade) a subscription by calling stripe.subscriptions.update.
Notably this will take care of any prorations for you, and you can specify your preferred proration behaviour when updating. You can learn more about how Stripe handles prorations here.

How can i get via AdSense Api the payment per Month and per Site

1) Hey i run API AdSense and im trying to get the total payment per month but filtered by site as well.
At the moment i can only extrect the amount of payment per month via https://www.googleapis.com/adsense/v1.4/accounts/accountId/payments but there is no way to filter there by Site
I can filter by site in this API https://www.googleapis.com/adsense/v1.4/accounts/accountId/reports but the payment that i get there are not accurate.
2) How can i get from the API the "InvalidTraffic" parameter per site ?
Thanks a lot in advance
1) Reporting is the correct way to get this information. Common causes of metric discrepancies are using the wrong time zone and using the wrong currency type. Also, be aware that "earnings up to yesterday are accurate, [but] more recent earnings are estimated due to the possibility of spam, or exchange rate fluctuations."
2) Invalid Traffic isn't exposed in the API.

How to redict user to Payoneer for the payment for goods?

Does Payoneer give possibility to redirect users to their site with giving settings in POST-inquiry?
Payoneer currently not providing ways for sending users to a payment page via POST inquiries.
Having said that, we are working on new and innovative services and solutions that will enable such activity in the coming year.
Thank you,
Yaniv Chechik - CTO

Magento Checkout error

I am using unirgy_giftcert gift certification plugin.
When I use gift code during checkout, I get following error message
Can't find implementation of payment method Unicert
Order seems to be completed, because, when I go to My Cart page, cart is blank.
Now When I try to complete the order in back end, I get the same error.
Ok, I've found answer of my question, after doing some R&D with my site.
Note : If you are using unirgy_giftcert and Subscription plugin, please note, you can not buy subscription products using Gift certificate codes
Actually, you can buy (but you must not), but, can not make full payment using gift certificate, because, it might create some problem in future devilries.
My site is a subscription based product selling company, that is why I was getting error.
I hope this will help someone.

Resources