#elmo - payouts

1 messages · Page 1 of 1 (latest)

open lance
#

One moment

elder ocean
#

ok

open lance
elder ocean
#

Thank you, is there a way to just pull just the payout balance_transactions ? or do I need to filter these in code?

open lance
#

Ah you just want to do it from the dashboard?

elder ocean
#

No, I'd like to use the API (using the ruby library)

open lance
#

What do you mean by pull the payout balance_transactions then?

#

I think the api endpoint I linked will do what you're trying to do, no?

elder ocean
#

I can pull the payout record, but there's not linkage to the particular charge

#

for intance:

#

"id": "po_1KOBE5KkI6JstnPk2FHdS5Ia",
"object": "payout",
"amount": 4794,
"arrival_date": 1643673600,
"automatic": true,
"balance_transaction": "txn_1KOBE5KkI6JstnPkefeQiVAr",
"created": 1643679129,
"currency": "usd",
"description": "STRIPE PAYOUT",
"destination": "ba_184ob4KkI6JstnPkvWzR42ON",
"failure_balance_transaction": null,
"failure_code": null,
"failure_message": null,
"livemode": false,
"metadata": {},
"method": "standard",
"original_payout": null,
"reversed_by": null,
"source_type": "card",
"statement_descriptor": null,
"status": "paid",
"type": "bank_account"

#

I need to find the initial charge associated with this payout.

craggy spruce
#

@elder ocean have you looked at the doc my colleague sent you?

#

They explained what to do. One Payout can have 1 charge, or 10, or 10 millions. So you can't just get them on the Payout

#

You have to call the List Balance Transactions API and say "please give me all balance transactions bundled in that specific Payout for me to reconcile" and that's done using https://stripe.com/docs/api/balance_transactions/list and passing the parameter payout: 'po_123'

elder ocean
#

I see, so it's a one to many, ok, I got it thanks.

craggy spruce
#

sure!

elder ocean
#

thanks again

craggy spruce
#

Of course!