#durrell-issuing-connect

1 messages ยท Page 1 of 1 (latest)

fleet owlBOT
willow sand
#

Hi there

hot dune
#

I don't see anything in the Stripe CLI to trigger an event for that.

willow sand
hot dune
#

Yes, I'm building a platform with Connect though.

#

I spoke with Rubeus a while ago about this.

#

The CLI seems to be broken

willow sand
#

That's fine, you can create Cards/Card holders on the Connected Account to trigger this

#

Yeah I do think the CLI has a bug for this use-case if I recall

#

I can check on the state of that in a moment

hot dune
#

I already have created cards/cardholders on the connected account. How do I simulate making a charge on the card then so that a Stripe::Issuing::Transaction record exists for me to retrieve?

#

I looked into using fixtures, but I'm not sure what path I would use in the fixture.

willow sand
#

You use the card with a PaymentIntent to create a Charge

#

You basically just pretend to charge it yourself

hot dune
#

I did that before as well and I just did it again. I'm not seeing the issuing_transaction.created event so how would I know what issuing_transaction_id to use to look up the record? I'm listening for webhooks using the Stripe CLI. When this didn't work before Rubeus recommended setting up ngrok to listen for events but the event didn't come through with ngrok either.

inner hornet
#

durrell-issuing-connect

#

Where are you creating the PaymentIntent? Is it on your own platform account or the connected account instead?

hot dune
#

I'm creating it for the connected account. I passed in

#
{
    stripe_account: "acct_1LsqXMR8qpTsTbw8"
}
#

as the second argument.

inner hornet
#

did you create a Connect WebhookEndpoint and not an Account one?

#

the former gets Events from the connected accounts, the latter gets Events only from your own platform account

hot dune
#

Yeah I created a Connect Webhook endpoint. All the other events for connected accounts are going there just fine.

I could just stub out the object in a test since I know I'd get back a Issuing Transaction record, but then when I try making the call in rails console I get this error:

Stripe::InvalidRequestError: This property cannot be expanded (authorization, balance_transaction)

Can I really not expand the authorization and the balance_transaction in this request?

#

... or is it just messed up because the record doesn't exist to begin with?

inner hornet
#

Sorry I don't really understand the question. You said you don't get Events at all, now you say you do

#

The server is quite busy so I need really actionable/clear information. For example give me an exact Issuing Transaction or Authorization or Event id, anything I can use to understand what you are seeing

hot dune
#

I'm sorry for the miscommunication. When I said, "I'm not seeing the issuing_transaction.created event..." I didn't mean I'm not seeing any events at all. I just meant this event isn't coming through. Interestingly when I trigger the issuing_authorization.request in the CLI a series of events comes through but not the issuing_authorization.request event itself. That's when Rubeus recommended listening with ngrok, but ngrok wasn't any better. This was several weeks ago. It must still be broken.

So for example, when I created the PaymentIntent just now, I got these events:
evt_1MCobrR8qpTsTbw8Texm3snw
evt_3MCoboR8qpTsTbw80TfDlMGB
evt_3MCoboR8qpTsTbw80jn2LUNV
evt_3MCoboR8qpTsTbw80GaUaMQy

inner hornet
#

perfect, that's what I needed, let me have a look

#

okay so I see that you are getting issuing_authorization.created Events sent to the CLI too. Are you getting those?

hot dune
#

yes

inner hornet
#

damn sorry then I'm lost again

#

what's the issue again? ๐Ÿ˜…

#

oh I get it

#

you don't get Issuing Transactions

#

but that's because you do manual capture on that PaymentIntent

hot dune
#

no worries. I'm not seeing the issuing_authorization.request event nor the issuing_transaction.created event.

inner hornet
#

you are explicitly saying "hey hold funds, don't capture yet"

#

so there's no Transaction, that part is expected right?

#

like remove capture_method: 'manual' from your PaymentIntent creation and try again and you should see issuing_transaction.created

hot dune
#

ok. I'll try that. thank you

#

nice. I see the issuing_transaction.created event now.

inner hornet
#

okay so now you're back to missing issuing_authorization.request specifically with the CLI right?

hot dune
#

Do you know why I cant expand the ["authorization, balance_transaction"] ?

The Issuing Transaction object has the authorization and the balance_transaction ids in it. Normally I can expand the objects if the record has the ids of the objects I want to expand.

hot dune
#

oh ok. thank you.

What should I enter for the Connect authorization webhook endpoint?

inner hornet
#

That's where you would put the URL of your webhook endpoint to receive that specific event

#

And since the CLI doesn't support it (based on what you discussed with Rubeus I think) you'd put the ngrok URL

#

and then you should see those come in to your ngrok

hot dune
#

why have a place in your UI to enter the endpoint for this specific event? Does this event need to be a different endpoint from the endpoint our other connect events are going to? Or can we use the same endpoint?

inner hornet
#

This is a special Event. You have to respond extremely fast to the Event or it will decline authorizations by default. So we make it explicit that you have to opt into the Event

#

it's not an FYI. That Event is specifically "someone is trying to pay with card X are you approving or declining the attempt"?

hot dune
#

I entered the ngrok endpoint for the issuing_authorization.request event nothing is coming through.

inner hornet
#

I'm sorry but I'm going to need a lot more again ๐Ÿ˜…

#

what do you see in the UI? Does it work for you own Stripe account first?

hot dune
inner hornet
#

that's empty?

hot dune
#

i deleted it because I don't want anybody seeing my ngrok endpoint.

#

I basically have something like
https://something_here.ngrok.io/webhooks/stripe_connect_events

inner hornet
#

ack looking

#

what happens if you add it in the first part, the non Connect one?

#

Like we tried on our own account and as soon as we put a URL there we get a new webhook endpoint for it, but I don't see one on your account

#

@hot dune are you still around?

hot dune
#

ya

inner hornet
#

okay so now I see you added it on the account version and that one created a WebhookEndpoint as expected

#

Did it work? I still see the old URL right now

#

okay it swapped, looking

hot dune
inner hornet
#

yeah and still no WebhookEndpoint

#

What happens if you try to create a Connect webhook endpoint and add this specific event?

hot dune
#

Like this?

inner hornet
#

yes but I don't see it anywhere on your account so I'm confused

#

what's the WebhookEndpoint we_123 id?

hot dune
#

I'm in test mode: we_1MCq3CJRbJh8dLdCcKtreTqv

inner hornet
#

ah but that's not a Connect WebhookEndpoint

#

like that we_123 you shared was created 20 minutes ago after you added the URL to the other settings page

#

are you seeing where to do this? Sorry to push but I keep reloading our tools waiting for the endpoint but I see nothing

#

ah now it's there

#

okay so now if you try again to cause one of those Events it should (hopefully) work

hot dune
#

that worked!!!!!

#

awesome!

inner hornet
#

damn

#

we have a weird bug in that Dashboard UI that seems to forget to create the endpoint

hot dune
#

thanks so much for helping me with this.

#

We really appreciate it.

inner hornet
#

of course, I'm so sorry this was so painful

#

like it really should just work ugh

#

we'll push internally to get this prioritized!

hot dune
#

ok. Thank you!