#arghya-das_api
1 messages Β· Page 1 of 1 (latest)
π Welcome to your new thread!
β²οΈ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
β±οΈ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
π This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1237981288455999508
π Have more to share? Add more details, code, screenshots, videos, etc. below.
Hi! Can you share the request ID (req_xxx)? Here's how you can find it: https://support.stripe.com/questions/finding-the-id-for-an-api-request
Find help and support for Stripe. Our support site provides answers on all types of situations, including account information, charges and refunds, and subscriptions information. Get your questions answered and find international support for Stripe.
oh shoot I am not open in the stripe dashboard right now
can you not help in this way πΆ?
parameter_missing - customer
this is for the billing portal api
if it is automatically cancelled due to declined card and now if I wanna go to billing portal it say customer parameter missing but if I cancel the sub from dashboard it is working
weird
π Taking over this thread, catching up now
Can you share the request ID (req_xxx) of the error you faced? Hereβs how you can find it: https://support.stripe.com/questions/finding-the-id-for-an-api-request
We'd need an request ID (req_xxx) to understand the information in the request that your system sent, so that we can provide the solution accordingly
Find help and support for Stripe. Our support site provides answers on all types of situations, including account information, charges and refunds, and subscriptions information. Get your questions answered and find international support for Stripe.
yes so I am not in front of the dashboard rn
πΆ
can't login at the moment
but I will need the help π is it not possible?
Based on the limited information you provided, the issue is likely due to customer not being set in the Customer Portal Session API: https://docs.stripe.com/api/customer_portal/sessions/create#create_portal_session-customer
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
customer is a required field to create a Customer Portal Session
I'd recommend checking if customer field has been set in the request
no the issue is not that
the issue is this
So I am in test mode and I have 4 retired setups in 1 week, I am running the clock simulator to try it with a declined card to fail the payment and cancel the subscription automatically but if I do that and then run the billing portal API it says customer parameter missing but if I simply cancel it from the dashboard it is ok. and I see in the dashboard that customer is not deleted also there is no webhook events called customer deleted
but if I do that and then run the billing portal API it says customer parameter missing
Isn't this the one with the problem?
yes but when I have a running sub it is working
even if I cancel the sub from the dashboard it is working
but as soon as I use the test clock simmulation to fail the payment and cancel the subscription it is not working.
but as soon as I use the test clock simmulation to fail the payment and cancel the subscription it is not working.
What is not working? Can you share the error message and the detailed steps that you were doing?
oh I think I have saved it somewhere wait sir
message: 'Missing required param: customer.',
Can you share the code that threw this error message?
so basically I am setting a sub for a price okay then I am using a test clock to simulate what will happen if I have use a declined test card which in next phase cancel the subscription but then after sub is cancel is deleted if I try to go to my blling portal this error is showing
parameter_missing
this one
Based on the limited information you provided, the issue is likely due to customer not being set in the Customer Portal Session API: https://docs.stripe.com/api/customer_portal/sessions/create#create_portal_session-customer
customer is a required field to create a Customer Portal Session
I'd recommend checking if customer field has been set in the request
This statement still holds. Your code / request didn't setcustomerin the billing portal API
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
aah so another thing I tried as soon as I go more then 30 days in my test clock it is not working, any reason?
https://support.stripe.com/questions/test-mode-subscription-data-retention:
Test clocks and their customers are automatically deleted 30 days after creation, while any associated subscription is canceled when the test clock is deleted
not live I am in test mode
actually okay as soon as I use the test clock I can't open my billing portal because the customer parameter is missing
Do you mean you try to advance the time to more than 30 days and it doesn't work as expected?
I tried as you gave that info
The issue is not with the test clock. The issue here is with the request that you created the billing portal
I tried less then 30 more like 20 days and stripe.customers.list and this is coming []
although no customer is deleted
Can you share the code that threw the error? Without the code or request ID (req_xxx), we don't know how your exact integration works
We are unable to help further if code or request ID (req_xxx) isn't provided
oh okay give me some time
if I can I will get back with that
actually I don't have the dashboard access the project I am working on
so I need to get that
but I can show you my code
Sure! Sharing the code will be helpful too
haha message is too long let me break it
Where is the code to create billing portal session?
stripe.billingPortal.sessions.create(..)
yes coming
yes yes just sending all of it so you can understand it better
Looks like the issue is due to customer retrieval doesn't return anything
if I cancel the sub from the billing portal it still works, if I cancel from dashboard it is still working but as soon as I use the test clock the stripe.customers.list returns []
yes sir yes sir thank you
This will go back to the initial ask. We'd need the request ID (req_xxx) of your List Customers API to understand why no customer is returned in the response on your account
Without request ID (req_xxx) or account ID (acct_xxx), we don't know what customers have been created in your account
can you give me sometime to get back?
this doesn't give any logs
Sure! Feel free to come back when you have an object ID
what object id do you need? mainly
Request ID (req_xxx) of the error or List Customers API will be helpful
Or do you have the subscription ID (sub_xxx)?
sub gets deleted when the test clock goes to cancel it
give me 2 mins to get back to the dashboard and get back to you
@fiery dirge
this one?
Checking it now
Provides a list of customers that are associated with the specified test clock. The response will not include customers with test clocks if this parameter is not set.
got somethiong
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
what to put in there?
yep it worked
I needed to add the test_clock id to return the list of customer associated with test_clock
Ah yes! If test clock is used, List Customers API should also include the test_clock
another thing is that if I made the subscription cancel and then deleted if I go to billing portal there is sill a button for pay invoice why is that
In general, we recommend to save the customer ID (cus_xxx) of that specific email address in your own database, and retrieve from your database when necessary instead of calling List Customers API
I was stressing about it for the last 1 month I have missed that part
another thing is that if I made the subscription cancel and then deleted if I go to billing portal there is sill a button for pay invoice why is that
When the subscription is deleted, the previous unpaid invoice will still be present to be paid
so sorry for that one sir
but then what will happen if they pay?
the sub is already deleted right?
The invoice will be marked as paid, but the subscription will remain as deleted
but then will they be getting more invoice?
for the next month or whatever timeframe?
No! The invoice showed in the billing portal was created before the subscription was canceled
After the subscription is canceled, no invoice will be created
nice and I can't renew after subscription is cancel right?
Yup! canceled is the terminal status of a subscription. It can't be renewed
is there a renew button in the billing portal?
I can't find the props I am sure I saw one
Renew is only possible if the subscription is scheduled to cancel in the future, but hasn't been canceled yet
If the subscription has been fully canceled, it's not possible to renew
oh scheduled to cancel means if I set that in the dashboard
but after what date I can find the button renew? but I saw some other billing portal has renew button
let's say I have sub but my two payments declined and it is gonna retry again then cancel it I will not see the renew button right
let's say I have sub but my two payments declined and it is gonna retry again then cancel it I will not see the renew button right
Yes! When a subscription is already canceled, renew button will not be shown
No problem! Happy to help π