Mike Jolley
eae1d75c86
Store API: Consistent error code and hook naming ( https://github.com/woocommerce/woocommerce-blocks/pull/5992 )
...
* Update error codes with `woocommerce_rest_` prefixes.
* Update action and filter hooks with woocommerce_store_api_ prefix
* Update hook docs
* Update error code mismatches
* Update hook name in tests
* update hook name in tests
* phpcs
2022-03-07 13:51:07 +00:00
Mike Jolley
fd03b79995
StoreAPI: Rename namespace to remove `\Blocks` ( https://github.com/woocommerce/woocommerce-blocks/pull/5982 )
...
* Composer config
* Update namespace in deprecated.php
* Bulk update namespace
* Revert rename in deprecated class
* bw compat
* Store API: Add dedicated container and make Store API code self-contained (https://github.com/woocommerce/woocommerce-blocks/pull/5986 )
* Move ArrayUtils to StoreApi
* Move PaymentContext/PaymentResult
* Move create account functionality to checkout endpoint. Update tests.
* Move get_routes_from_namespace to blocks
* Move RestApi logic within StoreApi namespace/directory
* StoreAPI Container
* Update functions
* Update extend docs
* Run Doc build script
* Missing container calls for 3rd party extensions
* Fix doc toc
2022-03-04 13:28:37 +00:00
Mike Jolley
49b65c7bcf
Refactor ExtendRestApi as ExtendSchema and expose `register_endpoint_data` as a public function ( https://github.com/woocommerce/woocommerce-blocks/pull/5941 )
...
* Create Extend class under schema namespace
* ExtendRestApi -> ExtendSchema
* ExtendSchema helper functions
* Move tests
* Fix tests
* Fix docs
* Typos
* Remove invalid param
* phpcs formatting
* Update docs/contributors/documentation-guidelines.md
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
* Update docs/extensibility/filtering-payment-methods.md
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
* Update docs/extensibility/README.md
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
* Update docs/extensibility/available-slot-fills.md
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
* Asserttrue comment
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
2022-03-01 10:34:05 +00:00
Mike Jolley
a58b2d0ac4
Store API: Introduce API Versioning System ( https://github.com/woocommerce/woocommerce-blocks/pull/5911 )
...
* Fix missing dependency
* Min version exceeds required 5.6
* Move exceptions
* Move schemas under V1 namespace
* Move routes to v1
* Move RouteException
* Route versioning
* Update route and schema identifiers/init
* Rework route init to support multiple versions and multiple schema
* Tests for cart routes
* Cart coupons tests
* Batch
* extensions
* Update docs
* Update remaining tests
* woocommerce_store_api_route_version was unused
* Revert unrelated change
* Fix phpcs
* Update src/StoreApi/docs/guiding-principles.md
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
* Update src/StoreApi/docs/cart-items.md
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
* Update src/StoreApi/RoutesController.php
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
* Note about v1 unversioned endpoints
* Remove unused get_route_version
* 409 comment in tests
* Remove copy pasted comments
* Update all usage to v1
* Correct namespace
* More v1 namespaces
* More missing v1
* fix mocks
Co-authored-by: Thomas Roberts <5656702+opr@users.noreply.github.com>
2022-02-23 12:00:45 +00:00
Mike Jolley
7f2af8c1a6
Validate available payment methods before attempting payment or updating order statuses ( https://github.com/woocommerce/woocommerce-blocks/pull/5440 )
...
* Make payment method required
* removed unused imports
* Remove PUT method
* Validate available method when updating order
* Enable bacs for tests
2022-01-04 18:04:08 +00:00
Seghir Nadir
ea1e17fc81
Fix sanitization callback ( https://github.com/woocommerce/woocommerce-blocks/pull/5060 )
...
* Fix sanitization callback
* Add test case to confirm sanitization callbacks work for nested properties
Co-authored-by: Mike Jolley <mike.jolley@me.com>
2021-11-05 15:39:08 +00:00