Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Commit f577d6f

Browse files
committed
chore: 📝 Add Customer Group documentation
1 parent 079d956 commit f577d6f

File tree

2 files changed

+55
-1
lines changed

2 files changed

+55
-1
lines changed

README.md

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ A Magento 2 API Object Oriented wrapper for a Laravel application.
2424
- [Categories](#categories)
2525
- [Customer Token](#customer-token)
2626
- [Customers](#customers)
27+
- [Customer Groups](#customer-groups)
2728
- [Guest Cart](#guest-cart)
2829
- [Orders](#orders)
2930
- [Product Attributes](#product-attributes)
@@ -212,6 +213,59 @@ Reset customer password.
212213
Magento::api('customers')->resetPassword($email, $resetToken, $newPassword);
213214
```
214215

216+
<a id="customer-groups"></a>
217+
218+
### Customer Groups
219+
220+
GET `/V1/customerGroups/{id}`
221+
222+
Show the customer group by the provided ID.
223+
```php
224+
Magento::api('customerGroups')->show($id);
225+
```
226+
227+
PUT `/V1/customerGroups/{id}`
228+
229+
Save the customer group by the provided ID.
230+
```php
231+
Magento::api('customerGroups')->saveGroup($id, $customerGroupRepositoryV1SavePutBody = []);
232+
```
233+
234+
DELETE `/V1/customerGroups/{id}`
235+
236+
Delete customer group by the provided ID.
237+
```php
238+
Magento::api('customerGroups')->deleteGroup($id);
239+
```
240+
241+
POST `/V1/customerGroups`
242+
243+
Save/Create Customer Group.
244+
```php
245+
Magento::api('customerGroups')->createGroup($customerGroupRepositoryV1SavePostBody = []);
246+
```
247+
248+
GET `/V1/customerGroups/search`
249+
250+
Search the Customer Groups.
251+
```php
252+
Magento::api('customerGroups')->search($pageSize = 50, $currentPage = 1, $filters = []);
253+
```
254+
255+
GET `/V1/customerGroups/default`
256+
257+
Get the default customer group.
258+
```php
259+
Magento::api('customerGroups')->default();
260+
```
261+
262+
PUT `/V1/customerGroups/default/{id}`
263+
264+
Set the default customer group.
265+
```php
266+
Magento::api('customerGroups')->setDefault($id);
267+
```
268+
215269
<a id="guest-cart"></a>
216270
### Guest Cart (various)
217271

src/Api/CustomerGroups.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ public function createGroup($customerGroupRepositoryV1SavePostBody = [])
5050
}
5151

5252
/**
53-
* The list of Customer Groups.
53+
* Search the Customer Groups.
5454
*
5555
* @param int $pageSize
5656
* @param int $currentPage

0 commit comments

Comments
 (0)