Base URL
https://apidocs.zowasel.com/v1
Authentication
All API requests require authentication via an API key. Obtain your API key from Zowasel by onboarding with our technical team and generating a key.
Header
Authorization: Bearer YOUR_API_KEY
Endpoints
User Management
1. Create User
POST/users
Creates a new user.
Request Body:
{
"email": "string",
"password": "string",
"firstname": "string",
"lastname": "string",
"mobile": "string",
"usertype": "merchant or corporate",
"isbusiness": "boolean",
"businessname": "string",
"level": "string",
"belongsto": "string",
"region": "string",
"rolename": "string",
"permissions": ["string"]
}
Response:
{
"_id": "unique_user_id",
"email": "string",
"password": "hashed_password",
"firstname": "string",
"lastname": "string",
"mobile": "string",
"usertype": "merchant or corporate",
"isbusiness": "boolean",
"businessname": "string",
"level": "string",
"dateCreated": "YYYY-MM-DDTHH:MM:SSZ",
"dateUpdated": "YYYY-MM-DDTHH:MM:SSZ",
"belongsto": "string",
"region": "string",
"rolename": "string",
"permissions": ["string"]
}
2. Get User Details
GET/users/{id}
Retrieves details of a specific user by ID.
Parameters:
id (string): The ID of the user.
Response:
{
"_id": "unique_user_id",
"email": "string",
"password": "hashed_password",
"firstname": "string",
"lastname": "string",
"mobile": "string",
"usertype": "merchant or corporate",
"isbusiness": "boolean",
"businessname": "string",
"level": "string",
"dateCreated": "YYYY-MM-DDTHH:MM:SSZ",
"dateUpdated": "YYYY-MM-DDTHH:MM:SSZ",
"belongsto": "string",
"region": "string",
"rolename": "string",
"permissions": ["string"]
}
3. Update User
PUT/users/{id}
Update details of a specific user.
Parameters:
id (string): The ID of the user.
Request body:
{
"email": "string",
"password": "string",
"firstname": "string",
"lastname": "string",
"mobile": "string",
"usertype": "merchant or corporate",
"isbusiness": "boolean",
"businessname": "string",
"level": "string",
"belongsto": "string",
"region": "string",
"rolename": "string",
"permissions": ["string"]
}
Response:
{
"status": "success",
"message": "User details updated successfully."
}
4. Delete User
DELETE/users/{id}
Delete a specific user.
Parameters:
id (string): The ID of the user.
Response:
{
"status": "success",
"message": "User deleted successfully."
}
Crop Marketplace
1. Create Crop Listing
POST/marketplace/crops
Creates a new crop listing in the marketplace.
Request Body:
{
"businessid": "string",
"type": "string",
"categoryid": "string",
"subcategoryid": "string",
"category": "string",
"subcategory": "string",
"description": "string",
"currency": "string",
"state": "string",
"negotiable": "string",
"country": "string",
"images": ["string"],
"videos": ["string"],
"productcolor": "string",
"color": "string",
"productionmethod": "string",
"testweight": "string",
"application": "string",
"packaging": "string",
"amount": "string",
"global": "string",
"quantity": "string",
"specifications": "string",
"cropwanted": {
"zipcode": "string",
"warehouseaddress": "string"
},
"cropauction": {
"startdate": "string",
"enddate": "string",
"minimumbid": "string"
},
"contentregion": "string"
}
Response:
{
"_id": "unique_crop_id",
"businessid": "string",
"type": "string",
"categoryid": "string",
"subcategoryid": "string",
"category": "string",
"subcategory": "string",
"description": "string",
"currency": "string",
"state": "string",
"negotiable": "string",
"country": "string",
"images": ["string"],
"videos": ["string"],
"productcolor": "string",
"color": "string",
"productionmethod": "string",
"testweight": "string",
"application": "string",
"packaging": "string",
"amount": "string",
"global": "string",
"quantity": "string",
"specifications": "string",
"cropwanted": {
"zipcode": "string",
"warehouseaddress": "string"
},
"cropauction": {
"startdate": "string",
"enddate": "string",
"minimumbid": "string"
},
"active": 1,
"contentregion": "string",
"deletedby": "none",
"createdat": "YYYY-MM-DDTHH:MM:SSZ",
"updatedat": "YYYY-MM-DDTHH:MM:SSZ"
}
2. Get Crop Listing
GET/marketplace/crops/{id}
Retrieves details of a specific crop listing by ID.
Parameters:
id (string): The ID of the crop listing.
Response:
{
"_id": "unique_crop_id",
"businessid": "string",
"type": "string",
"categoryid": "string",
"subcategoryid": "string",
"category": "string",
"subcategory": "string",
"description": "string",
"currency": "string",
"state": "string",
"negotiable": "string",
"country": "string",
"images": ["string"],
"videos": ["string"],
"productcolor": "string",
"color": "string",
"productionmethod": "string",
"testweight": "string",
"application": "string",
"packaging": "string",
"amount": "string",
"global": "string",
"quantity": "string",
"specifications": "string",
"cropwanted": {
"zipcode": "string",
"warehouseaddress": "string"
},
"cropauction": {
"startdate": "string",
"enddate": "string",
"minimumbid": "string"
},
"active": 1,
"contentregion": "string",
"deletedby": "none",
"createdat": "YYYY-MM-DDTHH:MM:SSZ",
"updatedat": "YYYY-MM-DDTHH:MM:SSZ"
}
3. Update Crop Listing
PUT/marketplace/crops/{id}
Update details of a specific crop listing.
Parameters:
id (string): The ID of the crop listing.
Request body:
{
"businessid": "string",
"type": "string",
"categoryid": "string",
"subcategoryid": "string",
"category": "string",
"subcategory": "string",
"description": "string",
"currency": "string",
"state": "string",
"negotiable": "string",
"country": "string",
"images": ["string"],
"videos": ["string"],
"productcolor": "string",
"color": "string",
"productionmethod": "string",
"testweight": "string",
"application": "string",
"packaging": "string",
"amount": "string",
"global": "string",
"quantity": "string",
"specifications": "string",
"cropwanted": {
"zipcode": "string",
"warehouseaddress": "string"
},
"cropauction": {
"startdate": "string",
"enddate": "string",
"minimumbid": "string"
}
}
Response:
{
"status": "success",
"message": "Crop listing updated successfully."
}
4. Delete Crop Listing
DELETE/marketplace/crops/{id}
Delete a specific crop listing.
Parameters:
id (string): The ID of the crop listing.
Response:
{
"status": "success",
"message": "Crop listing deleted successfully."
}
Market Price Reports
1. Create Market Price Reports
POST/marketprice/reports
POST/marketprice/reports
Creates a new market price report.
Request Body:
{
"region": "string",
"cropcategory": "string",
"cropsubcategory": "string",
"pricetype": "string",
"contentregion": "string",
"weighttype": "string",
"color": "string",
"quantity": "string",
"minimumprice": "number",
"maximumprice": "number",
"datecollected": "string",
"state": "string",
"market": "string",
"countrycustom": "string",
"countryflag": "string"
}
Response:
{
"_id": "unique_report_id",
"region": "string",
"cropcategory": "string",
"cropsubcategory": "string",
"pricetype": "string",
"contentregion": "string",
"weighttype": "string",
"color": "string",
"quantity": "string",
"minimumprice": "number",
"maximumprice": "number",
"average": "number",
"state": "string",
"market": "string",
"countrycustom": "string",
"countryflag": "string",
"datecollected": "string",
"tempdelete": 0,
"deletedby": "none",
"createdat": "YYYY-MM-DD",
"updatedat": "YYYY-MM-DDTHH:MM:SSZ"
}
2. Get Market Price Report
GET/marketprice/reports/{id}
Retrieves details of a specific market price report by ID.
Parameters:
id (string): The ID of the market price report.
Response:
{
"_id": "unique_report_id",
"region": "string",
"cropcategory": "string",
"cropsubcategory": "string",
"pricetype": "string",
"contentregion": "string",
"weighttype": "string",
"color": "string",
"quantity": "string",
"minimumprice": "number",
"maximumprice": "number",
"average": "number",
"state": "string",
"market": "string",
"countrycustom": "string",
"countryflag": "string",
"datecollected": "string",
"tempdelete": 0,
"deletedby": "none",
"createdat": "YYYY-MM-DD",
"updatedat": "YYYY-MM-DDTHH:MM:SSZ"
}
3. Update Market Price Report
PUT/marketprice/reports/{id}
Update details of a specific market price report.
Parameters:
id (string): The ID of the market price report.
Request body:
{
"region": "string",
"cropcategory": "string",
"cropsubcategory": "string",
"pricetype": "string",
"contentregion": "string",
"weighttype": "string",
"color": "string",
"quantity": "string",
"minimumprice": "number",
"maximumprice": "number",
"datecollected": "string",
"state": "string",
"market": "string",
"countrycustom": "string",
"countryflag": "string"
}
Response:
{
"status": "success",
"message": "Market price report updated successfully."
}
4. Delete Market Price Report
DELETE/marketprice/reports/{id}
Delete a specific market price report.
Parameters:
id (string): The ID of the market price report.
Response:
{
"status": "success",
"message": "Market price report deleted successfully."
}
Farmer Market
1. Create Farmer
POST/farmers
Creates a new farmer record.
Request Body:
{
"businessid": "string",
"passport": "string",
"email": "string",
"firstname": "string",
"lastname": "string",
"middlename": "string",
"telephone1": "string",
"telephone2": "string",
"gender": "string",
"dateofbirth": "string",
"maritalstatus": "string",
"country": "string",
"countryflag": "string",
"state": "string",
"town": "string",
"address": "string",
"bankname": "string",
"accountname": "string",
"bankaccountnumber": "string",
"bvn": "string",
"contentregion": "string",
"nin": "string",
"bvnimage": "string",
"ninimage": "string",
"idcardtype": "string",
"idcardfront": "string",
"idcardback": "string",
"nextofkinfullname": "string",
"nextofkinmobile": "string",
"nextofkinrelationship": "string",
"channel": "string"
}
Response:
{
"_id": "unique_farmer_id",
"businessid": "string",
"passport": "string",
"email": "string",
"firstname": "string",
"lastname": "string",
"middlename": "string",
"telephone1": "string",
"telephone2": "string",
"gender": "string",
"dateofbirth": "string",
"maritalstatus": "string",
"country": "string",
"countryflag": "string",
"state": "string",
"town": "string",
"address": "string",
"bankname": "string",
"accountname": "string",
"bankaccountnumber": "string",
"bvn": "string",
"contentregion": "string",
"nin": "string",
"bvnimage": "string",
"ninimage": "string",
"idcardtype": "string",
"idcardfront": "string",
"idcardback": "string",
"nextofkinfullname": "string",
"nextofkinmobile": "string",
"nextofkinrelationship": "string",
"channel": "string",
"tempdelete": 0,
"deletedby": "none",
"createdat": "YYYY-MM-DDTHH:MM:SSZ",
"updatedat": "YYYY-MM-DDTHH:MM:SSZ"
}
2. Get Farmer
GET/farmers/{id}
Retrieves details of a specific farmer by ID.
Parameters:
id (string): The ID of the farmer.
Response:
{
"_id": "unique_farmer_id",
"businessid": "string",
"passport": "string",
"email": "string",
"firstname": "string",
"lastname": "string",
"middlename": "string",
"telephone1": "string",
"telephone2": "string",
"gender": "string",
"dateofbirth": "string",
"maritalstatus": "string",
"country": "string",
"countryflag": "string",
"state": "string",
"town": "string",
"address": "string",
"bankname": "string",
"accountname": "string",
"bankaccountnumber": "string",
"bvn": "string",
"contentregion": "string",
"nin": "string",
"bvnimage": "string",
"ninimage": "string",
"idcardtype": "string",
"idcardfront": "string",
"idcardback": "string",
"nextofkinfullname": "string",
"nextofkinmobile": "string",
"nextofkinrelationship": "string",
"channel": "string",
"tempdelete": 0,
"deletedby": "none",
"createdat": "YYYY-MM-DDTHH:MM:SSZ",
"updatedat": "YYYY-MM-DDTHH:MM:SSZ"
}
3. Update Farmer
PUT/farmers/{id}
Update details of a specific farmer.
Parameters:
id (string): The ID of the farmer.
Request body:
{
"businessid": "string",
"passport": "string",
"email": "string",
"firstname": "string",
"lastname": "string",
"middlename": "string",
"telephone1": "string",
"telephone2": "string",
"gender": "string",
"dateofbirth": "string",
"maritalstatus": "string",
"country": "string",
"countryflag": "string",
"state": "string",
"town": "string",
"address": "string",
"bankname": "string",
"accountname": "string",
"bankaccountnumber": "string",
"bvn": "string",
"contentregion": "string",
"nin": "string",
"bvnimage": "string",
"ninimage": "string",
"idcardtype": "string",
"idcardfront": "string",
"idcardback": "string",
"nextofkinfullname": "string",
"nextofkinmobile": "string",
"nextofkinrelationship": "string",
"channel": "string"
}
Response:
{
"status": "success",
"message": "Farmer details updated successfully."
}
4. Delete Farmer
DELETE/farmers/{id}
Delete a specific farmer record.
Parameters:
id (string): The ID of the farmer record.
Response:
{
"status": "success",
"message": "Farmer deleted successfully."
}