Get current customers billing and shipping address (using PHP)

Hello,

I’m developing a SnipCart add-on module for ProcessWire CMS (in PHP). Currently I’m working on a custom taxes provider which automatically determines the country specific VAT. For this purpose I’d need to get the currently logged in customers billing and shipping address.

Could someone please point me in the right direction on how to achieve this?

Edit:
To clarify: I know about webhooks. But I want to display products with the correct taxes in the product catalog for logged in customers.

Thanks,
Martin

Hi there,

You should get all the information you need in :

Snipcart.store.getState().customer

Please try this and tell us if this worked for you.

Cheers !