Objective: The objective of this assignment is to develop APIs, using the attached dataset, of purchases of different softwares through out the year. Candidates are free to use the dataset directly or import it in any database, if importing , make sure to include a migration file or readme steps so that we can run and check the APIs ourselves.
https://drive.google.com/file/d/1YfhCPZbofAekMy9tPH_7ZXChVX8w_OUF/view?usp=sharing
Install the follwoing files in remote server.
- flask (Flask, jsonify, request)
- pandas
- json
- End point : /api/total_items
- API Use Cases :
- Total item (total seats) sold in Marketting for last in q3 of the year?
- Expected O/P: returns integer
- Parameters: {start_date: DATE, end_date: DATE, department: string}
- End point : /api/nth_most_total_item
- API Use Cases :
- What is the 2nd most sold item in terms of quantity sold in q4?
- What is the 4th most sold item in terms of Total price in q2?
- Expected O/P: returns string name
- Parameters: { item_by: ("quantity" | | "price"), start_date: DATE, end_date:DATE, n:integer }
Link : http://127.0.0.1:5000/api/nth_most_total_item?item_by=quantity&start_date=2022-10-01&end_date=2022-12-31&n=2

- End point : /api/percentage_of_department_wise_sold_items
- API Use Cases:
- What is the percentage of sold items (seats) department wise?
- Expected O/P: {dept_name: x%,……. }
- Parameters: {start_date: Date, end_date: Date}
- End point : /api/monthly_sales
- API Use Cases:
- How does the monthly sales for any product look like?
- Expected O/P: [1908.0, … 1952.0] for all 12 months
- Parameters: {product: String, year:Number}
Link : http://127.0.0.1:5000/api/monthly_sales?product=Outplay&year=2022

If you have any feedback, please reach out at raghav.aggarwal2001@gmail.com || https://raghavaggarwalportfolio.netlify.app/


