jasonknight/woocommerce-json-api

Issue With Get Products

Closed this issue · 1 comments

When using get_product all variations of the product is being returned as a product.
Would be grateful if this can be looked into.
A sample response of the product variation that is returned is shown below.

         [18] => Array
                (
                    [id] => 110
                    [name] => Variation #110 of TWLC Reach 4 Me
                    [slug] => product-46-variation
                    [type] => product_variation
                    [description] => 
                    [short_description] => 
                    [parent_id] => 46
                    [publishing] => publish
                    [sku] => RED123
                    [downloadable] => no
                    [visibility] => visible
                    [virtual] => no
                    [manage_stock] => no
                    [sold_individually] => no
                    [featured] => no
                    [allow_backorders] => no
                    [quantity] => 15
                    [height] => 
                    [weight] => 
                    [length] => 
                    [price] => 6250
                    [regular_price] => 6500
                    [sale_price] => 6250
                    [sale_from] => 
                    [sale_to] => 
                    [status] => instock
                    [attributes] => Array
                        (
                        )

                    [tax_class] => 
                    [tax_status] => none
                    [product_type] => product
                    [categories] => Array
                        (
                        )

                    [tags] => Array
                        (
                        )

                    [reviews] => Array
                        (
                        )

                    [variations] => Array
                        (
                        )

                    [images] => Array
                        (
                        )

                    [featured_image] => Array
                        (
                        )

                )

All variations are products. They are not any different, simply having the type product_variation.... I will look deeper into their ultimate representation in the WooCom system though...