Store Endpoint
TIP
Refer to products page for Base URL
* Add Store
A user can create only one store.
Endpoint: POST
sell/storeRequest Headers
| Authorization | Value | Description | Required |
|---|---|---|---|
| Bearer | ************ | Firebase access token | ✔️ |
Payload Description
| Name | Type | Description | Required |
|---|---|---|---|
| about | string | store description | ❌ |
| categories | array of strings | Men, Women, Boys, Girls | ✔️ |
| name | string | full name of store | ✔️ |
| phone | string | true if salePrice != 0.00 ~ false by default | ❌ |
| state | string | region eg. Ashanti, Western | ✔️ |
| street | string | street address | ❌ |
| string | whatsapp number | ❌ |
Sample Payload
{
"about": "sell clothing",
"categories": ["Men", "Girls", "Boys"],
"name": "My New Store",
"phone": "123456789",
"state": "Greater Accra Region",
"street": "Adenta st",
"whatsapp": "0123456789"
}Sample Response
{
"id": "1edcf7c9-bbf6-4ca1-8de2-d7f69104ab2b",
"about": "sell clothing",
"categories": [
"Men",
"Girls",
"Boys"
],
"country": "Ghana",
"creatorId": "hudJ90nd0ndjHD03JDs0LSN9dhd7yw",
"dateCreated": "2023-06-01T08:03:56.944780Z",
"dateUpdated": "2023-06-01T08:03:56.944780Z",
"expiryDate": "",
"followers": 0,
"image": "/media/https%3A/wookin-shopping-storage.fra1.cdn.digitaloceanspaces.com/media/shops/default/shop-default.webp",
"isSubscribed": false,
"name": "My New Store",
"phone": "123456789",
"planType": "",
"productLimit": 0,
"state": "Greater Accra Region",
"street": "Adenta st",
"subscriptionDate": "",
"slug": "my-new-store-279",
"website": "https://my.wookin.com.gh/",
"whatsapp": "0123456789"
}* Store Details
Endpoint: GET
sell/store/pkRequest Headers
| Authorization | Value | Description | Required |
|---|---|---|---|
| Bearer | ************* | Firebase access token | ✔️ |
Parameters
| Name | Type | Description | Required |
|---|---|---|---|
| pk = store_id | string | add id to URL | ✔️ |
Sample Request
sell/store/135f1584-18a8-4e71-97db-d6292cce35dbSample Response
{
"id": "135f1584-18a8-4e71-97db-d6292cce35db",
"about": "sell clothing",
"categories": [
"Men",
"Girls",
"Boys"
],
"image": "http://127.0.0.1:8000/media/https%3A/wookin-shopping-storage.fra1.cdn.digitaloceanspaces.com/media/shops/default/shop-default.webp",
"name": "My New Store",
"phone": "123456789",
"state": "Greater Accra Region",
"street": "Adenta st",
"website": "https://my.wookin.com.gh/",
"whatsapp": "0123456789"
}* Update Store
Endpoint: PATCH | PUT
sell/store/update/pkRequest Headers
| Authorization | Value | Description | Required |
|---|---|---|---|
| Bearer | ************* | Firebase access token | ✔️ |
Parameters
| Name | Type | Description | Required |
|---|---|---|---|
| pk | string | store id | ✔️ |
Sample Request
sell/store/update/135f1584-18a8-4e71-97db-d6292cce35dbSample Payload
{
"about": "We sell clothing and shoes"
}Sample Response
{
"id": "00ad763e-a204-410a-8ea1-f4696ba97d0b",
"about": "We sell clothing and shoes"
"categories": [
"Men",
"Girls",
"Boys"
],
"country": "Ghana",
"creatorId": "hudJ90nd0ndjHD03JD0LSN9dhd7yw",
"dateCreated": "2023-05-31T08:19:01.252098Z",
"dateUpdated": "2023-06-01T08:11:22.170046Z",
"expiryDate": "",
"followers": 0,
"image": "http://127.0.0.1:8000/media/https%3A/wookin-shopping-storage.fra1.cdn.digitaloceanspaces.com/media/shops/default/shop-default.webp",
"isSubscribed": true,
"name": "My New Store",
"phone": "123456789",
"planType": "",
"productLimit": 0,
"subscriptionDate": "",
"slug": "my-new-store-279",
"state": "Greater Accra Region",
"street": "Adenta st",
"website": "https://my.wookin.com.gh/",
"whatsapp": "0123456789"
}* Delete Store
Endpoint: DELETE
sell/store/delete/pkRequest Headers
| Authorization | Value | Description | Required |
|---|---|---|---|
| Bearer | *************** | Firebase access token | ✔️ |
Parameters
| Name | Type | Description | Required |
|---|---|---|---|
| pk | string | store id | ✔️ |
Sample Request
sell/store/delete/135f1584-18a8-4e71-97db-d6292cce35dbSample Response
{
data=""store & products deleted"",
status=204 No Content
}
Wookein Docs