Skip to content

Commit 56a82a5

Browse files
update subcategory endpoints in README
1 parent 1756f82 commit 56a82a5

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ Test the API using Swagger UI (`/` route), Postman, cURL or your preferred HTTP
6464

6565
#### Fetch products using name, category, subcategory
6666
- [GET] `/product/<name: string>` - Get product with name: `name` <br/><br/>
67-
- [GET] `/subcategory/<subcategory_id: int>/products?page=<page_no>` - Get product with within subcategory `subcategory`. Returns `page_no` of the paginated results. <br/><br/>
67+
- [GET] `/subcategories/<subcategory_id: int>/products?page=<page_no>` - Get product with within subcategory `subcategory`. Returns `page_no` of the paginated results. <br/><br/>
6868
- [GET] `/categories/<category_id: int>/products` - Get product with within category `category`. Returns first page of the paginated results. <br/><br/>
6969
- [GET] `/categories/<category_id: int>/products?page=<page_no>` - Get product with within category `category`. Returns `page_no` of the paginated results. <br/><br/>
7070

@@ -124,11 +124,11 @@ Test the API using Swagger UI (`/` route), Postman, cURL or your preferred HTTP
124124

125125
#### Subcategory
126126
- [GET] `/subcategories` - Get all subcategories
127-
- [GET] `/subcategory/(int: subcategory_id)` - Get subcategory with subcategory_id
128-
- [GET] `/subcategory/(int: subcategory_id)/categories` - Get categories related to subcategory_id
129-
- [DELETE] `/subcategory/(int: subcategory_id)` (Protected) - Delete subcategory with subcategory_id
127+
- [GET] `/subcategories/(int: subcategory_id)` - Get subcategory with subcategory_id
128+
- [GET] `/subcategories/(int: subcategory_id)/categories` - Get categories related to subcategory_id
129+
- [DELETE] `/subcategories/(int: subcategory_id)` (Protected) - Delete subcategory with subcategory_id
130130

131-
- [POST] `/subcategory/create` (Protected) - Create a new subcategory
131+
- [POST] `/subcategories` (Protected) - Create a new subcategory
132132
```
133133
{
134134
"name": "name",
@@ -137,7 +137,7 @@ Test the API using Swagger UI (`/` route), Postman, cURL or your preferred HTTP
137137
}
138138
```
139139

140-
- [PUT] `/subcategory/(int: subcategory_id)/update` (Protected) - Update subcategory with subcategory_id
140+
- [PUT] `/subcategories/(int: subcategory_id)` (Protected) - Update subcategory with subcategory_id
141141
```
142142
{
143143
"name": "name",

0 commit comments

Comments
 (0)