#nick-payout

1 messages ยท Page 1 of 1 (latest)

quiet oracle
#

Hi there! Let me take a look.

primal fjord
#

sure

#

I suppose I'll have to roll back the logic

#

To trigger the report on paid instead of created

quiet oracle
#

Sorry for the hold up, I could not verify the content of what is in the file.

primal fjord
#

It's empty

#

So not much to verify

quiet oracle
#

How are you retrieving the file?

primal fjord
#

it just has the headers I requested

#

using basic auth

quiet oracle
#

I see, but there were no data to populate the rows in the report

primal fjord
#

I don't understand what that means

#

It should have the content of the payout?

quiet oracle
#

Thank you for your confirmation

primal fjord
#

I would expect it to contain the data I can see on the dashboard for the payout

#

This works fine normally when I do it in response to the payout being paid

#

this is in response to the payout being created

#

so maybe I'm requesting the data too early

#

And I manually requested this data for payouts that were "in transit" which did work

#

but those had been in transit for a while

quiet oracle
#

Payout reconciliation reports could take up to 12 hours

primal fjord
#

That's not what I'm asking

#

This is not a question of processing time

#

The result is empty

#

So you probably have a bug somewhere that causes the report run to succeed too early with no data

#

okay so maybe I misunderstood what this site means

#

I read this as it could take up to 12 hours for the report run to succeed

#

The data is clearly there as evident from the dashboard

quiet oracle
#

Please allow me to rephrase, payout reconciliation report data is not available immediately via the Report Runs API request, it could take up to 12 hours.

#

But the dashboard displays this data near real time

primal fjord
#

That's a really poor design

#

Honestly

#

You should not allow the request to finish if the data is not yet avaialble

#

it's misleading and potentially simply incorrect

#

I've reverted the logic to be triggered by payout.paid instead like before, whcih worked

quiet oracle
#

If you try and make a request with the retrieve Payout API, this will also provide data near real time

primal fjord
#

I can't get payout contents with the payout API

#

That's the reason I use the report API

quiet oracle
#

This is a good point! Thank you very much for raising this, I will bring this idea to the team!

#

I agree with you, if the report's data is not yet available, a 2XX status might not make sense

primal fjord
#

if it's "within 12 hours" - when can I know when it is if the report just succeeds?

#

That's not really useful

#

Could I potentailly receive impartial data if I ran it after say 6 hours?

quiet oracle
#

The data for each day is defined as account activity that takes place between 12:00am UTC and 11:59pm UTC.

primal fjord
#

like only half the transactions of the payout perhaps?

#

I understand, but a payout cannot contain activity that happens after the payout is created

#

because the amount does not change

#

so you must know what is in a payout when reconciling on payout ID

quiet oracle
#

For example, all account activity on 16 March 2022 (from 12:00am to 11:59pm UTC) is available in the Payout reconciliation reports tab by 17 March 2022 at 12:00pm UTC.

primal fjord
#

Yeah but i don't reconcile by timestamp

#

It's by payout ID

#

when the payout is created

#

See req_dq7nNOiDjVKsBn

#

so if that request succeeds and generates a report file, that file should not be empty, regardless of when you do it

#

because the payout does not change after creation?

quiet oracle
#

If the payout was created, e.g. on 16th March at 11pm UTC, but the report runs API is called on 17th March at 11am, right now the report will be empty.

primal fjord
#

Yeah I'm saying that's not good design

#

Not that you're wrong

quiet oracle
#

I agree if the data is not available for display, it should not be a 2XX response

#

Thank you very much for bringing this good point!

primal fjord
#

You can just let it be processing until all the data is avaialble

#

but just to clarify

#

Does this mean that we potentially could get like half the content of a payout?

#

or is it binary? like all content of a payout or nothing

quiet oracle
#

It is all or nothing

primal fjord
#

Alright

#

that's good at least

quiet oracle
#

๐Ÿ™‡

primal fjord
#

I've reverted my code to react to payout.paid instead of payout.created

#

then all of the data is available and it works

quiet oracle
#

Yes, payout.paid occurs when a payout is expected to be available in the destination account, usually it takes at least a day or more to transfer money from Stripe to your bank account.

primal fjord
#

I know

quiet oracle
#

By that time, the report should be ready ๐Ÿ™‚

primal fjord
#

but that solves the problem because that's always 12 hours later (I hope)

quiet oracle
#

๐Ÿ‘

primal fjord
#

Thank you for your help

quiet oracle
#

Thank you! It was nice talking to you, and thank you for your feedback, I will definitely raise with the team ๐Ÿ™‡

primal fjord
#

You're welcome