Stripe 1 with existing users into the database

Hello ,

I am trying to integrate stripe into one of the site. I follow some of the step in the doc from Wappler made for the step by step tutorial.
What did I do differently: The site already had users into the database with their email and verified.
I just wanted to add stripe in case users with different categories wanted to purchase a service.
So, it does not making sense to me to redo the site.
I followed the step 4a and 4b. However, I had an error 401. I was not sure why.
So, I manually created customer in Stripe and follow the example of @Hyperbytes to see if my api works. It was working.
So, I believe I realized the charge step 4a and 4b did not work because they were no customer in Stripe yet.

I would like your input: However, can I integrate Stripe if the users already exist in the database.
Note: The page where they will be charge is already protected by Wappler security reinforce.

I am wondering how to match the stripe.token in the charge customer api

Just query the stripe api to know if the user in your DB already exists in Stripe.
If not, then create it, else use the stripe’s customer id to make your charge.
https://stripe.com/docs/api/customers/list#list_customers

Using the conditional makes sense! Thanks for that input.
My other issue here is the charges url.
It is followed the step 4a and 4b. It is giving me an error.
However, when I use the get variable instead of post variable the key is works.
Any idea about the issue.