• Resolved krko1234

    (@krko1234)


    Hi,

    I just upgraded from 1.7.15 to 1.8.

    My site heavily depends on PBC and uses the REST API. Now i see that im not getting the zone-based-price with my REST calls. In the end im running a woocommerce function for getting the price (get_price_from_id).

    I want to add that the rest api is used “internally” by the site itself. This has worked fine before.. im running woocommerce 3.9.2 and latest wp.

    Can i get this to work? The correct price has been fetched “automatalcly” with 1.7.15. This is not a requremient. I can figure out what zone the user is visiting from on my own…

    Can i use som internal function for getting the price based on that zone?

Viewing 1 replies (of 1 total)
  • Same here! Far as I understand, the problem is that following hook only fires in frontend but not the api:

    class-wc-product-price-based-country.php:236
    add_action( ‘woocommerce_init’, array( $this, ‘frontend_init’ ), 999 );

Viewing 1 replies (of 1 total)

The topic ‘Not working in rest api (anymore)’ is closed to new replies.