XiaoFaye / WooCommerce.NET

A .NET Wrapper for WooCommerce/WordPress REST API
MIT License
391 stars 217 forks source link

Phone property is missing in OrderShipping (V2?) and CustomerShipping (V3) #776

Open jose-dvm opened 1 month ago

jose-dvm commented 1 month ago

Just in case someone else wants to use this helpful library but needs to access these properties.

Wordpress version: 6.5.5 WooCommerce version: 8.8.5 WooCommerce.NET version: v0.8.6 (NuGet package)

  1. Do a GET request for customers or orders -> phone is available in CustomerShipping and OrderShipping
  2. Try to get phone value from CustomerShipping or OrderShipping using WooCommerce.NET -> phone is not available

The Pull Request #705 fixes the Order part and can be used as a reference to fix the Customer part.

Proofs and references about phone availability (it's missing in REST API docs):

imagen

imagen

https://github.com/woocommerce/woocommerce/blob/trunk/plugins/woocommerce/includes/rest-api/Controllers/Version2/class-wc-rest-orders-v2-controller.php

https://github.com/woocommerce/woocommerce/blob/trunk/plugins/woocommerce/includes/rest-api/Controllers/Version3/class-wc-rest-customers-controller.php

https://github.com/woocommerce/woocommerce/commit/01f71d756461ac37876099ceea43870034a95b00