I followed instructions in docs, but billing can’t be updated, only email.
This works:
async function fillBill() {
try {
await Snipcart.api.cart.update({
email: 'tester.doe@example.com'
});
} catch (error) {
console.log(error);
}
};
But this does not work:
async function fillBill() {
try {
await Snipcart.api.cart.update({
email: 'tester.doe@example.com',
billingAddress:{
name: 'Tester',
address1: '55 Test Street',
city: 'Melbs',
country: 'Australia',
province: 'Victoria',
postalCode: '3000'
}
});
} catch (error) {
console.log(error);
}
};
Can you please tell me what is wrong with the second function? No data makes it to the billing fields, including email when I use the second function. No errors in browser console.
Any ideas? Alternate methods?
Thanks.