#kira-payments-list

1 messages ยท Page 1 of 1 (latest)

oblique pastureBOT
trail iris
#

Hi ๐Ÿ‘‹

What do you mean by payment ID? Payment Intent ID, Invoice ID, Charge ID?

urban grove
#

Hello!

#

I would like to retrieve a certain paymentIntent ID, that was made from a certain user (email) & at a certain date (created_at)

trail iris
#

The created parameter allows you to specify a time window and the customer parameter will let you limit the List to PIs associated with that customer

urban grove
#

Sounds great!

urban grove
#

Ok. I did this

trail iris
#

Great ๐ŸŽ‰ I'm glad it worked

urban grove
#

what's the parameter to get email?

#
$stripe->paymentIntents->all(['customer.email'=> $email])
#

for example

trail iris
#

There isn't one

urban grove
trail iris
#

I don't know what you mean by "the email of a payment". There isn't an email property

#

Do you mean receipt_email or the email from the Customer object?

urban grove
#

my purpose is to redirect to a stripe payment page.

#
return $this->redirect('https://dashboard.stripe.com/test/payments/'.$paymentId);
#

For this, I need to identify the stripe payment, with my order data I got in my database. (order->getUser()->getEmail) and (order->getCreatedAt() )

trail iris
#

Okay so it's the email assocaited with the user?

urban grove
#

Yes, in my database, I can retrieve an order, and the user email from it

trail iris
#

You could also start storing the Payment Intent ID in your database

#

I know that's more work but, in the longer term, it might be useful

urban grove
#

I know. I could even create a customerId that would be on stripe to retrieve everything

trail iris
#

And then use that Customer ID along with the createdAt timestamp to find the payment intent

urban grove
#

I don't get it

#

I see that once we made a payment, a client is created and there is email stocked in Stripe

#

And so there's no way to retrieve it?

trail iris
#

The email is on the Customer object

#

Not the Payment

urban grove
#

Oh yes. Okay I get it. So i can go from Customer then his payments filtered by the date

trail iris
#

Correct

urban grove
#

What would be the customer attribute to get his payments?

#

Invoices?

oblique pastureBOT
trail iris
#

What do you mean? You woudl only use Invoices if you were generating Invoices for the customer. If you want to list the Payments for a Customer you first get the Customer ID and then use it in the List API I mentioned earlier