Add new endpoint to laravel api module
Budget: $10 – $30 USD
Hello ,
I need to add 2 endpoints to current api module , project backend is php and framework is laravel
1) products end point:
** Parameters:
Location_id : separated with comma to get multi locations in one request
location_tpe: (R , F, R+F , ….etc)
date filter (start and end date range)
not_for_selling: (0,1)
is_inactive: (0,1)
search: “” //will be used search parameter to be searched in name(ar,en) and sku
managed_stock: (0,1)
sub-category: (0,1) // 0 >> return categories , 1 >> return sub-categories
** structure:
{
"data" :[
{
"product_id": ,
"product_sku": ,
"product_name_ar": ,
"product_name_en": ,
"product_variation": , //Variations>>name
"current_stock_qty": ,
"avg_product_cost": , //According to sold purchase lines (Ex: (every pl_qty_available * pl_purchase_price_inc_tax) / total_qty_available )
"stock_value_by_cost_price": , //According to sold purchase lines (Ex: (every pl_qty_available * pl_purchase_price_inc_tax) )
"avg_selling_cost": ,
"stock_value_by_selling_price": , //current_stock_qty * selling_cost
"ratio": , //(avg_product_cost/selling_cost)*100
"unit_profit": , //avg_selling_cost-avg_product_cost
"profit": , //stock_value_by_selling_price-stock_value_by_cost_price
},
{
// like previous
}
],
"totals": [
{
"total_current_stock_qty": , //sum of all returned data
"total_product_cost": , //sum of all returned data
"total_selling_cost": , //sum of all returned data
"total_unit_profit": , //sum of all returned data
"total_profit": , //sum of all returned data
}
],
}
2) Total categories products end point:
** Parameters:
Location_id : separated with comma to get multi locations in one request
location_tpe: (R , F, R+F , ….etc)
not_for_selling: (0,1)
is_inactive: (0,1)
search: “” //will be used search parameter to be searched in name(ar,en) and sku
managed_stock: (0,1)
sub-category: (0,1) // 0 >> return categories , 1 >> return sub-categories
** structure:
{
"data" :[
{
"categories_id": ,
"category_name": , //Will return parent and childern categories
"total_current_stock_qty": , //total current stock qty from this category
"stock_value_by_cost_price": , //According to sold purchase lines
"stock_value_by_selling_price": , //current_stock_qty * selling_cost
},
{
//like previous
}
],
"totals": [
{
"total_current_stock_qty": , //sum of all returned data
"stock_value_by_cost_price": , //sum of all returned data
"stock_value_by_selling_price": , //sum of all returned data
}
],
}
Project timeframe Max. 24 hrs
DM me to send project after accept the milestone
I need to add 2 endpoints to current api module , project backend is php and framework is laravel
1) products end point:
** Parameters:
Location_id : separated with comma to get multi locations in one request
location_tpe: (R , F, R+F , ….etc)
date filter (start and end date range)
not_for_selling: (0,1)
is_inactive: (0,1)
search: “” //will be used search parameter to be searched in name(ar,en) and sku
managed_stock: (0,1)
sub-category: (0,1) // 0 >> return categories , 1 >> return sub-categories
** structure:
{
"data" :[
{
"product_id": ,
"product_sku": ,
"product_name_ar": ,
"product_name_en": ,
"product_variation": , //Variations>>name
"current_stock_qty": ,
"avg_product_cost": , //According to sold purchase lines (Ex: (every pl_qty_available * pl_purchase_price_inc_tax) / total_qty_available )
"stock_value_by_cost_price": , //According to sold purchase lines (Ex: (every pl_qty_available * pl_purchase_price_inc_tax) )
"avg_selling_cost": ,
"stock_value_by_selling_price": , //current_stock_qty * selling_cost
"ratio": , //(avg_product_cost/selling_cost)*100
"unit_profit": , //avg_selling_cost-avg_product_cost
"profit": , //stock_value_by_selling_price-stock_value_by_cost_price
},
{
// like previous
}
],
"totals": [
{
"total_current_stock_qty": , //sum of all returned data
"total_product_cost": , //sum of all returned data
"total_selling_cost": , //sum of all returned data
"total_unit_profit": , //sum of all returned data
"total_profit": , //sum of all returned data
}
],
}
2) Total categories products end point:
** Parameters:
Location_id : separated with comma to get multi locations in one request
location_tpe: (R , F, R+F , ….etc)
not_for_selling: (0,1)
is_inactive: (0,1)
search: “” //will be used search parameter to be searched in name(ar,en) and sku
managed_stock: (0,1)
sub-category: (0,1) // 0 >> return categories , 1 >> return sub-categories
** structure:
{
"data" :[
{
"categories_id": ,
"category_name": , //Will return parent and childern categories
"total_current_stock_qty": , //total current stock qty from this category
"stock_value_by_cost_price": , //According to sold purchase lines
"stock_value_by_selling_price": , //current_stock_qty * selling_cost
},
{
//like previous
}
],
"totals": [
{
"total_current_stock_qty": , //sum of all returned data
"stock_value_by_cost_price": , //sum of all returned data
"stock_value_by_selling_price": , //sum of all returned data
}
],
}
Project timeframe Max. 24 hrs
DM me to send project after accept the milestone