Backend API for the BizHub Guyana application to manage businesses and services those businesses are providing. Which also includes reviews, inquiry, users, authentication, authorisation, payments, ads management and much more
Admin required apis for BizHub admin
Get BizHub admin dashboard stats
Appointments created by user to services.
Add Appointment for a user of a service.
Appointment
Status - Predefined:
[‘rejected’, ‘approved’,
‘reschedule’, ‘completed’,
‘pending’]
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Delete user created appointment. Can only be deleted by
user and admin
Get all appointments from database in paginated form
Get all appointments from a service by passing service id
Get all appointments of a user by passing user id
Get single appointmnet by id
Update Appointment. Can only be updated by user and admin
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Routes for user authentication including register, login, reset password, etc
Check if email already registered.
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Check if username is used by any other user
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Generate password token and send email
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| greg@gmail.com | ||
| password | 123456789 |
Clear token cookie
Add user to database with encypted password
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Reset user password using token
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Update logged in user password, send in the body
currentPassword & newPassword
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Update logged in user basic info
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Upload user profile.
Only auth token required.
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| file |
Business CRUD functionality
Adding new business to database. Must be authenticated
and must be a registered user
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Delete business from database
Fetch all Businessess from database. Includes pagination,
filtering, etc
Get business with a radius of specific zip code
Fetch single business by ID
Update single business in database
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Route to business photo upload
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| file |
Manage Business reviews
Insert review for a specific buisness
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Delete Reviews
Get all reviews of business from database and populate
with business name and description
Fetch the reviews for a specific business
Fetch a review from database by id
Update review in database
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Categories of services BizHub supports
Create category and only admin can create one
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Delete category by id and only Admin can delete
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Get all categories
Get single category by id
Update category by id and only Admin can update
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Upload category icon by id and only Admin can upload
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| file |
Upload category icon by id and only Admin can upload
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| file |
Send Contact Or Enquiry Mail to BizHub original gmail account
Enquiry mail from user to current service
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Send email from contact us form. This will use registered
email on AWS contact@toolboxguyana.com to send message.
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Enquiry mail from user to current service
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Inquiry mail from user to Bizhub team
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| key | kodBSZTg56UcWWgrX9bF12HUJdypkN4V | |
| location | Model Town, Lahore, Punjab |
Manage user history which includes all time service visits and recent visits to service detail page
Add service to history. It will update history if already
added today
| Key | Value | Description |
|---|---|---|
| service | 5d725cfec4ded7bcb480eaa6 |
Delete history item
Get all history data.
Get History of current logged in user for today.
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Get logged in user notification for landing page to get
notified for any update on profile or business dashboard
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Manage BizHub review from registered users.
Insert review for a specific buisness
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Delete Reviews
Get all reviews of business from database and populate
with business name and description
Fetch a review from database by id
Update review in database
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Payment APIs for package upgrade or Ads publishing
All Payments done to Bizhub
Stripe payment for ad posting by users
Stripe payment for businesses to upgrade there package
Manage user history which includes all time service visits and recent visits to service detail page
Clear service flag so it is visible until next report
| Key | Value | Description |
|---|---|---|
| type | spam |
REQUIRED | hardcoded types from front end |
| description | fake content copied from someone else |
REQUIRED | description |
| service | 5d725cfec4ded7bcb480eaa6 |
REQURIED | reported serivice Id |
Remove a single report of a service
Get all reported services
| Key | Value | Description |
|---|---|---|
| limit | 10 |
Remove all reports of a service and clear flags.
Report service by passing service id and detail
| Key | Value | Description |
|---|---|---|
| type | spam |
REQUIRED | hardcoded types from front end |
| description | fake content copied from someone else |
REQUIRED | description |
| service | 5d725cfec4ded7bcb480eaa6 |
REQURIED | reported serivice Id |
User saved services
Get all saved services or business by users
| Key | Value | Description |
|---|---|---|
| user | 5d725a4a7b292f5f8ceff789 | |
| service | 5d725a4a7b292f5f8ceff789 |
Save or unsave service
| Key | Value | Description |
|---|---|---|
| service | 5d725a4a7b292f5f8ceff789 |
User posted reviews and rating for services provided by businesses
Add review for a service by logged in user
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Delete user posted review. Can onlye be deleted by posted
user and admin
Get all reviews of services from database and populate
with service name and description
Get all reviews for servcies by passing service id as
parameter
Get single service review by id
Update service review. Can only be updated by posted user
and admin
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Route to service photo upload
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| file |
Create, Read, update, delete Business Services
Create service for specific business
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Route to remove single service photo form list of photos
- /{serviceId}/photo/{photoId}
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Remove service from database
Get the specific services of business
Get business with a radius of specific zip code
get a single service ny its id
Search services on text base.
return services when entered textquery exists in with
title, description or keywords.
It may return data if entered query found in any string
type property
| Key | Value | Description |
|---|---|---|
| query | cof |
Search services on text base.
return services when entered textquery exists in with
title, description or keywords.
It may return data if entered query found in any string
type property
| Key | Value | Description |
|---|---|---|
| query | guy |
Route to service photo upload
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| caption | This is 4 updated caption |
Update service views by increasing 1 per click
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Update service in database
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Upload service logo/icon
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| file |
Route to service photo upload
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| file | ||
| caption | quote2 |
Ads management, posted for a specific slot for a specific page
Creating an Ad
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Delete existing ad by Id
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Get all user posted ads
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Get single ad by Id
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Update exsisting add by ID
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Upload Ad image on S3 and update url in exisiting ad
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
| Key | Value | Description |
|---|---|---|
| file |
CRUD functionality for users only available to Admins
Add user to database (admin)
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |
Delete user from database (Admin)
Get all users (admin)
Get single user by id (admin)
Update user in database (admin)
| Key | Value | Description |
|---|---|---|
| Content-Type | application/json |
JSON type |