#duracel

1 messages · Page 1 of 1 (latest)

vestal lightBOT
stable python
#

If I remove "automatic_tax": { "enabled": "true" } then both Google Pay/Pay with link are loaded. I'd like to have those options while still enabling automatic tax

onyx skiff
#

Hi sorry for the delay. Discord is busy

#

Looking

#

Interesting. And after the customer enters their billing address, Google Pay still isn't showing up?

onyx skiff
#

Also can you send the sessinon id for the one where google pay does show?

stable python
#

It doesn't show up even after entering the billing address. Here's the session id for the other session: cs_test_b1W8UubiTVGemDuJiN4o8X5nrQcdtc2UYWT9wISgm7hcdMT7PD94GLDbLI

main stream
#

Hello! If you don't specify a customer does it work as expected?

stable python
#

I just tried replacing the customer with customer_email and it still doesn't show the alternative payment methods: cs_test_b1ZPnEyWXtu68KLElN8W5pKmggMmeXIadrWGzioRvH9dtkAdsBTVldss9H

I also just tried removing the customer_email as well, and still doesn't work as expected:
cs_test_b19rmDfREBpq1YzyE7lV6lvCLDx0FjBaxwI4xr6SDTxg9SgoDp74kUHB8v

main stream
#

Does it work if you ask for a shipping address?

stable python
#

Not exactly sure how to do that. I tried passing the shipping_address_collection paratemeter like this:

"shipping_address_collection": {
"allowed_countries": "GB"
}

But I'm getting this error:

Raw response for the API
Status code 400
{
"error": {
"message": "Invalid array",
"param": "shipping_address_collection[allowed_countries]",
"request_log_url": "https://dashboard.stripe.com/test/logs/req_MNQUn6VMjp2C6v?t=1690580578",
"type": "invalid_request_error"
}
}

main stream
#

shipping_address_collection.allowed_countries takes an array of countries, not a single string representing one country.

#

It would need to be this:

"shipping_address_collection": {
  "allowed_countries": ["GB"],
}
stable python
#

I couldn't get it to work. I think it's because of Bubble's limitations (I'm using bubble.io to build my app) as it won't let me add arrays.

#

I tried adding the parameters in the request body instead, like this:

#

Is there another way to ask for shipping address that doesn't require passing arrays in the parameter?

main stream
#

I don't think so. Where are you setting success_url?

stable python
main stream
main stream
#

Huh. I don't see any parameters in that request, the body is blank.

#

Can you check to see if a configuration was changed somewhere that would result in a blank body?

stable python
#

It's because the API call isn't being initialized at all, this is the full error message I'm gettin in Bubble when I try to initialize it:

There was an issue setting up your call.

Raw response for the API
Status code 400
{
"error": {
"code": "parameter_missing",
"doc_url": "https://stripe.com/docs/error-codes/parameter-missing",
"message": "Missing required param: success_url.",
"param": "success_url",
"request_log_url": "https://dashboard.stripe.com/test/logs/req_cjnVCwy8oM6lC6?t=1690582760",
"type": "invalid_request_error"
}
}

#

I don't see anything wrong with the API call configuration here

main stream
#

Oh, your body type is JSON. The Stripe API does not accept JSON request bodies.

#

We only output JSON in responses.

#

The Stripe API is organized around REST. Our API has predictable resource-oriented URLs, accepts form-encoded request bodies, returns JSON-encoded responses, and uses standard HTTP response codes, authentication, and verbs.

stable python
#

Oh my bad, I'm new to working with APIs so I wasn't aware of this.You reckon any of these could work? (image)

main stream
#

You need the form-data option there.