#matt-jones-siteglide-sitegurus_api
1 messages ยท Page 1 of 1 (latest)
๐ Welcome to your new thread!
โฒ๏ธ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
๐ This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1481321585192210496
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.
- matt-jones-siteglide-sitegurus_api, 18 minutes ago, 19 messages
hi! just want to acknowlede your question, working on something else but will be back to this asap
ok sorry about that, looking into this now
off the top of my head i don't think this is possible but lemme double check
ok, turns out you can prefill phone numbers. you just need to match a very specific formatting, including the + and country code. and then if you pass:
enabled: true,
},```
into the checkout creation request, the phone number will show up in that field
so for US numbers if you pass phone: "+1XXXXXXXXXX" it should show up
when you refer to address, are you referring to shipping address or billing address? it doesn't look like you're collecting a shipping address in your checkout session so i'm assuming you mean billing?
if you're referring to the billing address i think the reason would be because that's essentially a part of the payment information - so it would only be saved if you are saving the payment method itself. and then when a customer re-enters a future checkout session, the address won't be "pre-filled", but they can re-select the saved card
Billing address. Actually all products will be picked up with "click and collect" from a physical location.
Will try this, thanks
also i double checked this reasoning with a colleague and it checks out ๐
Thanks for your help.
Yes the phone number is working with that format. I guess I thought it wouldn't be an incorrect format because there was no validation error previously.
yeaaaaah our phone number validation is a little tricky, checkout expects it to be formatted a very particular way (which is the same way it outputs it), but the APIs are a little more loose and have been for a while
and since adding stricter validation for everyone would be a breaking change it's a little tricky to get it fixed
@gloomy spire one quick followup, you actually can prefill the country. so for example if in your customer you pass
country: "CA",
},```
their checkout session will default to Canada in the country dropdown
but none of the rest of the address is prefillable
Yes, this is already working actually, though I thought it was because I was passing in locale.