#rarcif-connect-balancetransaction

1 messages · Page 1 of 1 (latest)

lunar glenBOT
surreal plinth
#

that does stripe.transactionBalance mean? That's not really an API I have ever heard of. Do you mean stripe.balanceTransaction maybe?

#

@carmine chasm do you have more details?

carmine chasm
#

Oh yeah sorry i mispelled I meant the balanceTransaction API

surreal plinth
#

Okay which programming language are you using? Can you share real code as what you wrote was by hand and not related to our library so I can't guess the language

#

@carmine chasm are you still around?

carmine chasm
#

yep

#

nodejs

surreal plinth
#

Okay, can you please share real code?

carmine chasm
#

const stripeAccountBalance = await stripe.balance
.retrieve({}, { stripeAccount: stripeAccountId })

This works, I am trying to replicate the same with stripe.balanceTransaction.

Is it possible to retrieve the object by passing the { stripeAccount: stripeAccountId } object as with stripe.balance?

surreal plinth
#

Okay so what's not working? I'm sorry, you're still a bit cryptic. All I need is your real code and the problem

#

@carmine chasm

#

rarcif-connect-balancetransaction

carmine chasm
#

I am just wondering if in the function "await stripe.balanceTransaction
.retrieve({}, { stripeAccount: stripeAccountId }) ", if the second object { stripeAccount: stripeAccountId } can be passed. I saw it working with the stripe.balance api but did not get it to work with the stripe.balanceTransaction, so I was wondering if it is possible at all by using this syntax?

surreal plinth
#

The Retrieve BalanceTransaction API is used to retrieve a specific BalanceTransaction and expects a BalanceTransaction id txn_123

#

that's why I kept asking for code because what you wrote doesn't make sense yet, it's like you replace balance with balanceTransaction without understanding the context

#
  'txn_123',
  {
    // parameters if any
  },
  {
    // options like connected account id
    stripeAccount: 'acct_123',
  }
);``` that's what a retrieve should look like
#

@carmine chasm ^ does that make sense?

carmine chasm
#

So it is possible to pass the second object then. Thats what I was trying to figure out.

#

To put things into context.

We have access to the balances of a stripeAccount by using the balance api. We were trying to get a breakdown for each user of all transactions that are available.

surreal plinth
#

sorry it's hard to help you as you disappear after each sentence for 20 minutes

carmine chasm
#

Yes, I am using the list already with autopagination and with starting after query param. I was trying to play around with both options. In both scenarios the second object was not taken. That is why I wanted to clarify, if it is possible to pass the second objet in the first place. I understanding then, that passing the stripeAccountId object is possible for the lbalanceTransaction.list api, as in stripe.balanceTransaction.list({}, { stripeAccountId: "the_id_of_the_accoun"})

surreal plinth
#

I'm sorry I have no idea what this means

#
    {
      limit: 1,
    },
    {
      stripeAccount: 'acct_123',
    }
  );``` works totally fine and lists the BalanceTransactions on the connected account with `limit` set to 1