Skip to content

Commit 18fe035

Browse files
committed
Added endpoints of the Product Categories API
1 parent 09db974 commit 18fe035

19 files changed

+1623
-175
lines changed

README.md

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,12 @@ This API client provides a type-safe Java interface for WooCommerce REST API v3,
3838
- Get a specific product variation
3939
- Update a product variation
4040
- Delete a product variation
41+
- ✅ Product Categories API
42+
- List all product categories
43+
- Create a new product category
44+
- Get a specific product category
45+
- Update a product category
46+
- Delete a product category
4147
- ✅ Orders API
4248
- List all orders
4349
- Create a new order
@@ -57,7 +63,7 @@ This API client provides a type-safe Java interface for WooCommerce REST API v3,
5763
5864
## 📦 Version Information
5965

60-
- **Current Version**: `0.9.3`
66+
- **Current Version**: `0.9.4`
6167
- **Supported WooCommerce API Version**: `v3`
6268
- **Java Compatibility**: Java 8+
6369

@@ -87,7 +93,7 @@ Then add the locally built artifact to your project:
8793
<dependency>
8894
<groupId>pl.wtx.woocommerce</groupId>
8995
<artifactId>woocommerce-api-client</artifactId>
90-
<version>0.9.3</version>
96+
<version>0.9.4</version>
9197
</dependency>
9298
```
9399

@@ -152,7 +158,7 @@ public class WooCommerceApiClientUsageDemo {
152158

153159
## 📊 Project Statistics
154160

155-
-3 GitHub stars
161+
-5 GitHub stars
156162
- 🔄 Regular updates and improvements
157163
- 👥 Open for community contributions
158164

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
<groupId>pl.wtx.woocommerce</groupId>
88
<artifactId>woocommerce-api-client</artifactId>
9-
<version>0.9.3</version>
9+
<version>0.9.4</version>
1010
<packaging>jar</packaging>
1111

1212
<name>WooCommerce REST API Client</name>

src/main/java/pl/wtx/woocommerce/WooCommerceApiClient.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ public WooCommerceApiClient() {
2323
public WooCommerceApiClient(boolean enableLoggingApiMessages) {
2424
JSON.setGson(GsonConfig.createGson());
2525
setUserAgent("WooCommerceApiClient (by wtx-labs)");
26-
2726
if (enableLoggingApiMessages) {
2827
setHttpClient(OkHttpClientConfig.configureClient(getHttpClient()));
2928
}

src/main/java/pl/wtx/woocommerce/WooCommerceApiClientUsageDemo.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ public class WooCommerceApiClientUsageDemo {
2020
private static final String API_PASSWORD = "TODO_SET_API_PASSWORD";
2121

2222
public static void main(String[] args) {
23+
2324
System.out.println(">>> Start running the WooCommerceApiClientUsageDemo...");
2425

2526
// Use WooCommerceApiClient(true) if you need to log API communication messages.
@@ -42,5 +43,7 @@ public static void main(String[] args) {
4243
}
4344

4445
System.out.println("<<< The WooCommerceApiClientUsageDemo has been finished.");
46+
4547
}
48+
4649
}

src/main/java/pl/wtx/woocommerce/api/client/OrdersApi.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ public void setCustomBaseUrl(String customBaseUrl) {
8484
<table border="1">
8585
<caption>Response Details</caption>
8686
<tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
87-
<tr><td> 200 </td><td> Returns specified order. </td><td> - </td></tr>
87+
<tr><td> 201 </td><td> Returns created order. </td><td> - </td></tr>
8888
<tr><td> 401 </td><td> Unauthorized </td><td> - </td></tr>
8989
<tr><td> 404 </td><td> Not Found </td><td> - </td></tr>
9090
</table>
@@ -155,7 +155,7 @@ private okhttp3.Call createOrderValidateBeforeCall(Order order, final ApiCallbac
155155
<table border="1">
156156
<caption>Response Details</caption>
157157
<tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
158-
<tr><td> 200 </td><td> Returns specified order. </td><td> - </td></tr>
158+
<tr><td> 201 </td><td> Returns created order. </td><td> - </td></tr>
159159
<tr><td> 401 </td><td> Unauthorized </td><td> - </td></tr>
160160
<tr><td> 404 </td><td> Not Found </td><td> - </td></tr>
161161
</table>
@@ -175,7 +175,7 @@ public Order createOrder(Order order) throws ApiException {
175175
<table border="1">
176176
<caption>Response Details</caption>
177177
<tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
178-
<tr><td> 200 </td><td> Returns specified order. </td><td> - </td></tr>
178+
<tr><td> 201 </td><td> Returns created order. </td><td> - </td></tr>
179179
<tr><td> 401 </td><td> Unauthorized </td><td> - </td></tr>
180180
<tr><td> 404 </td><td> Not Found </td><td> - </td></tr>
181181
</table>
@@ -197,7 +197,7 @@ public ApiResponse<Order> createOrderWithHttpInfo(Order order) throws ApiExcepti
197197
<table border="1">
198198
<caption>Response Details</caption>
199199
<tr><td> Status Code </td><td> Description </td><td> Response Headers </td></tr>
200-
<tr><td> 200 </td><td> Returns specified order. </td><td> - </td></tr>
200+
<tr><td> 201 </td><td> Returns created order. </td><td> - </td></tr>
201201
<tr><td> 401 </td><td> Unauthorized </td><td> - </td></tr>
202202
<tr><td> 404 </td><td> Not Found </td><td> - </td></tr>
203203
</table>

0 commit comments

Comments
 (0)